3
$\begingroup$

How to get phase-folded data (-0.5,0.5)? For phase-folded value to the interval (0,1), I use:

$$ \phi = \frac{H_{JD}-T_0}{P} \mod 1$$

$\phi$ is phase

HJD is time

T0 is the reference time

P is the period

T0 should correspond to $\phi$ = 0

$\endgroup$

2 Answers 2

4
$\begingroup$

Take your final result for the phase and then subtract 1 if it is $>0.5$.

$\endgroup$
4
$\begingroup$

Let's see if this is what you need:

Starting with

  phi = ((HJD-T0)/P)%1

rewriting in MathJax:

$$\phi = \mod((H_{JD} - T_0) \ / P, \ 1)$$

We just need to push it by 0.5 so it wraps sooner by $\mod()$ , then subtract the 0.5 again on the outside to recenter it:

$$\phi = \mod((H_{JD} - T_0) \ / P + 0.5 , \ 1) - 0.5$$

$\endgroup$
2
  • 1
    $\begingroup$ I think, you dropped a " / P " in your formula. $\endgroup$
    – SpaceCore
    Mar 23, 2022 at 15:49
  • 1
    $\begingroup$ @SpaceCore fixed; thanks! $\endgroup$
    – uhoh
    Mar 23, 2022 at 17:42

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .