06-26-2012 02:50 PM
Is there a way to have two sinewaves that play one after another withtout discontinuity? I know that I can can use the Phase parameter and I calculate it like this:
y=Amplitude_A*sin(Frequency*time + Phase_A)
Bias_B=Amplitude_A*sin(Frequency*time + Phase_A)
Since Time = 0 :
Isolating Phase_A :
(and i convert this in degrees)
So I have a function as smooth as possible but it does not work if I have a sinewave from 800 (max) to 200 (min) followed by another one of 600 (max) to 400 (min). When my Bias is greater the the Amplitude (just like this example), I have no way to go from the end of the first sinewave to the beggining of the second one without discontinuity or ramping. Ideally, I would like this transition to be a curve.
Sorry if it is not clear, english is not my first language.
Thanks in advance
Solved! Go to Solution.
07-02-2012 08:32 AM
I think the only way to ensure that there won't be a discontinuity it to make sure that you are switching the sinewave at a common point. Since we aren't changing the frequency and we aren't changing the central point of the amplitude (500 in both waves), the best way to get that change with minimal discontinuity is to change when crossing that 500 line. There won't be any phase shift necessary, since the central point there should be at the 0 or pi phase of both waves depending on whether you are crossing low to high or high to low. You could also implement windowing during the transition period to minimize discontinuity, but that will change the shape of your signal over that period.