Previous Up Next

6.23.3  Increasing the phase by π/2 in a trigonometric expression: shift_phase

The shift_phase command increases the phase of a trigonometric expression by π/2.


Examples.

Quoting the argument will prevent the automatic simplification.


Example.
Input:

shift_phase(’sin(x + pi/2)’)

Output:

−cos


π +2 x+2 
π
2
2



With an unquoted sine, you get:
Input:

shift_phase(sin(x + pi/2))

Output:

sin


π +2 x
2



since sin(x+pi/2) is evaluated (in this case simplified) before shift_phase is called, and shift_phase(cos(x)) returns sin((pi+2*x)/2).


Previous Up Next