Pulsed fraction from fractional amplitude of modulation.
If the pulsed profile is defined as p = mean * (1 + a * sin(phase)),
we define “pulsed fraction” as 2a/b, where b = mean + a is the maximum and a is the amplitude of the modulation.
Hence, pulsed fraction = 2a/(1+a)
>>> pf_from_a(1) 1.0 >>> pf_from_a(0) 0.0