agyness Andrew

5 Reputation

2 Badges

10 years, 319 days

MaplePrimes Activity


These are questions asked by agyness Andrew

[*********************************************************************************]
[* DO NOT EDIT PROBLEMS TO REMOVE THE ORIGINAL QUESTION! -Carl Love as moderator *]
[*********************************************************************************]
% use Euler formula to compute function y for i = 1:N if i ==1 legend('numerical y','exact y','numerical g','exact g') function g = f2g(a,b) % f(x) = x g = (b-a)/6*(a + 4*(a+b)/2 + b);
function [y g] = ques5
% using Simpson Formula to approximate the integration
% input:
% f(x): [a b]


end
% use Euler formula to compute function y
for i = 1:N
    if i ==1

legend('numerical y','exact y','numerical g','exact g')

function g = f2g(a,b)
% f(x) = x
g = (b-a)/6*(a + 4*(a+b)/2 + b);


ican use matlab to solve this problem but not maple
please help

 

Please respond me by email, thanks.

wingwatson7@gmail.com

 

Here is the original question http://www.mapleprimes.com/ViewTemp.ashx?f=21095_1386318320/screen06.12.13.docx , replaced by the questioner.  She/he must not do such things.

 

 

 

 

The differential equation dy/dt = t / (2-y), y(0)=1 fails the tests in section 5.1 at y=2. [ f(t,y) is undefined at y=2 and the y-partial derivative of f(t,y) is also undefined there. ] If a solution stays away from y=2, there is no problem at all. Try a few different initial conditions and summarize your findings. Use the Runge-Kutta order 4 method with a fixed step size.

Hint: You may find Maple's solution of the differential equation helpful:

s1 := dsolve({diff(y(t),t)= t/(2-y(t))}, y(t)); 

In the solution _C1 is a constant to be determined using the initial conditions.

Page 1 of 1