# Discrete time sine wave generation near nyquist

I'm trying to wrap my head around how to generate sine-waves out of a DAC near the Nyquist frequency (or determining how close I can get for reliable results). So if I want to generate a 499 Hz sine wave using a 1 kSPS DAC, I will calculate each sample:

$$y(t) = \sin(2 \pi 499 \ t)$$

Converting this to discrete time:

$$y[k] = y\left( \tfrac{k}{1000} \right) = \sin \left(2 \pi 499 \frac{k}{1000} \right)$$

I end up with something like this:

The red line shows the 499 Hz signal, while the blue dots show the DAC sample. I get these large amplitude fluctuations. I know it's common to use a reconstruction filter to get rid of DAC images, which I always thought of as a low-pass filter from DC to Nyquist, which wouldn't really help get rid of the amplitude fluctuations...or would it?

Is there a better approach for generating sine waves? Or is there just simply a limit I cannot exceed (and what is the limit)?

• so this is a "conventional" DAC and not an oversampled sigma-delta DAC? if that is the case, and you really want to generate good sinusoids up to nearly Nyquist, you will need a helluva sharp brickwall LPF as an anti-imaging filter. Nov 19, 2020 at 22:53
• oversampling (which is one of the techniques of sigma-delta) is far cheaper than an analog brick-wall LPF. Nov 19, 2020 at 22:56