EveryCircuit
Contact
Reviews
Home
smorgana
modified 9 years ago

Random Noise Generator

14
6
392
04:43:57
Following the pattern from @hurz, Random number generator, amplify simulator numerical noise.
published 9 years ago
hurz
9 years ago
Pseudo random noise. This is caused by the way how computer approximate the sin wave function. From math point of view sin(a)-sin(a+2pi)=0 but computer can't do that, cuz sin is not available as closed correct function like non periodic others. So gnu mathlib has to do an approximation to sin and this will cause every periode a very tiny numerical difference to the previous one. Keyword is "Taylor" development. Hope this helps.
smorgana
9 years ago
thanks for the explanation. i saw that you were amplifying the difference between sin at 0 and 360 degree phase. ideally there would be no difference, but i guessed they were numerically slightly different.
hurz
9 years ago
Yes, the difference ideal suppose to be zero. Check this i played a little with the error of both numerical results. http://everycircuit.com/circuit/4981154721038336
Redstone_guy
4 years ago
360° = 0°
zorgrian
4 years ago
@R this is quite correct in the sense of rotational rotationalism
andybutler
1 month ago
While the sin calculation will have inaccuracies I'd expect the exact same results if you do the same calculation twice. I suggest that the unpredictable signal we see here is caused by dithering. ?

EveryCircuit is an easy to use, highly interactive circuit simulator and schematic capture tool. Real-time circuit simulation, interactivity, and dynamic visualization make it a must have application for professionals and academia. EveryCircuit user community has collaboratively created the largest searchable library of circuit designs. EveryCircuit app runs online in popular browsers and on mobile phones and tablets, enabling you to capture design ideas and learn electronics on the go.

Copyright © 2026 by MuseMaze, Inc.     Terms of use     Privacy policy