Code covered by the BSD License
-
[sys_foc]=ora_foc(r,N,w_L,w_H...
Filename: ora_foc.m
-
l(neq,t,x,u)
-
sys_Dg(neq,t,x0,xf)
J_x0 and J_xf are row vectors of length n.
-
sys_Dh(neq,t,x,u)
-
sys_Dl(neq,t,x,u)
l_x should be a row vector of length n.
-
sys_activate
-
sys_g(neq,t,x0,xf)
-
sys_h(neq,t,x,u)
xdot must be a column vector with n rows.
-
sys_init(params)
Here is a list of the different system information paramters.
-
main.m
-
View all files
from
Solution of Fractional Optimal Control Problems
by Christophe Tricaud
Solution of Fractional Optimal Control Problems using Rational Approximation
|
| sys_h(neq,t,x,u)
|
function xdot = sys_h(neq,t,x,u)
global sys_params A B C D problem
% xdot must be a column vector with n rows.
alpha = sys_params(1);
w_L = sys_params(2);
w_H = sys_params(3);
N = sys_params(4);
% [A,B,C,D] = ssdata(ora_foc(-alpha,N,w_L,w_H));
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
if problem == 1
%LTI
xdot = A*x + B*(-(C*x+D*u)+u);
elseif problem == 2
%LTV
xdot = A*x + B*((C*x+D*u).*t+u);
elseif problem == 3
%Bang-Bang
tau = x(end);
xdot = A*x(2:end-1) + B*u;
xdot = [tau.*(C*x(2:end-1)+D*u);tau.*xdot;0];
else
error();
end
|
|
Contact us at files@mathworks.com