Biggest Reuleaux Triangle inscribed within a square which is inscribed within an ellipse | C ++ Program to find the biggest Reuleaux triangle inscribed within in a square which in turn is inscribed within an ellipse ; Function to find the biggest reuleaux triangle ; length of the axes cannot be negative ; height of the reuleaux triangle ; area of the reuleaux triangle ; Driver code
#include <bits/stdc++.h> NEW_LINE using namespace std ; float Area ( float a , float b ) { if ( a < 0 && b < 0 ) return -1 ; float h = sqrt ( ( ( pow ( a , 2 ) + pow ( b , 2 ) ) / ( pow ( a , 2 ) * pow ( b , 2 ) ) ) ) ; float A = 0.70477 * pow ( h , 2 ) ; return A ; } int main ( ) { float a = 5 , b = 4 ; cout << Area ( a , b ) << endl ; return 0 ; }