## feedbackDivider(vout, vref, resitorOrderOfMagnitude, maxTolerance, resistorTolerance, series)

import electronics.rlc.resistorDividers-1

Calculate a voltage divider with real world resistances used for power regulator feedback.

import electronics.rlc.resistorDividers-1;
``` feedbackDivider( 5V, // input voltage 1.2V, // desired output voltage 100kOhm // order of magnitude for the divider ) ```
 vout The desired output voltage of the power supply. vref The feedback reference voltage of the power supply. resitorOrderOfMagnitude The order of magnitude for the resistors (optional). If not given, one resistor will be in 1-10Ohm range. maxTolerance Maximum tolerance allowed for ideal resistor case (optional). If not given, 1% is used. resistorTolerance The tolerance of the used resistors (optional). Used for calculation of worst case values. If not given, 1% is used. series The resistor series to use. If not given, E24 is used. return value Array of realisable voltage dividers.

The difference the between voltage divider calculator and this function is that this function calculates the output voltage of the regulator with respect to feedback and the used divider. The errors would be calculated related to the output.

The result is an array containing the matching resistor pairs, output voltages, and the error in percents:

• rUpper - The value for the upper resistor in the divider.
• rLower - The value for the lower resistor in the divider.
• errorPercent - The error of the divider in percents.
• vout - The output voltage in case of ideal resistors.
• voutMin - The worst case voltage minimum considering given resistor tolerances.
• voutMax - The worst case voltage maximum considering given resistor tolerances.
For more details on resistor series, please see electronics.datasets.resistors.series-1. If you want to design a voltage divider, and you are interested in the midpoint voltage of the divider, please see calculateVoltageDivider.