Speed of Sound in Different States of Matter