digital-brain/content/zettels/time_delay.md

84 lines
2.5 KiB
Markdown
Raw Normal View History

2023-10-13 11:57:17 +02:00
+++
title = "Time Delay"
author = ["Dehaeze Thomas"]
draft = false
+++
Tags
:
## Phase induced by a time delay {#phase-induced-by-a-time-delay}
Having some time delay can be modelled by a transfer function having constant amplitude but a phase lag increasing with frequency.
Such phase lag is linearly proportional to the time delay and to the frequency:
\begin{equation}
\phi(\omega) = -\omega \cdot T\_s
\end{equation}
with:
- \\(\phi(\omega)\\) the phase lag in rad
- \\(\omega\\) the frequency in rad/s
- \\(T\_s\\) the time delay in s
## Estimation of phase delay induced in sampled systems {#estimation-of-phase-delay-induced-in-sampled-systems}
Consider a feedback controller implemented numerically on a system with a sampling frequency \\(F\_s\\).
The time delay associated with the limited sampling frequency \\(F\_s\\) is:
\begin{equation}
\phi(\omega) = -\frac{\omega}{F\_s}
\end{equation}
with:
- \\(\phi(\omega)\\) the phase lag in rad
- \\(\omega\\) the frequency in rad/s
- \\(F\_s\\) the sampling frequency in Hz
Some values are summarized in Table [1](#table--tab:time-delay-phase-lag).
<a id="table--tab:time-delay-phase-lag"></a>
<div class="table-caption">
<span class="table-number"><a href="#table--tab:time-delay-phase-lag">Table 1</a>:</span>
Phase lag as a function of the frequency (relative to the sampling frequency )
</div>
| Frequency | Phase Delay [deg] |
|----------------|-------------------|
| \\(F\_s/100\\) | -3.6 |
| \\(F\_s/10\\) | -36.0 |
| \\(F\_s/2\\) | -180.0 |
This is the main reason to have a sampling frequency much higher than the wanted feedback bandwidth is to limit the phase delay at the crossover frequency induced by the time delay.
Having a sampling frequency a 100 times larger than the crossover frequency is a good objective.
<div class="exampl">
Take the example of a controller implemented with a sampling time of 0.1ms (10kHz sampling frequency).
```matlab
t_delay = 1e-4; % Delay [s]
G_delay = exp(-t_delay*s);
```
The induced phase delay as a function of frequency is shown in Figure [1](#figure--fig:time-delay-induced-phase-lag).
At the Nyquist frequency (5 kHz), the phase lag is 180 degrees.
<a id="figure--fig:time-delay-induced-phase-lag"></a>
{{< figure src="/ox-hugo/time_delay_induced_phase_lag.png" caption="<span class=\"figure-number\">Figure 1: </span>Phase lag induced by a time delay" >}}
</div>
## Bibliography {#bibliography}
<style>.csl-entry{text-indent: -1.5em; margin-left: 1.5em;}</style><div class="csl-bib-body">
</div>