ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
Maths.php
Go to the documentation of this file.
1<?php
14function hypo($a, $b) {
15 if (abs($a) > abs($b)) {
16 $r = $b / $a;
17 $r = abs($a) * sqrt(1 + $r * $r);
18 } elseif ($b != 0) {
19 $r = $a / $b;
20 $r = abs($b) * sqrt(1 + $r * $r);
21 } else {
22 $r = 0.0;
23 }
24 return $r;
25} // function hypo()
26
27
hypo($a, $b)
Definition: Maths.php:14
An exception for terminatinating execution or to throw for unit testing.
$r
Definition: example_031.php:79