If a medical device has been patented which mentions in the first claim, a particular material for specific reasons and I manage to patent the same medical device which mentions in the first claim, a completely different material for specific reasons, will I have to pay royalties to the first inventor?
To infringe on a patent you must implement each and every step in at least one claim. So, in the scenario provided, if a claim includes a specific material and you don't use that material, you don't infringe that claim. However, this doesn't necessarily mean you have freedom to operate. There may be other broader patents. For example, let's say you see a patent for a lightbulb which specifies the use of a tungsten filament in evacuated glass bulb. If your bulb uses say a chromium filament you are fine with regards to that patent. However, there very well may be an earlier patent that specifies a light bulb with a filament in an evacuated glass bulb. You would infringe that earlier patent. The broader use of just filament would cover your device and you would infringe. Of course, these lightbulb examples are expired by now, but it is just to illustrate the idea.
At the very least, you should review all the patents cited by the patent and if you find a related patent look at that patent's cited documents too.