praveen wrote:> > Hello, > I am getting the sine sine after bandpassing the square signal > > waiting for eply > parveenThe first question that comes to mind is, "Why?", but never mind that. (There are simple oscillators that generate simultaneous sine and cosine. Look for some on http://www.dspguru.com ) Either delay your sine -- that requires as long a circular buffer as the lookup table you would need to generate it -- or integrate it, which may require some scaling, but uses much less memory. Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������
cosine generation from sine signal in DSP
Started by ●July 28, 2003
Reply by ●July 29, 20032003-07-29
Reply by ●July 29, 20032003-07-29
A two-level discrete-time square wave signal is not properly sampled. You may also end up with aliased components in the passband of your passband filter. BEWARE! Dirk Dirk A. Bell DSP Consultant (ISO work to do) "praveen" <praveenkumar1979@rediffmail.com> wrote in message news:ff8a3afb.0307290315.268e436c@posting.google.com...> Hello, > I am getting the sine sine after bandpassing the square signal > > > waiting for eply > parveen
Reply by ●July 29, 20032003-07-29
"Jon Harris" <jon_harrisTIGER@hotmail.com> wrote in message news:<3f245a33$1_4@newsfeed>...> I had to do this recently and, for my application, using the common identity > cos = sqrt(1-sin^2) worked for me. It wasn't a signal generator, I just > needed a single value and in only 2 quadrants, so this technique might not > be appropriate for you.What about the price of the sqrt calculations??? JaaC> > "praveen" <praveenkumar1979@rediffmail.com> wrote in message > news:ff8a3afb.0307280251.3d106579@posting.google.com... > > Hello, > > I want to generate cosine signal from the sine signal avaiable. > > What all different techniques by which i can do it???? > > Hilbert transform????how to do this using hilbert transform. > > Any reference or suggestion will be great.... > > This sin and cos is for Iq demodulation > > I will be first testing it on matlab and then on DSP > > waiting for reply > > with regards > > praveen
Reply by ●July 29, 20032003-07-29
I was using the SHARC, so it's really not bad at since it has an instruction called RSQRTS. It generates a seed to for 1/sqrt(x) that can be used to calculate it rapidly using a successive approximation method. You can get an excellent approximation in 9 cycles and an exact value in 13. Also, as I mentioned, I wasn't implementing a signal generator. I only need to perform the calculation occasionally so speed isn't that critical. "Jaime Andres Aranguren Cardona" <jaime.aranguren@ieee.org> wrote in message news:14a86f87.0307291215.81ed005@posting.google.com...> "Jon Harris" <jon_harrisTIGER@hotmail.com> wrote in messagenews:<3f245a33$1_4@newsfeed>...> > I had to do this recently and, for my application, using the commonidentity> > cos = sqrt(1-sin^2) worked for me. It wasn't a signal generator, I just > > needed a single value and in only 2 quadrants, so this technique mightnot> > be appropriate for you. > > What about the price of the sqrt calculations??? > > JaaC > > > > > "praveen" <praveenkumar1979@rediffmail.com> wrote in message > > news:ff8a3afb.0307280251.3d106579@posting.google.com... > > > Hello, > > > I want to generate cosine signal from the sine signal avaiable. > > > What all different techniques by which i can do it???? > > > Hilbert transform????how to do this using hilbert transform. > > > Any reference or suggestion will be great.... > > > This sin and cos is for Iq demodulation > > > I will be first testing it on matlab and then on DSP > > > waiting for reply > > > with regards > > > praveen
Reply by ●July 29, 20032003-07-29
Depends on where your noise energy is. Low frequency noise is not good for an integrator. For example, if DC offset counts as noise, the integrator is not gonna be happy... I'd rather have a zero at z=1 than a pole!! Mind you, after reading on, I see the sine came from bandpass filtering a square wave. If the bandpass filter is at the fundemental frequency of the square wave, then the integrator could be best. Make it a little leaky tho! Pole at z=0.9999! Jerry Avins <jya@ieee.org> wrote in message news:<3F25C72C.E3FB6B22@ieee.org>...> Eric Jacobsen wrote: > > > > > > Or take the derivative... > > Too noisy. Integrate and invert. > > Jerry