यहां हम यह देखेंगे कि किसी त्रिभुज के परिवृत्त का क्षेत्रफल कैसे ज्ञात किया जाता है, जिसकी भुजाएँ दी गई हैं। यहाँ भुजा AB a है, BC b है और CA c है, त्रिज्या 'r' है।

त्रिज्या r समान है -

उदाहरण
#include <iostream>
#include <cmath>
using namespace std;
float area(float a, float b, float c) {
if (a < 0 || b < 0 || c < 0) //if values are is negative it is invalid
return -1;
float s = (a + b + c) /2;
float triangle = sqrt(s * (s - a) * (s - b) * (s - c));
float area = 3.14159 * pow(((a*b*c) / triangle), 2);
return area;
}
int main() {
float a = 4, b = 5, c = 3;
cout << "Area : " << area(a, b, c);
} आउटपुट
Area : 314.159