CONTINUOUS_MODEL PSmooth2 ABSTRACT "SMOOTHed (no events) version of P-controller. Variable setpoint. Approximates real behaviour with a sine function. No event calls. Input control signal <= 0 (usually schedule) overrides control action. Output in control mode varies between 0 and 1, as measured signal increases and PropBand is positive. If PropBand is negative, and measured signal increased, output varies instead between 1 and 0. Multiple output links. MV 980105 variable set point available hi and lo values are calculated from propotional band PropBand > 0 => lo < hi (VAV control -type) PropBand < 0 => lo > hi (Radiator control -type)" EQUATIONS hi:= SetPoint + PropBand/2 ; lo:= SetPoint - PropBand/2 ; RampPos := (Measure - (hi + lo)/2) / (hi - lo); OutSignal= IF OverRide <= 0 THEN OverRide ELSE_IF RampPos > 0.5 THEN 1 ELSE_IF RampPos < -0.5 THEN 0 ELSE (sin (RampPos*PI) + 1) / 2 END_IF ; LINKS GENERIC MeasureLink Measure; GENERIC OverRideLink OverRide; GENERIC SetPointLink SetPoint; GENERIC PropBandLink PropBand; FOR i = 1, n GENERIC OutSignalLink[i] OutSignal END_FOR; VARIABLES GENERIC RampPos LOC "Normalized measurement signal" GENERIC Measure IN "Sensed signal" GENERIC OutSignal OUT "Control signal" GENERIC OverRide IN "Control action override signal, <= 0 overrides" GENERIC SetPoint IN "Setpoint" GENERIC PropBand IN "Proportional band; > 0 -> cooling ctrl; < 0 -> heating" GENERIC hi LOC "Sensed signal at which OutSignal becomes 1" GENERIC lo LOC "Sensed signal at which OutSignal becomes 0" MODEL_PARAMETERS INT n SMP "Number of OutSignal links" END_MODEL