Jak vypočítat střídu buck regulátoru v Pythonu pomocí UliEngineering

Můžete snadno vypočítat strídu buck regulátoru pomocí knihovny UliEngineering v Pythonu:

TechOverflow calculators:
You can enter values with SI suffixes like 12.2m (equivalent to 0.012) or 14k (14000) or 32u (0.000032).
The results are calculated while you type and shown directly below the calculator, so there is no need to press return or click on a Calculate button.
V
V
buck_regulator_duty_cycle.py
from UliEngineering.Electronics.SwitchingRegulator import *

# Výpočet stridy pro buck regulátor 12V na 5V
duty_cycle = buck_regulator_duty_cycle("12V", "5V")
print(f"Duty cycle (12V to 5V): {duty_cycle:.2%}")

# Výpočet stridy pro buck regulátor 24V na 3.3V
duty_cycle = buck_regulator_duty_cycle("24V", "3.3V")
print(f"Duty cycle (24V to 3.3V): {duty_cycle:.2%}")

Příklad výstupu

buck_regulator_duty_cycle_output.txt
Duty cycle (12V to 5V): 41.67%
Duty cycle (24V to 3.3V): 13.75%

Strída buck regulátoru se počítá pomocí vzorce: $D = \frac{V_{out}}{V_{in}}$


Podívejte se na podobné články podle kategorie: Calculators, Electronics, Python