# new_periodic_sequence

Source: https://docs.q-ctrl.com/references/qctrl-open-controls/qctrlopencontrols/new_periodic_sequence

```python
qctrlopencontrols.new_periodic_sequence(duration, offset_count, pre_post_rotation=False, name=None)
```

Creates the periodic sequence.

### Parameters
* **duration** (*float*) – Total duration of the sequence $\tau$ (in seconds).
* **offset_count** (*int*) – Number of offsets $n$.
* **pre_post_rotation** (*bool* *,* *optional*) – If `True`, a $X_{\pi/2}$ rotation is added at the
  start and end of the sequence. Defaults to `False`.
* **name** (*string* *,* *optional*) – Name of the sequence. Defaults to `None`.
### Returns
The periodic sequence.
### Return type
[DynamicDecouplingSequence](https://docs.q-ctrl.com/references/qctrl-open-controls/qctrlopencontrols/DynamicDecouplingSequence.md#qctrlopencontrols.DynamicDecouplingSequence)

## Notes

The periodic sequence <sup>[1](#id2)</sup> is parameterized by duration $\tau$ and number of
offsets $n$. The sequence consists of $X_{\pi}$ operations at offsets given by

$$
t_i = \frac{\tau}{n + 1} \;,
$$

where $i = 1, \cdots, n$.

## References

* <a id='id2'>**[1]**</a> [L. Viola and E. Knill, Physical Review Letters 90, 037901 (2003).](https://link.aps.org/doi/10.1103/PhysRevLett.90.037901)
