sheldon
|
Linkern,
Assuming that the simulator tolerances have been set appropriately, then you are probably seeing interpolation error. The DFT samples the waveform at regular time intervals. In general, the time point that the simulator choses are not the same time points that the DFT needs. So the DFT interpolates the simulator results to estimate the time points required for the DFT. By using different times steps you are reducing the error in the estimation, interpolation error. There are many things to try
1) Easy Set max_step to less than 1/2 the time step size of the DFT, this can be computationally expensive, it makes simulation time longer but usually gives good results.
2) More accurate add a zvcvs to the output to sample the output and then perform the DFT on the sampled output. zdft (sampled 0 out 0) zvcvs td=10u ts=10n
You will need to add a little extra time to the simulation and shift the DFT times to compensate for the delay in the zvcvs.
3) Use the Fourier integral it is not sensitive to interpolation error fourTransform ( out 0 ) fourier fund=1k points=256
Good Luck,
Sheldon
|