Please help me with code for the below ode

조회 수: 5 (최근 30일)
Karthik K
Karthik K 2019년 8월 26일
댓글: Walter Roberson 2019년 8월 27일
  댓글 수: 6
Karthik K
Karthik K 2019년 8월 27일
This is a base excitation probem in vibration
equation_of_motion.jpg
Walter Roberson
Walter Roberson 2019년 8월 27일
You have
function f = forced_coulomb_base(t,x,y)
so forced_coulomb_base expects to be passed three variables.
You have
[t,x,y]=ode45(@forced_coulomb_base,tspan,x0,y0);
ode45 passes two parameters to the function: the independent variable in the first parameter, and the boundary conditions in the second parameter.
You cannot calculate two separate ode by passing them as additional parameters and expecting additional outputs: all boundary conditions must be passed in a single variable, and all calculations must be returned in a single variable.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

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