Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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(1)=1 of the question as shown in the picuture, y'=x2+3xy3x2. The following are my codings:
syms x y; % Define symbolic variables
syms ode;
syms sol;
% Define the ODE
ode =(x^2+3*x*y)/(3*x^2);
% Separate variables using manual method, then input into here
eqn = int(1/(x^2+3*x*y), y)== int(1/(3*x^2), x);
% Solve the equation
sol = dsolve(eqn);
% Display the general solution
disp('General Solution:');
disp(sol);
% Define the initial condition
initial_condition = sol.subs(x,1)==1;
% Solve for the constant of integration
constant = solve(initial_condition);
% Substitute the constant into the general solution to find the particular solution
particular_solution = sol.subs(constant);
% Display the particular solution
disp('Particular Solution:');
disp(particular_solution);
However, it outputs errors as shown below, i don't know where did i do wrong. Please correct and teach me.
Error using mupadengine/feval2sym_NaNsingularity
No differential equations found. Specify differential equations by using symbolic functions.
Error in dsolve>mupadDsolve (line 334)
T = feval2sym_NaNsingularity(symengine,'symobj::dsolve',sys,x,options);
Error in dsolve (line 203)
sol = mupadDsolve(args, options);
Error in ODE_Q1(line 12)
sol = dsolve(eqn);
Related documentation
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beginning VB 2008 Databases

Authors: Vidya Vrat Agarwal, James Huddleston

1st Edition

1590599470, 978-1590599471

More Books

Students also viewed these Databases questions