Why is mechanical waves faster in denser medium while EM waves slower? Why is it that mechanical waves/longitudinal waves/sound travel faster in a denser/stiffer medium as in steel compared to say air, while EM waves/trasverse waves/light travels slower in a (optically) denser medium as in say glass?
I know that for mechanical waves,$$v \varpropto \sqrt{T}$$, where $T$ stands for Tension
and $$c \varpropto \sqrt{\frac{1}{\epsilon_0\mu_0}}$$
Any physical interpretation might be helpful.
EDIT: What I understand from this is that, since higher tension implies stronger intermolecular interaction, which leads to better conveyance of energy across the material which causes the waves to move faster. But this analogy doesn't fit at all for light waves. Why?
 A: The reason is that EM waves don't really propagate through matter -- they exist in vacuum and go with c there, and they interact with matter by being absorbed and re-emitted by the particles of the medium. This only looks like they were slowed down from the macroscopic perspective. 
Mechanical waves exist as a form of particle motion, and their speed roughly depends on how easily the distortion can propagate from one particle to another.
If you look at the wave equation, the speed is a square root of the stuff multiplying spatial derivative (connected with the strength of particle motion coupling) divided by the stuff multiplying temporal derivative (connected with the inertia of particles). How this is connected to the density depends on the medium and wave type.
A: Mechanical waves are slower in a denser medium, provided that you keep the stiffness of the material the same. Steel is about $10^3$ times more dense than air, but its resistance to compression is millions of times greater.
If your T means temperature, then $v \propto \sqrt{T}$ is not for mechanical waves in general, it's for gases. At fixed pressure, a higher temperature gives a lower density, which causes a higher v.
Electromagnetic waves are not really analogous to mechanical ones.
