Info

This question is closed. Reopen it to edit or answer.

why are there noise signals with increasing time?

2 views (last 30 days)
Sampath reddy
Sampath reddy on 1 Apr 2012
Closed: MATLAB Answer Bot on 20 Aug 2021
The following is a program for simulation of a laser beam with dither modulation.
clear all
clc
freq=1000000; %samples per second
tmax=1; %time
Kac=0.1555; %slope constant
c=3*10^8; %light velocity
lam=632.8*10^-9; %wavelength of beam
wd=2*pi*400; %dither angular frequency
M=250; %constant
k=2*pi/lam;
wc=2*pi*c/lam;
n=tmax*freq;
I1=zeros([n 1]);
L=.28; %optical path length in meters
Vhfo=6.5; %constant
dell=0;
omega=pi/240; %rotation rate
for ii=2:n,
t(ii)=(ii-1)/freq;
L=.2800000784+(1e-7*sin(2*pi*250*t(ii))); %optical path length with dither modulation
dell=(4*((L/4)^2)/c)*omega; %change in lengths l1 and l2
l1(ii)=L+dell;
l2(ii)=L-dell;
q=round(L/lam);
v1=q*(c/l1(ii));
w1=2*pi*v1;
v2=q*(c/l2(ii));
w2=2*pi*v2;
I1(ii)=cos((w2-w1)*t(ii)+M*sin(2*pi*wd*t(ii))); %modulated output
end
plot(I1);
I'm modulating l1 and l2 and from l1 and l2 the modulation is being passed to E01 and E02 and from there on to I1 . In addition to modulation, with increasing time there are spikes being built up on the signal in I1 which is not supposed to happen. The same thing when simulated in simulink doesnt have spikes. I'm unable to find the mistake. Any help anyone!! Thanks!!!
  5 Comments
Jan
Jan on 3 Apr 2012
@Sampath reddy: Your program does not contain any comment, but several unexplained magic numbers like 0.1555, 632.8, 250, 0.28, 6.5, .2800000784. It is not mentioned which algorithm your are using. Some computations are strange, e.g. "var=((1/l2)-(1/l1));" - but this variable is never used.
Finally you do not mention, why you expect, that there are no spikes. Perhaps the theory does expect spikes. We cannot check this easily, but you should be an expert, because you have implemented this code.
So please post the relevant details.
Sampath reddy
Sampath reddy on 3 Apr 2012
Now the comments are given. According to the equations there should be no spikes. But there are spikes. can you help now?

Answers (0)

This question is closed.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!