# qiskit.pulse.library.Triangle

`qiskit.pulse.library.Triangle(duration, amp, phase, freq=None, angle=0.0, name=None, limit_amplitude=None)`

A triangle wave pulse.

The envelope of the pulse is given by:

$f(x) = \text{A}\left[\text{sawtooth}\left(x\right)\right] , 0 <= x < duration$where $\text{A} = \text{amp} \times\exp\left(i\times\text{angle}\right)$, and $\text{sawtooth}\left(x\right)$ is a sawtooth wave with the same frequency as the triangle wave, but a phase shifted by $\frac{\pi}{2}$.

**Parameters**

**duration**(*int*(opens in a new tab)*|**ParameterExpression*) – Pulse length in terms of the sampling period dt.**amp**(*float*(opens in a new tab)*|**ParameterExpression*) – The magnitude of the amplitude of the triangle wave. Wave range is [-amp,`amp`].**phase**(*float*(opens in a new tab)*|**ParameterExpression*) – The phase of the triangle wave (note that this is not equivalent to the angle of the complex amplitude)**freq**(*ParameterExpression**|**float*(opens in a new tab)*| None*) – The frequency of the triangle wave, in terms of 1 over sampling period. If not provided defaults to a single cycle (i.e :math:’frac{1}{text{duration}}’). The frequency is limited to the range $\left(0,0.5\right]$ (the Nyquist frequency).**angle**(*ParameterExpression**|**float*(opens in a new tab)*| None*) – The angle in radians of the complex phase factor uniformly scaling the pulse. Default value 0.**name**(*str*(opens in a new tab)*| None*) – Display name for this pulse envelope.**limit_amplitude**(*bool*(opens in a new tab)*| None*) – If`True`

, then limit the amplitude of the waveform to 1. The default is`True`

and the amplitude is constrained to 1.

**Returns**

ScalableSymbolicPulse instance.

**Return type**

*ScalableSymbolicPulse*

Was this page helpful?

Report a bug or request content on GitHub.