Utility method to get area of right angle triangle , given base and hypotenuse
function getArea ( $ base , $ hypotenuse ) { $ height = sqrt ( $ hypotenuse * $ hypotenuse - $ base * $ base ) ; return 0.5 * $ base * $ height ; }