Home
Wood Heating
Choices
Data
System Design
Controller
Control Logic
Software Design
Electrical Schematic
Simple system w/ storage
Domestic Hot Water
Heat Storage
Solar Hot Water
Introduction
System Components
User Guide
Programming Guide
Failsafe Design
Sample Application
LM35 Sensor Assembly
Pinout Info
Poor Man's VS Circ
Journal
Plastic Pipe Collector
Thermistors
Forum Solar-TodayWood-TodayBurn Planner
<Prev Table Of Contents Next>

Differential Rules

Differential rules set an element based on the difference between two other elements. The template is as folllows:

Set Element1 (to TRUE) if Element2 is at least Element3 greater (or less) than Element4 with a deadband of Element5

NOTE: Differential rules have an implied 'to TRUE' as part of the template. If the conditions in a differential rule are satisfied, the target element will be set to TRUE.

NOTE 2: Differential rules ALWAYS set the value of the target variable. It;s set to TRUE if the rule criteria are met, and FALSE if not.

The differential rules have a lot of options and a lot of resulting complexity. There are five elements involved, and all of them are required.

Example: Solar Circulator

A differential rule might be used to control a solar panel circulator, for instance. In that case, we might want the circulator to be on any time the panel temperature is at least 5 degrees above the storage tank temperature. The rule might look like this:

Set SolarCirc if PanelTemp is at least SeveralDegrees greater than StorageTemp with a deadband of CoupleDegrees

In this example, these elements are used:

  1. SolarCirc: A discrete output that turns on the solar panel circulator
  2. PanelTemp: A sensor input that reads the panel outlet temperature
  3. SeveralDegrees: A variable with a current value of 5
  4. StorageTemp: A sensor input that reads the storage tank temperature
  5. CoupleDegrees: A variable with a current value of 2

The first element is the target. It is set to TRUE (a numeric value of 1) if the rule is triggered. In most cases, the target element will be a discrete output that controls a pump or a valve. In our example, it's SolarCirc.

The second element is the first of two values to be compared. It will typically be either a sensor value or a variable. In our example it's PanelTemp.

The third element is the differential. In our example it's a variable with a value of 5. Note that a variable must be used - it's not possible to enter a number directly. On advantage is that we can change the value of the variable at any time to tune the system's performance.

The fourth element is the second value that's part of the comparison. In the example, it's the storage tank temperature. It could also be a variable.

The fifth element is deadband (sometimes called hysteresis). This helps prevent excessive cycling. A more detailed discussion of deadband can be found below.

Example: Thermostat

A fairly common need is to implement a rule that has the same effect as a thermostat. For instance, we might want to open Zone Valve 1 if the top floor temperature is below the top floor setpoint. Here's a differential rule:

Set ZoneValve1 if TopFloorTemp is at least ZeroDegrees less than TopFloorSetpoint with a deadband of CoupleDegrees

In this example, these elements are used:

  1. ZoneValve1: A discrete output that opens the top floor zone valve.
  2. TopFloorTemp: A sensor input that reads the top floor temperature
  3. ZeroDegrees: A variable with a value of 0
  4. TopFloorSetpoint: A variable that contains the desired temperature for the top floor
  5. CoupleDegrees: A variable with a current value of 2

In this case, we don't need a differential term. The ZeroDegree variable effectively disables the differential calculation. We still nead a variable for deadband.

Deadband

Deadband is a value that's added (or subtracted) from the temperature difference depending on whether the target element is active or not. It has the effect of preventing short cycling.

If you had a rule that tuned on a circulator whenever a measured temperature was less than 70 degrees, you might have a situation where the temperature was near 70 degrees, but fluctuating between 69.9 and 70. Without deadband, the circulator would cycle on and off with every fluctuation.

With that same rule and a two degree deadband, the system will subtract two degrees from the setpoint whenever the circulator is off. That means that when the temperature hits 70, the circulator turns off. It will stay off until the temperature hits 68 degrees.

In this way, the temperature will cycle between 68 and 70. The actual numeric value of the deadband variable can be changed to tune system performance.

For rules with a 'less than' term such as our thermostat example, deadband is subtracted from the fourth element (setpoint in this case). For rules with a 'greater than' term, the deadband is added.

<Prev Table Of Contents Next>