Signal Interference

I was expecting that the addition of a pi radians phase shifted signal resulting in complete signal cancellation. But the plot shows a distortion signal. Why does the cancellation leaves some signal?

 {SinOsc.ar() + SinOsc.ar(phase: pi)}.plot;

This threw me for a second. Notice the range of the plot output. It is between 1e-07 and -1e-07, so very small. If you plot the following you will get a better representation of what you want:

{SinOsc.ar(100) + SinOsc.ar(100, phase: pi)}.plot(minval:-1, maxval:1);

Sam

1 Like

Great! Thank you. So that very small thing represents indeed only the voltage? Is that correct to interpret it like this?

pi is approximated (represented as a float) - sin(pi) in the language yields 1.2e-16ā€¦

so looks like a rounding error.

may be some further error from interpolation in table lookup.

That noise is not that small ( ~ -70 db if Iā€™m reading it right)

1 Like