Given a circle which is the incircle of a triangle whose sides are a, b< and c, the task is to find the radius of this incircle.
Input: a = 2, b = 2, c = 3 Output: 0.566947 Input: a = 3, b = 4, c = 5 Output: 1
Radius of the incircle = area of the triangle / half of perimeter of the triangle
Area of the triangle = √(p*(p-a)*(p-b)*(p-c)
perimeter of the triangle = (a + b + c)
Below is the implementation of the above approach:
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.
- Program to calculate the Area and Perimeter of Incircle of an Equilateral Triangle
- Area of Incircle of a Right Angled Triangle
- Radii of the three tangent circles of equal radius which are inscribed within a circle of given radius
- Area of Equilateral triangle inscribed in a Circle of radius R
- Program to print a Hollow Triangle inside a Triangle
- Find minimum radius such that atleast k point lie inside the circle
- Find area of the larger circle when radius of the smaller circle and difference in the area is given
- Biggest Reuleaux Triangle within a Square which is inscribed within a Right angle Triangle
- Biggest Reuleaux Triangle inscribed within a Square inscribed in an equilateral triangle
- Angular Sweep (Maximum points that can be enclosed in a circle of given radius)
- Maximize a value for a semicircle of given radius
- Number of rectangles in a circle of radius R
- CSS | border-top-right-radius Property
- Radius of the biggest possible circle inscribed in rhombus which in turn is inscribed in a rectangle
- Equation of circle from centre and radius
- Area of a n-sided regular polygon with given Radius
- Length of the chord of the circle whose radius and the angle subtended at the center by the chord is given
- Radius of the circle when the width and height of an arc is given
- Number of common tangents between two circles if their centers and radius is given
- Percentage increase in the cylinder if the height is increased by given percentage but radius remains constant
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.