== Unit logaritmis jeung désibel ==
In electronics, it is common to use [[ logarithmic units]] to measure gain. Originally, the bel was used:
: Gain = log<sub>10</sub>(''P''<sub>2</sub>/''P''<sub>1</sub>) bel
where P1 and P2 are the input and output '' powers'' respectively.
Using the bel unit, however, results in small numbers, so the [[decibel]] ( one tenth of a bel) became popular in its place. As there are ten decibels ('''dB''') in a bel:
: Gain = 10 * log<sub>10</sub>(''P''<sub>2</sub>/''P''<sub>1</sub>) dB
A similar unit using [[ natural logarithm]] s is called the [[neper]].)
When gain is calculated using voltage instead of power, making the substitution [[Joule 's law|(''P''=''V''<sup>2</sup>/''R'')]], the formula is:
*Gain = 10 * log ((''V''<sub>2</sub><sup>2</sup>/''R'') /(''V''<sub>1</sub><sup>2</sup>/''R'') ) dB
*Gain = 20 * log (''V''<sub>2</sub>/''V''<sub>1</sub>) dB
This formula only holds true if the load [[impedance]]s are identical. In many modern electronic devices, [[output impedance]]s are low enough and [[input impedance]]s high enough that load can be ignored without significantly affecting the calculation.
=== Conto ===
If an amplifier produces an output of 1 [[volt]] into a 1 [[ohm]] load, then it is providing 1 watt of output power. If the amplifier is then altered to produce an output of 10 volts into the same load, it is now providing 100 watts of output power (<math>P=V^2/R</math>). Therefore:
voltage gain = 10 times
power gain = 100 times
which by definition is said to be a gain of 20 dB.
A gain of factor 1 or ( equivalent to 0 dB) where both input and output are at the same voltage level is also known as ''[[1 ( number)| unity]] gain''.