Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 7

Lab-Report#01

Course Title:

Communication System

Title:

ONLINE LAB REPORT

Submitted to:

Engr: Atif Mahmood Khaki

Submitted by:

Sadam Hussain

GCPKI00857

Department:

BEEE (5th)

Department of Electrical Engineering

1
Experiment#01

Introduction to Matlab basic concepts

The name MATLAB stands for Matrix Laboratory. MATLAB was written originally to
provide easy access to matrix software developed by the LINPACK (linear system package)
and EISPACK (Eigen system package) projects. MATLAB [1] is a high-performance
language for technical computing.

It integrates computation, visualization, and programming environment. Furthermore,


MATLAB is a modern programming language environment: it has sophisticated data
structures, contains built-in editing and debugging tools, and supports object-oriented
programming. These factors make MATLAB an excellent tool for teaching and research.
MATLAB has many advantages compared to conventional computer languages (e.g., C,
FORTRAN) for solving technical problems. MATLAB is an interactive system whose basic
data element is an array that does not require dimensioning.

Exercise

Plot sine and cosine graph in Matlab that ask user to input amplitude and
frequency And Also change their graph colour and clearly indicate which
graph is for sine and cosine respectively.

Required Software:

Matlab

Procedure:

1) Open Matlab in your system.


2) After few minute loading a matlab command window will appear on the screen as shown
in picture below.

2
3) Type your code in command window or Select New Live Script from the bar window as
shown in picture below.

3
4) By selecting live Script Editor a New window of live scrip editor will appear on the
screen

5) Type your code in Live editor window.


6) After typing code of desire problem select Run button given above the scrip window in
live editor manu.

7) If there is any syntax error or logical error after running th code try to resolve the error
properly.

4
Matlab Code:

Matlab Output :

5
Discussion :

Sine and cosine are trigonometric ratios and those are complementary to each other. So when

one will plot a graph of both these functions, the graph will just differ by a phase of angle 90

degrees .A cosine wave is a signal waveform with a shape identical to that of a sine wave ,

except each point on the cosine wave occurs exactly 1/4 cycle earlier than the corresponding

point on the sine wave. A cosine wave and its corresponding sine wave have the same

frequency, but the cosine wave leads the sine wave by 90 degrees of phase.

Conclusion:

 In this experiment problem of sine and cosine wave is performed in order to obtain
the graph and date from the graph desired to us.
 Matlab is language of technical computing.
 Matlab has a large number of functionality which is easy to understand and solve the
complex engineering problems .
 Matlab allow user to quickly solve the complex problems.
 Matlab is user centric software as we can get help by typing help all the command can
be found out.

6
7

You might also like