The shift_phase command increases the phase of a trigonometric expression by π/2.
Examples.
x−cos | ⎛ ⎜ ⎜ ⎝ |
| ⎞ ⎟ ⎟ ⎠ |
x+sin | ⎛ ⎜ ⎜ ⎝ |
| ⎞ ⎟ ⎟ ⎠ |
x− |
|
Quoting the argument will prevent the automatic simplification.
Example.
Input:
Output:
−cos | ⎛ ⎜ ⎜ ⎝ |
| ⎞ ⎟ ⎟ ⎠ |
With an unquoted sine, you get:
Input:
Output:
sin | ⎛ ⎜ ⎜ ⎝ |
| ⎞ ⎟ ⎟ ⎠ |
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).