Converts bipolar value to a scalar

import { Bipolar } from 'https://unpkg.com/ixfx/dist/data.js';
Bipolar.toScalar(-1); // 0.0
Bipolar.toScalar( 0); // 0.5
Bipolar.toScalar( 1); // 1.0

Throws an error if bipolarValue is not a number or NaN

  • Parameters

    • bipolarValue: number

      Value to convert to scalar

    Returns number

    Scalar value on 0..1 range.