Calculation of optical power emitted from a fibre grating laser