two point boundary vale problem

조회 수: 1 (최근 30일)
Lewis Watson
Lewis Watson 2011년 3월 14일
I have a problem asking me to solve a second order diffrential equation of the form;
-u"(x)+x^2u(x)=f(x), 0<x<1 subject to u(0)=0 and u(1)=0
i have to create a function file which implements a function y=e^(-x^4) cos(20x)
and another function file with first line of the form;
function [ x,U ] = centraldiff(n,f) with inputs n is such that n+1 is the number of divions of [0,1] and the second input is a string which gives the name of a function describing the function.
i will be extremly thankful for any help, as i have noclue to this lab question.
thankyou

답변 (1개)

Sarah Wait Zaranek
Sarah Wait Zaranek 2011년 3월 14일
The function bvp4c should be able to get you started.
There are some nice examples in the documentation for bvp4c that should help you out. http://www.mathworks.com/access/helpdesk/help/techdoc/ref/bvp4c.html

카테고리

Help CenterFile Exchange에서 Ordinary Differential Equations에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by