komm.RootRaisedCosinePulse
Root raised cosine pulse. It is a pulse with waveform given by $$ h(t) = \frac{\sin ( 2 \pi f_1 t ) + 4 \alpha t \cos ( 2 \pi f_2 t )}{\pi t ( 1 - (4 \alpha t)^2 )}, $$ where $\alpha$ is the roll-off factor (which must satisfy $0 \leq \alpha \leq 1$), $f_1 = (1 - \alpha) / 2$, and $f_2 = (1 + \alpha) / 2$. Its spectrum is given by the square root of the spectrum of the raised cosine pulse.
The root raised cosine pulse is depicted below for $\alpha = 0.25$, and for $\alpha = 0.75$.
Attributes:
-
rolloff
(float
) –The roll-off factor $\alpha$ of the pulse. Must satisfy $0 \leq \alpha \leq 1$. The default value is
0.0
.
Examples:
>>> pulse = komm.RootRaisedCosinePulse(rolloff=0.25)
>>> pulse.waveform([-0.75, -0.50, -0.25, 0.00, 0.25, 0.50, 0.75]).round(4)
array([0.2379, 0.6218, 0.9432, 1.0683, 0.9432, 0.6218, 0.2379])
>>> pulse.spectrum([-0.75, -0.50, -0.25, 0.00, 0.25, 0.50, 0.75]).round(4)
array([0. , 0.7071, 1. , 1. , 1. , 0.7071, 0. ])