Mathematical optimization: Building a rectangular pen

A farmer wants to build a rectangular pen for his sheep. One side is a straight river. For the other three sides he has 200m of fencing to use. What is the maximum area of pen he can make?
Animate to see how the fence changes. Click on the Representation box to see the graphic representation of the relationship between one side of the fence and the Area.