Power Factor & AC Power API
AC power triangle and power-factor maths as an API, computed locally and deterministically. The power-factor endpoint solves the power triangle: from any two of the apparent power S (volt-amperes), the real power P (watts), the reactive power Q (VAR), the power factor (cos φ) or the phase angle it returns all of them, using S = √(P²+Q²), P = S·cosφ, Q = S·sinφ and PF = P/S. The load endpoint computes the powers of a load directly from its voltage, current and power factor — single-phase S = V·I or three-phase S = √3·V·I from line values. The correction endpoint sizes power-factor correction: the reactive power a capacitor must supply to raise the power factor from a present value to a target, Qc = P·(tanφ1 − tanφ2), and — given the supply voltage and frequency — the capacitance, C = Qc/(2π·f·V²), the basis of cutting reactive demand and utility penalties. Everything is computed locally and deterministically, so it is instant and private. Ideal for electrical-engineering and power-systems tools, motor, industrial and HVAC load analysis, energy-billing and power-quality apps. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is AC power and power-factor correction; for Ohm's law, reactance and resonance use an Ohm's-law API.
api.oanor.com/powerfactor-api