src/Malenki/Math/Number/Complex.php
public function add($z)
    {
        if (is_numeric($z)) {
            $z = new self($z, 0);
        }

        return new self($this->float_r + $z->re, $this->float_i + $z->im);
    }
public function add($z)
    {
        if (is_numeric($z)) {
            $z = new self($z, 0);
        }

        return new self($this->float_r + $z->re, $this->float_i + $z->im);
    }
public function add ( $ z ) { if ( is_numeric ( $ z ) ) { $ z = new self ( $ z , 0 ) ; } return new self ( $ this -> float_r + $ z -> re , $ this -> float_i + $ z -> im ) ; }
Add value to the current complex number, creating new complex number.

@param  mixed   $z Complex or real number
@access public
@return Complex
Add value to the current complex number creating new complex number .