public function tan(int $scale = null): Decimal
    {
	    $cos = $this->cos($scale + 2);
	    if ($cos->isZero()) {
	        throw new \DomainException(
	            "The tangent of this 'angle' is undefined."
	        );
	    }

	    return $this->sin($scale + 2)->div($cos)->round($scale);
    }
public function tan(int $scale = null): Decimal
    {
	    $cos = $this->cos($scale + 2);
	    if ($cos->isZero()) {
	        throw new \DomainException(
	            "The tangent of this 'angle' is undefined."
	        );
	    }

	    return $this->sin($scale + 2)->div($cos)->round($scale);
    }
public function tan ( int $ scale = null ) : Decimal { $ cos = $ this -> cos ( $ scale + 2 ) ; if ( $ cos -> isZero ( ) ) { throw new \ DomainException ( "The tangent of this 'angle' is undefined." ) ; } return $ this -> sin ( $ scale + 2 ) -> div ( $ cos ) -> round ( $ scale ) ; }
Calculates the tangent of this method with the highest possible accuracy
Note that accuracy is limited by the accuracy of predefined PI;

@param integer $scale
@return Decimal tan($this)
Calculates the tangent of this method with the highest possible accuracy Note that accuracy is limited by the accuracy of predefined PI ;