10-30-2018 06:57 AM
Any tips on how I can model this without using the sine wave function and using the sine math function instead and output it using the waveform chart? I know the sine function takes input in radians so I was trying to convert to radians and then add a phase shift. any help would be much appreciated
Solved! Go to Solution.
10-30-2018 07:17 AM
Shouldn't that be 2*pi/frequency*t? I think it's wt+p, and t=1/f? Not sure, it's been a while.
Also, you're using "i" as time, but it probably needs scaling (for instance t=i/1024, if you want i=1024 to be a full phase.
10-30-2018 09:33 AM
you're close
1) It looks like you are converting the units incorrectly. To go from degrees to radians, it should be x* pi/180. It looks like you have it as 180/pi
2) You're stepping time (t) by the for loop index. That increments by 1 so your time step is once per second. Too slow. Step it by something smaller like i*dt (at least at the Nyquist Rate).