Brahmagupta's formula
Brahmagupta's formula is a method for calculating the area of a cyclic quadrilateral, i.e. a quadrilateral where all four vertices lie on a common circle.
Formula
If the quadrilateral has side lengths \( \large a \), \( \large b \), \( \large c \), \( \large d \), one can first calculate the semiperimeter:
$$ \large s = \frac{a+b+c+d}{2} $$
The area is then given by:
$$ \large A = \sqrt{(s-a)(s-b)(s-c)(s-d)} $$
Connection with Heron's formula
Brahmagupta's formula can be seen as an extension of Heron's formula. Both express the area solely in terms of the side lengths.
If one sets one of the sides \( \large d = 0 \) in Brahmagupta's formula, it reduces directly to Heron's formula for a triangle with sides \( \large a, b, c \).
Thus, Heron's formula can be regarded as a special case of Brahmagupta's formula.
Why does the formula work?
Brahmagupta's formula is a generalization of Heron's method. When a quadrilateral is cyclic, it can be divided into two triangles sharing a common diagonal. By expressing the area of both triangles with Heron's formula and simplifying, Brahmagupta's formula appears.
A characteristic property is that a quadrilateral is cyclic if and only if the sum of two opposite angles is \( \large 180^\circ \).
Example
A rectangle is always a cyclic quadrilateral. We take an example with side lengths \( \large a = 5 \), \( \large b = 8 \), \( \large c = 5 \), \( \large d = 8 \).
The semiperimeter is:
$$ \large s = \frac{5+8+5+8}{2} = 13 $$
The area is:
$$ \large A = \sqrt{(13-5)(13-8)(13-5)(13-8)} = \sqrt{8 \cdot 5 \cdot 8 \cdot 5} = \sqrt{1600} = 40 $$
So the area of the rectangle is 40, which agrees with the well-known formula \( \large A = 5 \cdot 8 \).