Adam Cooman

Previous

Steady-state Simulation
under multisine excitation

Next

3. Transient simulators

In a transient analysis, the circuit behaviour is simulated at discrete time-steps. The user can control the start time (tstartt_{\mathrm{start}}), stop time (tstopt_{\mathrm{stop}}) and the time-step (tstept_{\mathrm{step}}) used in the analysis. The continuous-time derivatives in the circuit have to be approximated in the discrete-time transient simulation. The way this approximation is performed is referred to as the integration method, which can be chosen by the user as well.

These 4 parameters (tstartt_{\mathrm{start}}, tstopt_{\mathrm{stop}}, tstept_{\mathrm{step}} and the integration method) have to be set by the user. Once the time-domain waveforms are calculated by the simulator, they can be transformed to the frequency domain in a post-processing step.

Choosing the time-step

Both a fixed and variable time-step can be used in most commercially available transient simulators. Since we’d like to calculate the spectrum of the signals with the Fast Fourier Transform (FFT), the time samples have to be equally spaced in time. This equal spacing is automatically obtained when a fixed time-step is used in the transient simulation. We will always use a fixed time-step in our time-domain simulations. If a variable time-step is used, the data can be interpolated to the fixed grid in time, but this will introduce interpolation errors. Alternatively, the simulator can be forced to simulate every time-point on an equally-spaced time-grid while the underlying time-step is still left free to take smaller steps when needed [1].

The fixed time step in a transient analysis is chosen such that the highest significant harmonic generated in the circuit can be represented in the simulation. The sample frequency fsample f_{\mathrm{sample}} should be at least 2fmax2\aleph f_{\mathrm{max}} to allow proper sampling of all harmonics without aliasing. To prevent spectral leakage when calculating the spectra using the FFT, the sample frequency should be chosen as an integer multiple of the frequency resolution.

It can happen that the corresponding time step 12fmax\frac{1}{2\aleph f_{\mathrm{max}}} cannot be represented by a finite amount of digits. An fsample f_{\mathrm{sample}} of 300kHz300\mathrm{kHz}, for example, will result in a time-step tsample t_{\mathrm{sample}} of 3.33μs3.33\ldots\mathrm{\mu s}. Rounding errors in the simulator can then introduce weird effects. Increasing fsample f_{\mathrm{sample}} to 400kHz400\mathrm{kHz} yields a nicer tsample t_{\mathrm{sample}} of 2.5μs2.5\mathrm{\mu s} which can easily be written correctly to the netlist.

Choosing the start and stop-time

At least one period of the multisine should be simulated, so tstopt_{\mathrm{stop}} should be larger than 1fres\frac{1}{ f_{\mathrm{res}}}. Due to the initial conditions present in the circuit, a transient will be present in the signal. The simulation should be run long enough to allow the transient to damp out such that the circuit reaches steady-state. The length of the transient depends on the quality factors of possible resonances in the circuit, so it should be checked carefully whether transient is still present in the signals. This can be done by inspecting the obtained spectrum for leakage, or by subtracting the final period from the previous ones as is shown in Figure 3.1. To create that figure, a transient simulation with 44 periods was run. The final period was subtracted from the three previous periods and the logarithm of the norm of the remainder of that subtraction is plotted. From such a plot, it can be concluded that the circuit reaches steady-state after 1.51.5 periods of the multisine, so tstopt_{\mathrm{stop}} should be set to 2.52.5 periods of the multisine.

example of a circuit transient

Figure 3.1 Result of subtracting the final period in a transient simulation from the previous ones. It is clear that the circuit reaches steady-state after 1.5 periods.

The start time of the simulator tstartt_{\mathrm{start}} controls when the simulated points are returned to the user. Internally, the simulation starts always at t=0t=0, but to limit the amount of data stored to disc, the start time can be set. The transient from the initial conditions to steady-state contains a lot of information about the circuit behaviour, so our simulations always use tstart=0t_{\mathrm{start}}=0.

Choosing the integration method

It is best to set the integration method of the transient analysis to trapezoidal [3]. Unlike other integration methods, trapezoidal integration doesn’t introduce artificial damping into the circuit. Trapezoidal integration still introduces frequency warping in the circuit. With frequency warping, it is as if the circuit is being simulated at different frequencies as the ones specified in the multisine. The relation between the original frequencies and the warped frequencies is known and given by

fwarp=1πtstan(πforiginaltsample)f_{\mathrm{warp}}=\frac{1}{\pi t_{\mathrm{s}}}\tan\left(\pi f_{\mathrm{original}} t_{\mathrm{sample}}\right)

If, for example, a single tone at a frequency of 1GHz1\mathrm{GHz} is applied to a bandpass filter and the whole circuit is simulated with a sample frequency of 4GHz4\mathrm{GHz}, the original frequency is warped to 1.27GHz1.27\mathrm{GHz}. If the bandpass filter has a narrow band around 1GHz1\mathrm{GHz}, it can happen that the tone is filtered out, while it should not have been. To overcome this issue, a larger sample frequency should be used, or the warping should be taken into account properly on beforehand.

Transforming to the frequency domain

Once the simulation has been performed over several periods of the multisine with a fixed time-step, the last period of the time domain signals can be used to obtain the spectrum using the FFT. It is best to normalise the FFT such that the magnitude of a frequency line corresponds to the peak value of each corresponding tone in the spectrum.

To be able to compare the transient analysis results with the harmonic balance results, only the positive frequencies are saved, but are multiplied by 22 to maintain the power in the signal.

Previous
1 2 3 4 6 7 8 9 10 11 
Next