(URGENT) How can I write the following matlab code written for
24 hours, for 365 days? I just want to see how it is done in such
optimizations. in MATLAB
X=24;
Tmin=0;
Tmax=1;
Tf=1;
Hmin=0;
Hmax=1;
N= [0 0 0 0 0 0 0 0 0 0 0 0 0];
T= optimvar('T',X,'LowerBound',Tmin,'UpperBound',Tmax);
H=optimvar('H',X,'LowerBound',Hmin,'UpperBound',Hmax);
A=optimvar('A',X,'LowerBound',0); F =
optimproblem('ObjectiveSense','max');
TA.Constraints.c1=T>=Tf;
TA.Constraints.c2=H>=Hmin;
TA.Constraints.c3=A<=((T-H));
TA.Objective= T-A;
sol = solve(TA);
(URGENT) How can I write the following matlab code written for 24 hours, for 365 days? I just want to see how it is done
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am