Electrical engineering

Circuit properties

Electrical potential energy

Electrical potential energy is the potential energy embodied by charged particles in an electric field. A voltage gradient creates an electric field with strength equal to voltage over distance, and free electrons in the field are negatively charged particles that want to move towards the positive end of the voltage gradient (which would be a lower-energy state). By doing work to separate charges inside a battery, we can create a voltage gradient and ‘generate’ potential energy.

Another way to look at it is that voltage is a measurement of the amount of energy lost when one coulomb of charge moves from one point to another (doing work in the process).

Current

Current is the rate of flow of positive charge in a circuit. The unit of charge is the coulomb. One electron has a charge of 1.6\e{-19} \u{C}, and conversely, one coulomb of charge contains 6.3\e{18} electrons. Current is the rate of flow of charge through a point in a circuit. Work is done when charges flow across a potential difference.

i = \frac{\d{q}}{\d{t}}

The current flowing from point A to point B is notated as i_\t{AB}. A small arrowhead is drawn on the wire between A and B, with the arrowhead pointing towards B.

Kirchoff’s current law states that “the algebraic sum of currents in a network of conductors meeting at a point is zero.” In other words, the sum of the currents into a point in a circuit equals the sum of the currents out. This is just conservation of charge.

Voltage

The voltage between two points in a circuit is the amount of work done by each unit of charge that flows between those two points. That energy is converted / lost when a charge moves from a higher to a lower potential.

v = \frac{\d{U}}{\d{q}}

The voltage at point A with respect to point B is notated v_\t{AB}. A separate arrow is drawn ‘across’ the component separate to the wire, with the arrowhead pointing towards A. Often times, voltage in a circuit is given with respect to a ground point instead, and is notated v_A. This ground point is arbitrary, placement of the ground serves to offset the voltages in a circuit by some value.

Kirchoff’s voltage law states that “the directed sum of voltages around a closed loop is zero.” This counts for any closed loop in a circuit, no matter how complex.

Resistance

Resistance is the amount of energy lost by an electrical charge as it repels or collides with other charges in a conducting material. This loss of energy is directly proportional to the current through the conductor.

Ohm’s law relates resistance, current, and voltage. It requires that the current and voltage have opposite polarity. If the current and voltage have the same polarity, energy is gained instead.

v = iR

The current through an ideal wire (a 0\ohm resistor) depends on the current through the rest of the circuit. Contrast this with a resistor, where the current through the resistor is strictly determined by the resistance value and the voltage across it.

The resistance of a conductor is given by the resistivity \rho (dependant on material and temperature), axial length l, and cross-sectional area A:

R = \rho \x \frac{l}{A}

Power

Power is the rate at which energy is supplied or received by the charges in a circuit. All electrical devices require a continuous supply of energy to operate. Energy is supplied by a component if the voltage and current across that component have the same polarity, and is consumed if they have opposite polarity (like for a resistor).

p = \frac{\d{U}}{\d{t}} = iv

The equation assumes that power is being consumed (the polarities of the current and voltage are opposite).

AC power

When voltage and current are both sinusoids, we can find the resultant power by multiplying them:

v(t) = V_p \cos(\omega t + \phi_v)
i(t) = I_p \cos(\omega t + \phi_i)
p(t) = V_p I_p \cos(\omega t + \phi_v) \cos(\omega t + \phi_i)

In AC

  • double frequency
  • a vertical offset about 0

Components

Open and closed circuits

An open circuit is equivalent to a resistor of infinite resistance. The current through an open circuit is zero, because there is no closed path for charge to flow through. The voltage across an open circuit is probably the input voltage if there’s just one voltage source. No current flows, so the voltage drop across any resistor in the circuit is zero.

A closed circuit is an ideal wire (a 0\ohm resistor).

Voltage and current sources

An ideal voltage source ensures a constant voltage across the terminals. It supplies or draws as much current (energy) as is needed to accomplish this, because a voltage is just the amount of energy gained or lost by a unit charge moving across two points.

An ideal current source ensures a constant current through itself. It creates as much of a voltage drop across itself as is needed to accomplish this, because current flows when a voltage is applied.

Any current source can be replaced with a voltage source of a specific value, and vice versa.

Components in series and parallel

Components are in series if there is exactly one path for charge to flow between them (there are no junctions between them). The current flowing through each of the components is equal, but the voltage splits proportionally to the resistance of each component. Adding a resistor in series will increase the total resistance.

Components are in parallel if they are connected together at both ends. The voltage across each of the components is equal, but the current splits proportionally to the resistance of each component. Adding a resistor in parallel will decrease the total resistance.

The resistance of n resistors in series is:

R_\text{total} = \sum_{i=1}^{n} R_i

The resistance of n resistors in parallel is:

R_\text{total} = \1{\sum_{i=1}^{n} \1{R_i}}

Voltage and current dividers

For n resistors in series with a total voltage drop of v_T across them, the voltage across any one resistor R_1 is:

v_1 = v_T \left( \frac{ R_1 }{ R_1 + \cdots + R_n } \right)

For n resistors in parallel with a total current of i_T through them, the current through any one resistor R_1 is:

i_1 = i_T \left( \frac{ \1{R_1} }{ \1{R_1} + \cdots + \1{R_n} } \right)

Analysis tools

Node voltage analysis

Node voltage analysis is a method of finding a voltage in a circuit that doesn’t have easily reducible series and parallel resistors. It works best when the circuit contains only two or three essential nodes.

Pick one essential node to be the ground point, and pick a second essential node A to find the voltage of. Label the currents going out of this node as i_1, i_2, and i_3 (for however many paths meet at that node). From Kirchoff’s current law, we know that i_1 + i_2 + i_3 = 0.

Next, write expressions for each of these currents relative to the reference voltage v_A. For a path between A and ground that contains only a resistance R_1 and a voltage source v_1, we can find the current through the resistor (and therefore down the whole path) with \frac{v_A - v_1}{R_1} as per Ohm’s law.

Writing out an equation for each path and substituting them into the KCL equation gives us the following:

\frac{v_A + 4}{3.3} + \frac{v_A - 29}{1.8} + \frac{v_A - 26}{1.8} = 0

This can be simplified to the following:

\left(\1{3.3} + \1{1.8} + \1{1.8}\right) \x v_A + \left( \frac{4}{3.3} + \frac{-29}{1.8} + \frac{-26}{1.8} \right) = 0

Subtraction and then division gives us the result, that v_A = 20.75. We can now find the current through each of the branches by substituting the value of v_A into each of our original path current equations.

Superposition theorem

The voltage and current in a circuit are linear properties, meaning that the total voltage (or current) through a component in a circuit is equal to the sum of the voltage (or current) contributions from the voltage and current sources individually.

To find the contributions of each source individually, we replace every current source in the circuit with an open circuit (so that the current through that point is 0\u{A}), and every voltage source with a closed circuit (an ideal wire, so that the voltage drop over that point is 0\u{V}). We then add each source back in individually, analyse the circuit each time, and sum the individual voltages and currents to find the voltage and current in the original circuit.

Thévenin’s theorem

Thévenin’s theorem can be used to replace a network of resistors, voltage sources, and current sources with a simpler equivalent. When we use the theorem, we have the option of removing a component temporarily, using the wires that connected to that component as the terminals, and then putting the component back afterwards. This gives us a useful way to model the voltage and current through that component as the resistance of the component varies.

The Thévenin-equivalent voltage v_\t{th} of a circuit is equivalent to the open-circuit voltage across the terminals A-B. No current can flow in an open circuit, so any resistors will have a voltage drop of zero (voltage being proportional to the current through a component).

The Thévenin-equivalent resistance R_\t{th} of a circuit can be found by setting all voltage and current sources to zero (replacing voltage sources with ideal wires and current sources with open circuits) and finding the equivalent resistance of the resultant resistor network. Note that I don’t currently have the tools to work with Y and \Delta networks (see Y-Δ_transform.

The Thévenin-equivalent current i_\t{th} is equal to the short-circuit current of the original circuit.

Transducers

An input transducer (or sensor) converts a non-electrical signal to an electrical signal. An output transducer (or actuator) performs an action in response to an electrical signal.

We’re given the acronym SMART (Systems of Monitoring, Analysis, and Response Technology).

Sensors can be categorised by the underlying electrical property modulated: voltage, current, resistance, capacitance, or inductance.

Strain gauges

G is the gauge factor (constant property of the material), \epsilon is change in length \frac{\Delta l}{l_0}:

\frac{\Delta R}{R_0} = G \x \epsilon

Resistive temperature sensors

The resistance of a resistive temperature sensor is given by the temperature coefficient \alpha and a known resistance and temperature T_0 and R_0. As temperature increases, the resistance of the sensor also increases (as per resistivity under the notes for materials science).

R(T) = R_0 (1 + \alpha(T - T_0))

Some materials work better for resistive temperature sensors than others. For 500-1000°C, Ni works fine and is cheap. The best material is Pt, which has a very linear temperature/resistivity relationship over a range of -190°C to 660°C. A platinum temperature sensor with resistance 100\ohm at 0°C is labelled “Pt 100”.

Resistive temperature sensors are roughly a couple of centimetres long.

Thermistors

The resistance of a thermistor (semiconductor-based temperature sensor) is given by the material constant \beta and a known reference resistance R_0 and temperature T_0.

R(T) = R_0 e^{\beta(\1{T} - \1{T_0})}

This yields a negative exponential relationship, such that increasing the temperature decreases the resistance of the thermistor. This is because the semiconductor used (Si or Ge) is an insulator when cold, but with heat the valence electrons loosen up and the material becomes a conductor. Past a certain point, the electrons begin to move too much and the resistivity of the material begins to increase again.

The negative relationship between temperature and resistance creates a risk for ‘runaway thermal heating’, where as the resistance decreases, the power through the thermistor increases (as per P = \frac{v^2}{R}), heating the thermistor further. Despite the exponential relationship, the output can be treated as approximately linear over a small temperature range (they’re often used for temperatures ranging from 0°C to 100°C). Note the negative \alpha coefficient, since this is a negative relationship.

R(T) \approx R_0 (1 - \alpha(T-T_0))

Thermistors are much more sensitive than resistive temperature sensors, meaning they can be made much smaller.

Voltage divider to convert resistance to voltage

We can use a voltage divider to determine the resistance of a resistive transducer, converting \Delta R to \Delta v. In the following image, R_x is the resistive transducer, R is a second known resistor, and v_\t{out} is the output voltage proportional to R_x. This yields a negative relationship, which is useful for a thermistor; swap R and R_x to get a positive relationship instead.

v_\t{out} = \left( \frac{R}{R+R_x} \right) \x v_S
R_x = \left( \frac{v_S}{v_\t{out}} - 1 \right) \x R

There are a few issues with using a voltage divider to find the resistance of a transducer:

  • Any variation in v_S (such as from noise or decreasing battery voltage) affects v_\t{out}, leading to inaccurate measurements.
  • If the transducer is a strain gauge, any variation in temperature will affect v_\t{out}, leading to inaccurate measurements.
  • v_\t{out} will have a DC offset (voltage at R_0 will not be 0), which means that the signal cannot be amplified without also amplifying the voltage offset. If v_\t{out} ranges from 2.2V to 2.6V, \Delta v will only be 0.4V. Trying to amplify \Delta v to a usable range will boost the absolute voltages well past standard logic levels.

Wheatstone bridge

A Wheatstone bridge is a circuit for measuring the resistance of a transducer without any DC offset or variations due to the input voltage or ambient temperature.

v_\t{out} = v_A - v_B = \left( \frac{R_3}{R_1+R_3} - \frac{R_x}{R_2+R_x} \right) \x v_S

R_2 and R_3 are variable resistors that are tuned until v_\t{out} is zero at R_0. Use a coarse resistor for R_2 and a fine resistor for R_3.

When R_x is a strain gauge, we can replace R_3 with an identical but disconnected strain gauge to be used as a control, such that any variations in R_x due to temperature are matched by R_3. We also want to thermally insulate R_1 and R_2.

When the bridge is balanced (so when v_\t{out} = 0):

\frac{R_3}{R_1+R_3} - \frac{R_x}{R_2+R_x} = 0
R_2 R_3 + R_x R_3 = R_x R_1 + R_x R_3
R_x = \frac{R_2 R_3}{R_1}

Circuit loading

If a resistive circuit R_\t{load} is placed across v_\t{out} of a voltage divider, the voltage v_\t{out} will drop. This is because the resistance R_2 across which v_\t{out} is measured is now in parallel with R_\t{load}, which means that the resultant output resistance will be smaller relative to R_1.

To minimise circuit loading, R_\t{load} must be as large as possible.

Amplifiers

An amplifier can be modelled as a black box with a pair of input and output terminals. The voltage across the input terminals is v_\t{in}, and across the output terminals is v_\t{out}.

Thévenin-equivalent amplifier

Furthermore, we can model the internals of the amplifier using Thévenin-equivalence, with the circuit appearing different depending if we’re looking from the input or output terminals. The circuit seen from the input terminals is a single Thévenin-equivalent resistance R_\t{in}, and from the output terminals is a Thévenin-equivalent voltage A \x v_\t{in} and resistance R_\t{out}.

To prevent excessive loading / voltage droop, we want R_\t{in} \gg R_\t{sensor} and R_\t{load} \gg R_\t{out}.

Amplification and gain

Amplifiers have an amplification factor A, which is the ideal amplification assuming no load resistance at the output (the open-loop gain), and a gain G, which is the real observed amplification. These values are the same when R_\t{out} \to \infty.

G = \frac{v_\t{out}}{v_\t{in}}

Cascading amplifiers

Amplifiers are often cascaded in order to boost a signal beyond the limits of a single amplifier. To cascade, the v_\t{out} of one amplifier stage is fed into the v_\t{in} of the next. The overall gain of a chain of cascaded amplifiers can still be found by dividing the overall output voltage by the overall input voltage.

G_1 \x G_2 \x G_3 = \frac{v_\t{out}}{v_\t{in}}

Operational amplifiers

An operational amplifier is an integrated circuit with five terminals: differential inputs v^+ and v^-, supply pins v_\t{s+} and v_\t{s-}, and amplified output v_\t{out}. The suppy voltages determine the minimum and maximum output voltages.

v_\t{out} = A \x (v^+ - v^-)

Ideal operational amplifiers have input resistance R_\t{in} \to \infty and output resistance R_\t{out} \to 0. Low output resistance means that the output voltage is unaffected by any load resistance, so the op-amp acts as an ideal voltage source (with gain equal to the amplification factor). Because R_\t{in} \to \infty, the current flowing between v^+ and v^- is 0\u{A} (an open circuit). The amplification factor A of an ideal op-amp is \infty.

Comparator

With no feedback, an open-loop op-amp will act as a comparator. If the inverting input v^- is held at 0V and the non-inverting input voltage v^+ is positive, the output will be maximum positive; if v^+ is negative, the output will be maximum negative. I don’t think there needs to be a resistor between v^- and ground.

Positive feedback

In a positive-feedback circuit, a fraction of the input voltage is returned to the non-inverting input terminal v^+, increasing \Delta v and therefore v_\t{out} to saturation. Changing or disconnecting v_\t{in} after this point will have no effect on v_\t{out}, which will be stuck at saturation. Resistors between v_\t{in}, v^+, and v_\t{out} are mandatory to prevent massive current flow.

Negative feedback

In a negative-feedback circuit, a fraction of the output voltage is returned to the inverting input terminal v^-, which forces the differential input voltage \Delta v towards 0\u{V}. For an ideal op-amp with infinite gain, the differential input voltage is driven to 0\u{V} exactly. Since the differential input voltage of an ideal op-amp is zero, the input current is also zero (as per Ohm’s law). This is called either the summing-point constraint or the virtual earth principle.

  • v^+ = v^-
  • i_\t{in} = 0\u{A}

For example, consider an op-amp with v_\t{out} = 1\u{V} and A = 10^5. Using v_\t{out} = A \x (v^+ - v^-), we can see that \Delta v = 0.00001\u{V}.

Inverting amplifier

In an inverting amplifier circuit, v_\t{in} is connected to the negative input terminal v^-.

For the circuit shown below, the ground connection at v^+ and the summing-point constraint ensures that v^+ = v^- = 0\u{V}. Because of this, the voltage v_\t{out} - v^- across R_2 is exactly v_\t{out}, and the voltage v_\t{in} - v^- across R_1 is exactly v_\t{in}. Because the current at the input terminals is known to be 0\u{A}, all current must flow directly between v_\t{in} and v_\t{out} (through R_1 and R_2). Via Ohm’s law and KCL, we can see that v_\t{in} / R_1 = -v_\t{out} / R_2, and so the gain of the circuit is:

G = \frac{v_\t{out}}{v_\t{in}} = -\frac{R_2}{R_1}

The input resistance of the op-amp is known to be \infty, but the input resistance R_\t{in} of the circuit is exactly R_1. This is because the input resistance of any circuit is equal to v_\t{in} / i_\t{in}, and we know that i_\t{in} = v_\t{in} / R_1. This is an issue because we want R_\t{in} (and thus R_1) to be as large as possible so that we avoid loading any circuits connected to v_\t{in}, but to get a large gain we need R_1 to be as small as possible.

Non-inverting amplifier

In a non-inverting amplifier circuit, v_\t{in} is connected to the positive input terminal v^+.

For the circuit shown below, the voltage at v^- is the same as the voltage v_1 across R_1. From the summing-point constraint, v_\t{in} = v_1. Additionally, R_1 and R_2 form a voltage divider with v_\t{out}, so we also know that v_1 = (R_1 / R_1 + R_2) v_\t{out}. Replacing v_1 with v_\t{in} and dividing by the fraction gives us the gain of the circuit:

G = \frac{v_\t{out}}{v_\t{in}} = \frac{R_1 + R_2}{R_1} = 1 + \frac{R_2}{R_1}

The input resistance R_\t{in} of the circuit is exactly the input resistance of the op-amp, which is \infty. Similarly, the input current i_\t{in} is 0\u{A}. This makes the non-inverting amplifier an ideal voltage amplifier.

Note that the minimum gain is 1, which occurs when R_2 = 0\u{Ω}. By connecting v_\t{in} to v^+ and v_\t{out} directly to v^-, we get a voltage follower, an amplifier with gain of exactly 1. In this circuit, R_2 would be 0\u{Ω} (a short circuit) and R_1 would be undefined / irrelevant.

Summing amplifier

In a summing amplifier circuit, v_1 and v_2 are connected to the negative input terminal v^- individually via resistors R_1 and R_2. If they’re connected to the positive terminal instead, the circuit will be an averaging amplifier instead.

For the circuit shown below, the ground connection and negative feedback ensures that v^+ = v^- = 0, and the voltage across R_F gives v_\t{out}. The inputs are weighted, summed, and then inverted:

v_\t{out} = - \left( \frac{R_F}{R_1} v_1 + \frac{R_F}{R_2} v_2 \right)

If R_1 = R_2, we can find the gain of the circuit as a single value (where we treat v_1 + v_2 as v_\t{in}). Note that this is identical to the gain of an ordinary inverting amplifier:

v_\t{out} = -\frac{R_F}{R_I} (v_1 + v_2)
G = \frac{v_\t{out}}{v_\t{in}} = -\frac{R_F}{R_I}

The input impedence of each input is equal to the value of the resistor associated with that input.

Differential amplifier

In a differential amplifier circuit, v_2 is connected to v^+ via a voltage divider, and v_1 is connected to v^- with negative feedback as usual.

For the circuit shown below, v^+ is determined by a voltage-divided v_2, and v_1 is inversely amplified as before:

v^+ = \left( \frac{R_4}{R_3 + R_4} \right) v_2
v_\t{out} = \left( \frac{R_1+R_2}{R_1} \right) v^+ - \frac{R_2}{R_1} v_1
v_\t{out} = \left( \frac{R_1+R_2}{R_1} \right) \left( \frac{R_4}{R_3+R_4} \right) v_2 - \frac{R_2}{R_1} v_1

If R_1 = R_3 and R_2 = R_4, we can simplify the circuit down to a simple subtraction operation, and we can find the gain as a single value (where we treat v_2 - v_1 as v_\t{in}):

v_\t{out} = \frac{R_2}{R_1} (v_2 - v_1)
G = \frac{v_\t{out}}{v_\t{in}} = \frac{R_2}{R_1}

Transconductance amplifier

A transconductance amplifier converts voltage to current with gain G = 1 + (R_L / R_F), with infinite input and output impedence.

Permanent magnet DC motors

Quick notes:

  • Use the right-hand rule to determine the direction of the magnetic field induced by a current moving in a circle. Fingers indicate the direction of conventional current, thumb indicates the north pole of the magnetic field.
  • When two magnetic fields interact, the north pole of one will be attracted to the south pole of the other.

Induced voltage

The two sides of the armature coil in the motor are rotating through the magnetic field created by the permanent magnets, which induces a voltage in the conductor (Faraday’s law, a current-carrying conductor moving in a magnetic field will induce a voltage in the conductor).

For the PMDC motor, a voltage is induced in each conductor (each side of the armature) with equal magnitude and opposite polarity to the applied voltage. The induced voltage in each conductor is proportional to the angular velocity \omega_r. The total induced voltage is given by the back EMF constant of the motor k_e (\t{V} \u{s} \u{rad}^{-1}) and the angular velocity \omega_r:

E = E_\t{AB} + E_\t{CD} = k_e \omega_r

Electromagnetic torque

Torque is produced in the motor due to the interaction between the current I and the torque constant of the motor k_t (\t{NmA}^{-1}, probably dependent on the magnetic field strength of the motor):

T_e = k_t I

The torque constant k_t has equal value to the back EMF constant k_e, but different units. This is because the back EMF is directly responsible for the ‘push’ of the motor.

Motor voltage

The voltage drop across a PMDC motor is given by the current I, the armature resistance R_A (\ohm), and the back EMF voltage E:

V_\t{DC} = IR_A + E = IR_A + k_e \omega_r

This is a simplistic model, more complex models would take the inductance of the motor into account.

Motor efficiency

When a motor is running, some proportion of electrical power P_\t{in} is converted to mechanical power P_\t{M}, with the remainder lost to heat as P_\t{L}:

P_\t{in} = V_\t{DC} I = I^2 R_A + E I
P_\t{M} = T_e \omega_r = \frac{T_e \theta}{t} = E I
P_\t{L} = I^2 R_A = P_\t{in} - P_\t{M}

Alternating current

Quick notes on trig

  • \sin(x) = \cos(x - 90°)
  • -\cos(x) = \cos(x \pm 180°)

Average voltage

Integration is used to find the continuous sum of a function. We can find the average voltage V_\t{avg} of some time-varying signal by finding the sum of the function v(t) over some period T and then dividing the result by that same period.

V_\t{avg} = \1{T} \x \int^{t_0+T}_{t=t_0} v(t) \d{t}

For a sinusoid, we can integrate the wave function y = A\cos(2\pi f t + \phi) from 0:

\begin{aligned} V_\t{avg} &= \1{T} \x \int^T_0 A\cos(2\pi f t + \phi) \d{t} \\ &= \1{T} \left[ A \x \frac{T}{2\pi} \sin\left(2\pi \1{T} t + \phi\right) \right]^T_0 \\ &= \frac{A}{2\pi} ( \underbrace{ \sin(2\pi+\phi) - \sin(\phi) }_\t{terms are equal} ) \\ &= 0 \end{aligned}

For a square wave with a duty cycle of D over a period of T, we can sum the integrals of each part of a piece-wise function:

v(t) = \begin{cases} A &, 0 \le t < DT \\ 0 &, DT \le t < T \end{cases}
\begin{aligned} V_\t{avg} &= \1{T} \x \int^{DT}_0 A \d{t} + \int^T_{DT} 0 \d{t} \\ &= \1{T} \x A \x DT \\ &= A \x D \end{aligned}

Root mean square

The average voltage of a sinusoid is zero because the function is symmetric about the x axis, so the negative portion exactly cancels out the positive axis. To get a more useful result, we can instead square the function to convert negative values to positives, then average the function, and finally square-root the result to undo the squaring. This is called the root mean square, denoted as V_\t{rms}:

V_\t{rms} = \sqrt{ \1{T} \x \int^{t_0+T}_{t=t_0} (x(t))^2 \d{t} }

For a sinusoid, we integrate the wave function as before, relying on the identity \cos(2A) = 2\cos^2(A)-1:

\begin{aligned} V_\t{rms} &= \sqrt{ \1{T} \x \int^T_0 A^2 \cos^2 (2\pi f t + \phi) \d{t} } \\ &= \sqrt{ \frac{A^2}{T} \x \int^T_0 \cos^2 (2\pi f t + \phi) \d{t} } \\ &= \sqrt{ \frac{A^2}{T} \left( \int^T_0 \1{2} \d{t} + \underbrace{ \int^T_0 \1{2} \cos(4\pi \1{T} t + 2\phi) \d{t} }_\t{evaluates to zero} \right) } \\ &= \sqrt{ \frac{A^2}{T} \x \1{2}T } \\ &= \frac{A}{\sqrt{2}} \end{aligned}

If there’s a DC component, such as for A\cos(2\pi f t + \phi) + c, we need to include the squared DC component beneath the square root:

V_\t{rms} = \sqrt{ \frac{A^2}{2} + c^2 }

V_\t{rms} is trivial to calculate for the square wave from the previous section:

\begin{aligned} V_\t{rms} &= \sqrt{ \1{T} \x \int^{DT}_0 A^2 \d{t} + \int^T_{DT} 0^2 \d{t} } \\ &= \sqrt{ \1{T} \x A^2 \x DT } \\ &= A \sqrt{D} \end{aligned}

Capacitors

The amount of charge stored on the plates of a capacitor is equal to the voltage across the capacitor, up to a constant of proportionality (capacitance C):

q = C v_c

Taking the derivative of the equation with respect to time gives us the behaviour of the circuit when a current is applied:

\frac{\d{q}}{\d{t}} = i_c = C \frac{\d{v}}{\d{t}}

The current through a capacitor can only be non-zero if the rate of change of voltage is non-zero. At DC, the current through a capacitor is zero, and it acts as an open circuit. When a sinusoidal voltage is placed across it, the current will be a sinusoid that leads the voltage by 90°.

Inductors

An inductor is a coil of wire that induces a magnetic field B when current flows.

Flux \phi is given by magnetic field density B (fields per meter squared), circular cross-sectional area A of the coil, and number of coils N. Total flux (or flux linkage) is called \lambda:

\lambda = n\phi = B \x A \x n

The total flux \lambda is proportional to the current i_L that generated the magnetic field, according to the inductance L of the inductor:

\lambda = L \x i_L

Taking the derivative of this equation with respect to time gives us an expression for the voltage induced across the inductor with polarity opposing the applied current:

\frac{\d{\lambda}}{\d{t}} = v_L = L \frac{\d{i_L}}{\d{t}}

The voltage across an inductor can only be non-zero if the rate of change of current is non-zero. At DC, the voltage across an inductor is zero, and it acts as a short circuit (an ideal wire). When a sinusoidal current is passed through, the voltage will be a sinusoid that leads the current by 90°.

Old notes

Diodes

A diode has polarity. The lead adjacent to the contrasting stripe is the cathode (positive end), and the other lead is the anode (negative end).

A diode is forward biased if the voltage across the terminals is positive (positive end is positive) and reverse biased if negative (positive end is negative).

An ideal diode will act as a perfect conductor when forward-biased (R \to \infty), and a perfect insulator when reverse-biased (R=0).

Capacitors

A capacitor is a device with two charge-storing plates separated by an insulating material. A capacitor of capacitance C and with voltage V across the terminals has charge of Q accumulated on one plate and -Q accumulated on the other. The stored charge is proportional to both the voltage and the capacitance.

Q = CV

Capacitance is proportional to the area A of each plate in square centimetres, the distance d between the two plates in millimetres, and the dielectric constant \epsilon of the insulating material.

C = 8.85 \x 10^{-14} \epsilon A / d

The current through a capacitor is proportional to the rate of change of the voltage.

I = C \frac{dV}{dt}

The energy U_c stored in a capacitor is proportional to the voltage across the capacitor.

U_c = \frac{1}{2}CV^2

The power flowing through a capacitor isn’t lost as heat like it is in a resistor. Instead, it’s stored as energy (voltage and charge) and is returned when discharged.

Capacitors in series

The total capacitance C_\t{total} of n capacitors connected in series is equal to the reciprocal of the sum of the reciprocals of the individual capacitances. Adding a resistor will increase the resistance.

\frac{1}{C_\t{total}} = \sum_{k=1}^{n} \frac{1}{C_k}

Because there is no external connection to the connection between each pair of capacitors in series, the stored charge in each capacitor is equal.

Capacitors in parallel

The total capacitance C_\t{total} of n capacitors connected in parallel is equal to the sum of the individual capacitances. Adding a capacitor will increase the capacitance.

C_\t{total} = \sum_{k=1}^{n} C_k

Circuits

RC circuits

A charged capacitor placed across a resistor discharges according to an inverse exponential curve.

V = Ae^{-t/RC}