Electrical resource!

Monday, December 18, 2006

Convolution Using Matlab 7.0

The questions might be arising in your minds that..
* What is convolution?
* how we can write the program for convolution?
Convolution is the point to point multiplication add and drag process.when some signal is passed through some system then this system has some impulse response denoted by h(x), and our original signal is denoted by 'X' .Then we can write convolution as,
'f(X)=X*h(x)'
To write the program for convolution in matlab just copy the following coding and paste it in matlab empty file!
Matlab coding for Convolution!

'p(x)=(1+2x+3x^2+5x^4)(1-3x-x^2+x^3+3x^4)'
x=32*[5 3 2 1]
n=0:1:3
figure(1)
axis equal
stem(n,x,'linewidth',2.5)
xlabel('Sample Time')
ylabel('Amplitude')
title('INPUT SIGNAL')
grid
h=[3 1 -1 -3 1]
n=0:1:4
figure(2)
axis equal
stem(n,h,'linewidth',2.5)
xlabel('Sample Time')

Sunday, December 17, 2006

Amplitude Modulation using Matlab 7.0

Its the first project given by my professor..Firstly i make a search for it on internet and collected some resource..then with the help of some of my mates i completed it successfully.Here is the Matlab code for Amplitude Modulation using Matlab 7.0.Now i am trying to generate code for frequency modulation.Now a days CDMA (code division multiplexing) technology is used which has less noise in the out put as compared to other FDMA or TDMA.
Matlab code for AM
t=0:0.001:1;
vd=8*cos(2*pi*5*t);
vc=0.1*cos(2*pi*15*t);
ft=vc.*vd;
am=ft+vc;
figure(1)
plot(t,vd);
figure(2)
plot(t,vc);
figure(3)
plot(t,am);
Here is the output of the coding!
Carrier signal

Orignal singal(information signal)Amplitude Modulated signal

Friday, December 15, 2006

What is Matlab...And for what purpose it is used?...The most simplified approach to Matlab!

MATLAB is a high-performance language for technical computing. It integrates computation, visualization, and programming in an easy-to-use environment where problems and solutions are expressed in familiar mathematical notation.Here you can know the behaviour of the signal when you are dealing with the electronics or electrical engineering,it has all the features such as convolving,filtering,adding,multiplexing,amplitude modulation,frequency modulation etc etc...! Here i'll show my assignments and projects in matlab 7.0 and my personal researches in Matlab.Matlab is simple to use as compared to c++,java and other languages.It has alot of predefined keyword and thats the plus point of matlab ,you don't have to write the coding for keywords.soo that was little bit about matlab further i'll post my projects in matlab.I'm electrical engineering student at university of engineering and technology pehshawar,nwfp,pakistan, and I'm in 5th semester.soo that was little info about me so for any error or mistake or question please feel free to contact me thanks.
regards,
shahbaz khan .

How to Convert continues Signal to Discrete signal Using Matlab 7.0

How to convert continues signal to discrete signal using Matlab 7.0 ?...here is the way to convert the continues sinusoidal sin signal into discrete time signal the only replacement you have to do is that,to replace the plot command to stem command i-e for sinusoidals ploting you have to use plot(t,any signal) but to plot it in discrete you have to write =>> stem(t,any signal) instead of writing the plot command.

Coding for discrete signal in Matlab
t=0:0.01:0.5;
y=sin(2*pi*5*t);
stem(t,y);
title('discrete signal')

Graph for discrete Signal

How to draw sine wave in Matlab 7.0

Here i'm with the most basics fo matlab.The question might be rising in your minds that what is sine or cos wave? ..the answer to this question would be like that the sine wave is a sinusoidal wave having the shape as shown in the below figure...In electrical technology we transmit the singnal in the form of sine,cos or tan wave..our new modern techology in pakistan termed as Gsm is based on these kind of signals ...now five mobile companies are working in pakistan named as mobilink,telenor,paktel,ufone and warid,the technology is based on signals transmitting and receiving which is done by these kind of sinosoids signals.Here in pakistan 2.5G (2.5 generation)...which has gprs along with the other feature ,the companies which does not allows gprs are having 2.0G..the most modern is the 3.0G which support video conferencing and thats used in some Europe countries...For third generation there must be a compatible cell phone which support the 3g.
Coding for sine wave in Matlab
t=0:0.001:1;
y=sin(2*5*pi*t)
plot(t,y)
Sine wave

Sunday, December 10, 2006

Electrical resource centre

We'll be here for posting soon!..plz check back soon!

eXTReMe Tracker