optimization for trajectory input variables

조회 수: 1 (최근 30일)
Nivedhitha S
Nivedhitha S 2019년 8월 20일
댓글: Nivedhitha S 2019년 8월 30일
Dear community,
I am a newbie in matlab. I would like to know the method to define an objective function for an optimization function. I have a set of 6 ode equations which has 4 input variables for its calculation. I would to like to manipulate these 4 input variables sunch that one of my variable (ODE) can be optimized (maxima/minima). How to implement an objecive function and obtain the trajectory profile for these 4 input variables? I would like to obtain a continuous time varying profile for these 4 input variables. The system is a continuous time varying setup with interdependant ode. Please give me any suggestions for the same.

답변 (1개)

Prabhan Purwar
Prabhan Purwar 2019년 8월 27일
Hey,
The problem basically consists of an optimizing system of differential equations.
A model with varying parameters can be used to find the best-fitted model parameters for the same.
This can be achieved either through MATLAB or Simulink, both are discussed below, suitability relies upon the complexity and nature of the problem.
Following illustrates formation and solution to a differential equation.
  • Using MATLAB
k1 = ...; % set constant k1
k2 = ...; % set constant k2
k3 = ...; % set constant k3
f = @(t,y)[9-k1*y(2)^2*y(1)+k2*y(1)^2 ; k3*y(2)^2+y(1)*y(2)]; % define differential equations
tspan = [0 20]; % set interval of integration
u0 = ...; % set initial condition for u
omega0 = ...; % set initial condition for Omega
y0 = [u0 ; omega0]; % set vector of initial values
[T Y] = ode45(f,tspan,y0); % call integrator
plot(t,y(:,1),'-o',t,y(:,2),'-o') % plot results
Links:
  • Using Simulink
Links:
Optimization of differential equations
  • Using MATLAB
Making use of fminsearch(), fminbnd() and optimset() functions or optimization toolbox for complex problems after solving the differential equation.
Links:
For real-time optimization of differential equation refer to Simulink
  • Using Simulink
Model can be optimized as illustrated in video
Link:
  댓글 수: 1
Nivedhitha S
Nivedhitha S 2019년 8월 30일
Thank you for detailed help and suggestions.
But i was asking about the possibility of a trajectory optimization for my problem.

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

카테고리

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