Optical-frequency encoder using polarization-maintaining fibre