public static function fromNative()
    {
        $args = \func_get_args();

        if (\count($args) != 2) {
            throw new \BadMethodCallException('You must provide 2 arguments: 1) real part, 2) imaginary part');
        }

        $real    = Real::fromNative($args[0]);
        $im      = Real::fromNative($args[1]);
        $complex = new self($real, $im);

        return $complex;
    }
public static function fromNative()
    {
        $args = \func_get_args();

        if (\count($args) != 2) {
            throw new \BadMethodCallException('You must provide 2 arguments: 1) real part, 2) imaginary part');
        }

        $real    = Real::fromNative($args[0]);
        $im      = Real::fromNative($args[1]);
        $complex = new self($real, $im);

        return $complex;
    }
public static function fromNative ( ) { $ args = \ func_get_args ( ) ; if ( \ count ( $ args ) != 2 ) { throw new \ BadMethodCallException ( 'You must provide 2 arguments: 1) real part, 2) imaginary part' ) ; } $ real = Real :: fromNative ( $ args [ 0 ] ) ; $ im = Real :: fromNative ( $ args [ 1 ] ) ; $ complex = new self ( $ real , $ im ) ; return $ complex ; }
Returns a new Complex object from native PHP arguments

@param  float                        $real Real part of the complex number
@param  float                        $im   Imaginary part of the complex number
@return Complex|ValueObjectInterface
@throws \BadMethodCallException
Returns a new Complex object from native PHP arguments