src/Chippyash/Math/Type/Calculator/Native.php
public function floatPow(FloatType $a, NI $exp)
    {
        if ($exp instanceof RationalType) {
            $b = RationalTypeFactory::fromFloat($a());
            return $this->rationalPow($b, $exp)->asFloatType();
        }

        if ($exp instanceof ComplexType) {
            return $this->floatComplexPow($a(), $exp);
        }

        //int and float types
        $p = pow($a(), $exp());

        return new FloatType($p);
    }
public function floatPow(FloatType $a, NI $exp)
    {
        if ($exp instanceof RationalType) {
            $b = RationalTypeFactory::fromFloat($a());
            return $this->rationalPow($b, $exp)->asFloatType();
        }

        if ($exp instanceof ComplexType) {
            return $this->floatComplexPow($a(), $exp);
        }

        //int and float types
        $p = pow($a(), $exp());

        return new FloatType($p);
    }
public function floatPow ( FloatType $ a , NI $ exp ) { if ( $ exp instanceof RationalType ) { $ b = RationalTypeFactory :: fromFloat ( $ a ( ) ) ; return $ this -> rationalPow ( $ b , $ exp ) -> asFloatType ( ) ; } if ( $ exp instanceof ComplexType ) { return $ this -> floatComplexPow ( $ a ( ) , $ exp ) ; } //int and float types $ p = pow ( $ a ( ) , $ exp ( ) ) ; return new FloatType ( $ p ) ; }
Float Pow - raise number to the exponent
Will return a float type

@param FloatType $a operand
@param NI $exp Exponent

@return FloatType
Float Pow - raise number to the exponent Will return a float type