Insights Blog
-- Browse All Articles --
Physics Articles
Physics Tutorials
Physics Guides
Physics FAQ
Math Articles
Math Tutorials
Math Guides
Math FAQ
Education Articles
Education Guides
Bio/Chem Articles
Technology Guides
Computer Science Tutorials
Forums
General Math
Calculus
Differential Equations
Topology and Analysis
Linear and Abstract Algebra
Differential Geometry
Set Theory, Logic, Probability, Statistics
MATLAB, Maple, Mathematica, LaTeX
Trending
Featured Threads
Log in
Register
What's new
Search
Search
Search titles only
By:
General Math
Calculus
Differential Equations
Topology and Analysis
Linear and Abstract Algebra
Differential Geometry
Set Theory, Logic, Probability, Statistics
MATLAB, Maple, Mathematica, LaTeX
Menu
Log in
Register
Navigation
More options
Contact us
Close Menu
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Forums
Mathematics
MATLAB, Maple, Mathematica, LaTeX
How to change the frequency values inside a time domain signal phase
Reply to thread
Message
[QUOTE="tworitdash, post: 6483091, member: 220671"] The problem I am having is simple. I have a Gaussian spectrum initially. Like this, Process 1: [CODE=matlab]S = m0/sqrt(2*pi*sigma^2) * exp(-(vel_axis - mu).^2/(2*sigma^2)); [/CODE] Here, mu is the mean velocity (frequency) and sigma is the standard deviation. vel_axis is the axis on which I am calculating this Gaussian spectrum. Then, with the help of random phase generators and using an inverse Fourier transform, I calculate the time domain signal of this spectrum. [CODE=matlab]s = ifft(fftshift(sqrt(N) .* sqrt(S) .* exp(1j .* Theta))); %timedomain [/CODE] Here Theta is the uniform random phase between -pi to pi and N is the number of sampling points. Process 2: Now, I want to change the phase of the signal in the time domain to see the changes again in frequency domain. [CODE=matlab]s_modified_in_time_domain = abs(s) .* exp(1j .* unwrap(angle(sig)) .* (-1)) [/CODE] Here, I have multiplied (-1) so that I will have a spectrum around the value of -mu instead of mu. That is the idea. However, the spectrum is not around -mu and it is shifted to the positive axis of velocity (frequency). I have attached a plot to this post where it can be seen by the blue signal. The red signal is the actual time-domain signal of Process 1 in the frequency domain. And the Gaussian is around mu. Here mu is 5 [m/s]. Process 3: Instead of doing the modification in the time domain, if I modify it in process 1 and in the equation of S, if I use -mu, instead of mu I get the desired result. Therefore, I don't know why I get a shift in the plot of Process 2. Any idea if the equation for lower case s (equation number 2) does something weird? In the plot: Blue is process 2 in the frequency domain Red is Process 1 with mu = 5 Yellow is Process 1 with mu = -5 The Blue plot should resemble the Yellow plot but it shifted towards the right. I want to do the change in the time domain and see the effect in the frequency domain. How can I use Process 2 in a good way. Just to show this effect I have used N as 4. So, it is very poorly sampled. The code is done in MATLAB. This is just the idea. the code is lengthy with other things.[ATTACH type="full" alt="Screen Shot 2021-04-19 at 4.51.20 PM.png"]281797[/ATTACH] [/QUOTE]
Insert quotes…
Post reply
Forums
Mathematics
MATLAB, Maple, Mathematica, LaTeX
How to change the frequency values inside a time domain signal phase
Back
Top