How can the gravitational redshift of a very distant quasar be distinguished from its cosmological redshift? Quasars are very massive objects,thought to be supermassive black holes,so therefore must have substantial gravitational red shift,but they are so far away they must also have a cosmological redshift. Is it possible to distinguish one from the other?
The optical emission lines of quasars do not come from sufficiently close the the central supermassive black hole to be appreciably gravitationally redshifted.
If they did arise from gas near the "innermost stable circular orbit", then the maximum gravitational redshift would be about 0.2. In addition, the lines would have a characteristic profile caused by a combination of gravitational redshift and the blue/redshift and Doppler boosting caused by the fast-moving gas (such line profiles are sometimes seen at X-ray wavelengths). Of course many if not most quasars have redshifts that far exceed 0.2 and can only be explained by cosmic expansion.
Both cosmological redshifts, and gravitational redshifts, can be thought of as coming from the same source-- the equations of general relativity. In that sense, the distinction between them is somewhat artificial, though useful, but they are redshifts that affect all the lines in the same way. So there is no way to disentangle their effects, other than to model both of their sources. This is not so unusual-- if you have normal Doppler shifts in a reference frame where you don't know the motion of either the source or the detector, then the Doppler shift registered will represent a combination of those motions that you cannot disentangle simply from what you observe-- you will have to model the effects of all contributing effects.
That generally means you need to bring in more independent information, such that you can test your models. In the case of quasars, you could look for quasars that appear to be similar except for their distance from you, and then you can assume their gravitational redshift is similar but their cosmological redshift is very different. In particular, you can have relatively nearby quasars that do not have a lot of cosmological redshift, perhaps even comparable to their gravitational redshift. And you can have very distant ones that are predominantly cosmological redshifts. You can also use the fact that the cosmological redshift is the same for all the lines of a given quasar, but gravitational redshifts will depend on how deep in the gravity well each line forms. There is also a connection between where a line forms and what its Doppler shift is, because the gas is generally moving, so we even have a third source of frequency shift, but it connects with gravitational redshift in ways that alter the line shape. So we have new information from line shape, that allows the models to be tested, even though we must combine no less than three separate sources of frequency shift (special relativistic, general relativistic due to local gravity, general relativistic due to global effects of the expanding universe).
You have other information also, such as temperatures and Doppler shifts, and time dependence, so you put all that together and you try to model the quasar. That's the only way to disentangle the redshifts, you need self-consistent models that succeed at producing a wide range of observables. Remember that we had quasar spectra for many years before we were even able to figure out what they were, and debate still continues about the sources of the various spectral components.