Page 1 of 1
PID controller
Posted: Thu Aug 05, 2010 4:34 pm
by Nabil
Hi
Is it possible to build a PID controller with vensim, that is how to differentiate and integrate the the difference terms?
Regards
Nabil
Posted: Fri Aug 06, 2010 9:45 am
by bob@vensim.com
Differentiation is always a sampling process, especially in real implementations. Generally the most sensible way to do differentiation in a Vensim model is to use
time derivative = (variable of interest - delayed variable of interest) / sampling interval
delayed variable of interest = INTEG((variable of interest - delayed variable of interest)/sampling interval,variable of interest)
Where sampling interval is bigger than TIME STEP (usually > 2*TIME STEP if it is not simply TIME STEP).
Posted: Fri Aug 06, 2010 11:40 am
by Nabil
Thank you
Nabil