src/Number/Rational.php
public function abs(): Rational
    {
        return new Rational(abs($this->whole), abs($this->numerator), abs($this->denominator));
    }
public function abs(): Rational
    {
        return new Rational(abs($this->whole), abs($this->numerator), abs($this->denominator));
    }
public function abs ( ) : Rational { return new Rational ( abs ( $ this -> whole ) , abs ( $ this -> numerator ) , abs ( $ this -> denominator ) ) ; }
The absolute value of a rational number

@return Rational
The absolute value of a rational number