Python : comment convertir une vitesse de rotation de rpm en Hz avec UliEngineering

Vous pouvez facilement convertir une vitesse de rotation de rpm (révolutions par minute) en Hz (révolutions par seconde) grâce à la bibliothèque Python UliEngineering :

rpm_to_hz.py
from UliEngineering.Physics.Rotation import *
from UliEngineering.EngineerIO import *

# Convertir 60 rpm en Hz
speed = rpm_to_Hz("60 rpm")
print(f"60 rpm = {format_value(speed, 'Hz')}")

# Convertir 3000 rpm en Hz
speed = rpm_to_Hz("3000 rpm")
print(f"3000 rpm = {format_value(speed, 'Hz')}")

Exemple de sortie

rpm_to_hz_output.txt
60 rpm = 1.00 Hz
3000 rpm = 50.0 Hz

La conversion utilise la formule : $Hz = \frac{rpm}{60}$


Check out similar posts by category: Physics, Python