# Feedback and Hysteresis

## Feedback

A system is said to have feedback (system in this context is very general and could be anything from an electrical circuit, hydraulic pump, or even machinery), when some observation of the systems output is considered at the input to the system.

An example of this would be trying to balance a wooden dowel in the palm of your hand. In this sense, you are the system, the input to the system would be the position you want the dowel to be in, and the output of the system is how you move the dowel in order to keep it there. You can visually observe when the dowel is about to fall, so you can move your hand accordingly. This system uses visual feedback in order to stabilize the output (i.e., balance the dowel upright).

Feedback loops are considered to be ether “positive” or “negative”, where positive feedback reinforces the output signal and negative feedback opposes the output signal.

Figure 1 shows a general example of a system with a negative feedback loop. In this illustration, signal flows in the direction of the arrows, and the triangle blocks either increase or attenuate the signal.

You can think of a negative feedback system as having two opposing sides trying to act on the output of the system. The open loop gain is trying to push the output as high as it can, but is opposed by the feedback loop (which is trying to pull the output signal back down low). There will eventually form an equilibrium point between the two sides, where, if the signal goes above the point, the feedback loop will pull it back down, and if goes below the point, open loop gain will push it up.

Figure 2 shows a plot of the input/output relationship of the system in Fig. 1. For this plot the open loop gain “G” is assumed as large as possible (i.e. infinite), and the feedback path attenuation is assumed to be 50%. Over time you can see that the output stabilizes at twice the input, giving the system an overall gain of 2. In general, the gain of a negative feedback system is controlled directly by the amount of attenuation in the feedback loop. More attenuation in the feedback loops (i.e., less signal being fed back), will cause a larger overall gain increase.

Now, in a positive feedback system (like Fig. 3), the positive and negative terminals on the summation block are switched. Both the feedback loop and the open loop gain are trying to push the output signal up.

Systems like this in theory would increase gain forever (as in Fig. 4). In reality though there is always a physical limitation that would stop the increase in gain. For circuits and opamps, this physical limit is the saturation property. Since the output voltage cannot exceed the rail voltages, a positive feedback system would drive an output signal into saturation (leveling out) instead of continuing on to infinity.

When positive feedback systems have some form of output saturation (or limiting), it creates a form of hysteresis in the system.

## Hysteresis

Hysteresis is the property of a system where the current output of the system depends on the previous state (or history) of the system in addition to input.

We can see the effects of hysteresis by examining a Schmitt trigger comparator. A Schmitt trigger circuit is shown in figure 5. You can notice the similarities between the actual circuit, and the positive feedback example in figure 3 from above. The feedback path may look a little different but functions identically (the R1 and R2 resistors form a voltage divider, essentially attenuating the output signal being fed back to the amp by 50%).

The general opamp equation:

${V_{Out}} = {G_{open\:loop\:gain}}*({V_{non - inverting}} - {V_{inverting}})$

The equation can be used to govern how this circuit functions. It is important to note that voltage in a circuit does not change instantaneously, but takes a small amount of time for current to propagate through a circuit (often in the nano to pico second range). This is why there is both an $Output_{current}$ and an $Output_{next}$ value in our next equation. You can think of it as output current being the present output state of the opamp, and output next as being the output state the amp is trying to drive to.

$Outputnext = G(Attenuation * Outputcurrent--InputSignal)$

For this example we make the following assumptions:

• The input signal has a range from +/-5V
• Attenuation of the feedback loop is 50%
• The system saturates at +/-5V

To analyze this circuit we will consider two different output states.

Initially when the system is powered on (no previous output), the input signal starts out at -5V. This causes the output signal to be driven into positive saturation (leveling out at 5V).

$G(.5 * (0)--( - 5V)) = G * 5V = 5V$

This is the state that represents when the input to a Schmitt trigger is below the upper threshold. Input values that are less than 2.5V, will simply cause $Output_{next}$ to be driven back into positive saturation (this can be thought of as like trying to push a ball up a hill. Until you get to the top of the hill, if you leave the ball at any point on the hill, it just rolls back down (i.e. being pushed back into positive saturation). Once youâ€™re past the top of the hill, the ball will roll down the other side.

Figure 6 shows the input ranges for this particular state. Input values in the green range will cause the output to be driven to 5V and remain in the same state, while input values in the red range will cause the output to be driven to -5V and change states.

$Outputnext = G(.5 * (5V)--Input) = G(2.5V--Input)$

You can see from this equation, now that a positive voltage is being fed back into the input of the opamp, you will need an input voltage above 2.5V to change the polarity of $Output_{next}$.

So now for instances if the input changed to 3.5V, this is past the 2.5V threshold so instead of being driven back to positive saturation, the output is driven towards negative saturation (the output signal changes to -5V).

$G(.5 * (5)--(3.5V)) = G * - 1V = - 5V$

At this point the Schmitt trigger changes states, so now instead of a positive voltage being fed back to the input, a negative voltage is being fed back (changing the threshold from 2.5V to -2.5V). This state represents when the input signal has risen above the upper threshold and the output has asserted. You can see that the Schmitt trigger will not return to the previous state until the input signal falls below -2.5V (hence the lower threshold). Figure 7 (like Fig. 6) shows an illustration of the input values will cause the Schmitt trigger to change states or remain in its current state.

$Outputnext = G(.5 * ( - 5V)--Input) = G( - 2.5V--Input)$

You can start to see that the upper and lower thresholds of a Schmitt trigger are dependent on what state the circuit is in. This is a form of hysteresis in that the current state was determined by prior input into the system.