code: 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);
      }
docs: Add value to the current complex number, creating new complex number.
  
  @param  mixed   $z Complex or real number
  @access public
  @return Complex