Where these formulas come from
The Hamwi (1964) and Devine (1974) formulas were made by doctors, partly to estimate medicine doses. Robinson and Miller (both 1983) reworked them with newer data. All four use only your height and sex, and they were designed for adults about 5 feet (152 cm) and taller.

