LM317 Voltage Regulator Calculator
Design LM317 adjustable voltage regulator circuits. Compute output voltage from R1 and R2 values, or find the exact R2 resistor for any desired voltage with dropout analysis.
About This Calculator
The LM317 is a versatile adjustable voltage regulator widely used in power supply design, battery charging circuits, and general-purpose electronics. This calculator helps you determine the output voltage from known resistor values or find the required R2 resistor value for a desired output voltage.
The core formula is Vout = 1.25V x (1 + R2/R1) + Iadj x R2, where 1.25V is the precision reference voltage between the output and adjustment terminals, and Iadj (~50µA) is the adjustment pin current. For most designs, the Iadj term is negligible.
R1 is typically chosen as 240Omega (standard) or 120Omega (for better regulation). The LM317 can deliver up to 1.5A output current with adequate heatsinking, and requires a minimum 3V dropout between input and output.
Regional Power Supply Considerations
India: 230V AC mains at 50Hz. A typical 12-0-12V transformer produces ~17V DC after rectification, suitable for 5-12V LM317 outputs. Common wall adapters in India output 9V, 12V, or 24V DC.
United States: 120V AC mains at 60Hz. Standard 12V AC transformer outputs ~15V DC after rectification, ideal for 5-9V regulated outputs. US wall adapters commonly provide 5V, 9V, or 12V DC.
United Kingdom: 230V AC mains at 50Hz, similar to India. UK power supplies typically output 5V, 9V, 12V, or 24V DC. Ensure the rectified DC voltage is at least 3V above the desired LM317 output for proper regulation.
Frequently Asked Questions
What is the LM317 voltage regulator?
The LM317 is a popular adjustable positive voltage regulator capable of supplying more than 1.5A over an output voltage range of 1.25V to 37V. It requires only two external resistors (R1 and R2) to set the output voltage. Key features include internal current limiting, thermal overload protection, and safe-area compensation. It is widely used in power supply designs, battery chargers, and DIY electronics projects worldwide.
What is the formula for calculating LM317 output voltage?
The LM317 output voltage is calculated as: Vout = 1.25V x (1 + R2/R1) + Iadj x R2. The reference voltage (Vref) is 1.25V between the output and adjustment terminals. Iadj is the adjustment pin current, typically 50µA and usually negligible. For practical design with R1 = 240Omega, the simplified formula Vout = 1.25 x (1 + R2/240) gives accurate results within 0.1V for most applications.
What are typical R1 and R2 values for common LM317 output voltages?
For R1 = 240Omega: 5V output requires R2 = 720Omega (nearest standard: 680 or 750Omega), 9V requires R2 = 1488Omega (nearest: 1.5kOmega), 12V requires R2 = 2064Omega (nearest: 2kOmega or 2.2kOmega), 15V requires R2 = 2640Omega (nearest: 2.7kOmega). For R1 = 120Omega, resistor values are halved. Use the nearest E12 or E24 series resistor value and verify the actual output voltage.
What is the minimum input voltage for the LM317?
The LM317 requires a minimum input-to-output differential (dropout voltage) of 3V under full load. Therefore, the minimum input voltage is Vin(min) = Vout + 3V. For example, a 5V output needs at least 8V input, and a 12V output needs at least 15V input. For best regulation and ripple rejection, add 2-3V margin above the minimum. Input voltages above 40V can damage the LM317.
How does the Iadj current affect LM317 output voltage accuracy?
The adjustment pin current (Iadj) is typically 50µA and maximum 100µA. It flows through R2, adding a small voltage of Iadj x R2 to the output. For R2 values under 10kOmega, this contribution is under 0.5V (typically 0.05-0.2V). Most designs ignore Iadj since the LM317's reference voltage tolerance (+/-2%) dominates the error budget. Using R1 = 120Omega instead of 240Omega improves regulation by reducing Iadj effects.
How do I select standard resistor values for the LM317?
First, calculate the exact R2 value using the formula R2 = R1 x (Vout/1.25 - 1). Then select the nearest standard E12 (10% tolerance) or E24 (5% tolerance) resistor value. For example, if the calculated R2 is 1488Omega, use 1.5kOmega (E12) or 1.5kOmega (E24). Then calculate the actual Vout using the chosen resistor. For precision applications, use E96 (1%) resistors or combine two resistors in series to get closer to the exact value.
Can the LM317 be used with different AC mains voltages in India, US, and UK?
Yes, the LM317 works with any DC input voltage between 3V and 40V above ground, regardless of regional AC mains standards. In India and UK (230V AC, 50Hz), a transformer typically produces 12-24V AC which rectifies to 15-33V DC. In the US (120V AC, 60Hz), a 12V AC transformer gives about 15V DC after rectification. Ensure the rectified and filtered DC voltage is at least 3V above the desired LM317 output voltage.
What is the difference between LM317 and fixed voltage regulators like 7805?
The LM317 is an adjustable regulator offering any output voltage from 1.25V to 37V using two external resistors, while fixed regulators like 7805 (5V), 7812 (12V) provide a single preset output. The LM317 generally offers better line and load regulation (0.04%/V typ vs 0.1%/V for 7805). However, fixed regulators are simpler (no external resistors) and often cheaper for common voltages. The LM317 is preferred for non-standard voltages or designs requiring adjustability.