You are on page 1of 8

Independent University, Bangladesh

School of Engineering and Computer Science


Department of Electrical & Electronic Engineering

Course ID EEE-314L

Course Title Numerical Technique Lab

Student Name MD AKIF RAHMAN

Student ID 1711396

Experiment No: 04
Experiment Name: Study on solving Differential Equations.
Objectives:
➢ To get introduced with basic MATLAB commands to solve Differential Equations.
➢ Perform different operations on given examples.
➢ Verify MATLAB output of the operations with the theoretical hand calculations.

Apparatus:
➢ MATLAB

Theory: (In Short)


• Differential Equations
A differential equation is an equation which contains one or more terms and the derivatives of one variable
(i.e., dependent variable) with respect to the other variable (i.e., independent variable)
dy/dx = f(x)
Here “x” is an independent variable and “y” is a dependent variable
For example, dy/dx = 8x

• Types of Differential Equations


Differential equations can be divided into several types namely
1. Ordinary Differential Equations: An ordinary differential equation (also abbreviated as
ODE), in Mathematics, is an equation which consists of one or more functions of one
independent variable along with their derivatives. A differential equation is an equation that
contains a function with one or more derivatives. But in the case ODE, the word ordinary is used
for derivative of the functions for the single independent variable.
2. Partial Differential Equations: In Mathematics, a partial differential equation is one of the
types of differential equations, in which the equation contains unknown multi variables with their
partial derivatives. It is a special case of an ordinary differential equation.
3. Linear Differential Equations: A linear equation or polynomial, with one or more terms,
consisting of the derivatives of the dependent variable with respect to one or more independent
variables is known as a linear differential equation.
A general first-order differential equation is given by the expression:
dy/dx + Py = Q where y is a function and dy/dx is a derivative.
The solution of the linear differential equation produces the value of variable y.
4. Nonlinear differential equations
5. Homogeneous Differential Equations: A differential equation of the form f(x,y)dy = g(x,y)dx is said to be
homogeneous differential equation if the degree of f(x,y) and g(x, y) is same. A function of form F(x,y) which
can be written in the form kn F(x,y) is said to be a homogeneous function of degree n, for k≠0. Hence, f and g
are the homogeneous functions of the same degree of x and y. Here, the change of variable y = ux directs to an
equation of the form;
dx/x = h(u) du which could be easily integrated.
6. Nonhomogeneous Differential Equations

• Applications of Differential Equations


1. Population Problems
2. Falling Objects
3. Mixing Problems
4. Harmonic Motion
5. bonds between atoms or molecules
6. Systems of the electric circuit consisted of an inductor, and a resistor attached in series.

MATLAB Commands:

Operations Commands
‘y’ is the differential
dsolve(y) equation.
Differential Equation Solver
dsolve(y, cond) ‘cond’ is the initial or
boundary condition
Prettyprint symbolic ‘Y’ is the solution for
pretty(Y)
expressions equation ‘y’
Plotting Differential Equation ‘Y’ is the solution for
ezplot (Y, [min, max])
solution equation ‘y’
Experiments:
Write down appropriate MATLAB code to solve the following Differential Equations:
• Differential Equation
𝑑𝑦
a. = −𝑎𝑦
𝑑𝑡
𝑑𝑦
b. = −𝑎𝑦 𝑎𝑛𝑑 𝑦(0) = 1
𝑑𝑡

𝑑2𝑦
c. = −𝑎2 𝑦
𝑑𝑡2

𝑑𝑦 𝑥𝑦 − 𝑦 2
d. =
𝑑𝑥 𝑥2
𝑑𝑦 𝑦 𝑦
e. = 𝑡𝑎𝑛( ) +
𝑑𝑥 𝑥 𝑥
Result Analysis:
Discussion:
Write down the procedure you followed to do the experiments(in short) and the result analysis.

For this experiment, we studied the process of solving ordinary differential equation with the
help of MATLAB and further compared the values of MATLAB results with that of the
theoretical ones. The MATLAB command that was used for solving the differential equation is
dsolve (equation, initial conditions). To show the value of the root or solution, we used another command
which is pretty(root). The values of MATLAB results and that of theoretical ones are not entirely identical
for all the experiment problems. However, the solution of equation a and b seems to match completely with
that of the theoretical ones. For theoretical calculation, we used our knowledge of MAT221 course to solve
differential equations which have been shown in detail in calculation part.
LAB REPORT RUBRICS

Student Name MD AKIF RAHMAN Student ID 1711396


Course Title Numerical Technique Lab Course Code EEE 314L
Term Spring Summer Autumn Year 2022
Experiment Experiment
Study on solving Differential Equations 04
Name Number
Submission
17-July,2022 Due Date 8-July,2022
Date
Tick () on the appropriate box (any one from 1 to 5)
Rubrics (weight) Accomplished Intermediate Developing Intermediate Novice
(5) (4) (3) (2) (1)
Understanding Defined experiment Intermediate Defined Intermediate Defined
experiment’s requirements and between experiment between novice experiment
requirements assume circuit developing requirements and and developing. requirements and
(25%) specifications, if any, and assume circuit assume circuit
properly. accomplished. specifications, if specifications, if
any, moderately. any, poorly.

Building Circuit Conducted Intermediate Conducted Intermediate Conducted


and conducting experiment properly between experiment between novice experiment
experiment (25%) by building developing & moderately by and developing. poorly by
simulation circuit accomplished. building building
using required simulation circuit simulation circuit
specification. using required using required
specification. specification.

Result and Analyzed and Intermediate The results are Intermediate The results are
analysis (25%) interpreted the results between analyzed to some between novice analyzed poorly
properly using the developing extent according and developing. due to
converter parameters. and to specified incomplete
accomplished. requirements. simulation.

Remarks / Answered the given Intermediate Answered Intermediate Answered the


Answering questions correctly between partially the given between novice given questions
Question (25%) and describe the developing questions and and developing. incorrectly and
remarks properly. and describe the describe the
accomplished. remarks remarks poorly.
moderately.

Sub Total 80
Deduction for late
submission / any
other issue
Total (100%)
10% of Total

You might also like