The chainsaw was originally invented for medical purposes by Scottish doctors John Aitken and James Jeffray in the late 18th century, around 1783-1785. They developed an early prototype chainsaw used to cut through bone during surgeries, particularly for childbirth-related procedures like symphysiotomy. This early chainsaw had a chain with cutting teeth that was moved by a hand crank. The modern chainsaw for cutting wood was developed much later. Bernhard Heine, a German orthopedist, designed an osteotome (a bone-cutting chainsaw) in 1830. The first electric chainsaw for forestry use was invented by German engineer Andreas Stihl in 1926, and the first gasoline-powered chainsaw followed shortly after in 1927 by Emil Lerp. Stihl is recognized as a key figure in chainsaw development and mass production.