Optically Heated Long-Period Grating as Temperature-Insensitive Fiber-Optic Refractive-Index Sensor