Professional Documents
Culture Documents
2022
ID Number : 150718061
OBJECTIVE
To become familiar with the analytical solutions of differential equations using Matlab and
graphical illustrations of the solutions.
BACKGROUND
Using Matlab, it is possible to solve differential equations in two different ways. First, a
symbolic solution by manipulating the symbols in the equation(s) can be obtained much like one
would do with pencil and paper. Second way is to find a numerical answer which may be
approximate. Both have advantages and disadvantages depending on the application.
In this lab, symbolic solutions and their numerical evaluations will be studied. Symbolic Math
Toolbox in Matlab, is required.
Some of the commands mainly to be used in this session are; syms, diff, dsolve and eval.
We prefer the analytical method in general because it is faster and because the solution is exact.
Nevertheless, sometimes we must resort to a numerical method due to limitations of time or
hardware capacity.
1
Lab Date: 02.03.2022
Think of dy and dx each as discrete variables. So you could do something like multiply both
sides by dx and end up with:
Now, integrate the left-hand side dy and the right-hand side dx:
So there is our general solution: Any constant multiple of is a solution to the differential
equation, which makes sense.
Now, we will solve the same DE 1 by using Symbolic Math Toolbox in Matlab,
S=
2
Lab Date: 02.03.2022
PRELIMINARY
Preliminary study report must be submitted to the ues system before lab begins.
If you do not submit your preliminary study report, you will get 0 directly for the related
lab.
Solve differential equations (DE 2) and (DE 3) analytically on a paper with pencil. Then
take a photo of your solution and paste this image under the related question.
( )
( ) ( ( )) ( )
( )
( ) ( ) ( )
3
Lab Date: 02.03.2022