Question: In my attempt in using MATLAB to solve for the general solution and particular solution when y ( 1 ) = 1 of the question
In my attempt in using MATLAB to solve for the general solution and particular solution when y of the question as shown in the picuture, The following are my codings:
syms x y; Define symbolic variables
syms ode;
syms sol;
Define the ODE
ode xxyx;
Separate variables using manual method, then input into here
eqn intxxy y intx x;
Solve the equation
sol dsolveeqn;
Display the general solution
dispGeneral Solution:;
dispsol;
Define the initial condition
initialcondition sol.subsx;
Solve for the constant of integration
constant solveinitialcondition;
Substitute the constant into the general solution to find the particular solution
particularsolution sol.subsconstant;
Display the particular solution
dispParticular Solution:;
dispparticularsolution;
However, it outputs errors as shown below, i don't know where did i do wrong. Please correct and teach me
Error using mupadenginefevalsymNaNsingularity
No differential equations found. Specify differential equations by using symbolic functions.
Error in dsolvemupadDsolve line
T fevalsymNaNsingularitysymengine'symobj::dsolve',sysxoptions;
Error in dsolve line
sol mupadDsolveargs options;
Error in ODEQline
sol dsolveeqn;
Related documentation
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
