I'm new to GEKKO and so my question could be stupid. I want to estimate some parameters of my model, it's a SIR model. I've read many times the documentation and watch many videos of professor John Hedengren but GEKKO it's still hard to understand for me. This is my code:
from gekko import GEKKO
tab_data = [275.5,317,457.34,646,888.67,1236.67,1619.34,2077.34]
total_active_data=[59999725.,59999684.33333334,59999558.66666666,\
59999385.33333334,59999158.33333333,59998823.,\
59998474.66666666,59998053.33333333]
population = 60e6
m = GEKKO()
v = m.MV(0.97,0,9.7)
v.STATUS = 1
v.FSTATUS = 0
tau = m.MV(0.066,0.0594,0.099)
tau.STATUS=0
tau.FSTATUS = 0
I0 = m.Var(100)
S0 = m.Var(population-I0.value-275)
R0 = m.CV(value=tab_data)
R0.FSTATUS=1
m.time = [i for i in range(len(tab_data))]
m.Equation(S0.dt() == -v*S0*I0/total_active_data)
m.Equation(I0.dt() == v*S0*I0/total_active_data - 0.07*I0-tau*I0)
m.Equation(R0.dt() == tau*I0)
m.options.IMODE = 5 # MHE
m.options.EV_TYPE = 2 # Objective type
m.options.NODES = 3 # Collocation nodes
m.options.SOLVER = 3 # IPOPT
m.solve()
If I run it, there is the following error
Equation without an equality (=) or inequality (>,<)
I think that I have set all the parameters and the variables in the right way (I want to allow that v and tau could change in time and R0 is the one on which I compute my objective function) but maybe I'm wrong.