More examples, including some in-depth and experimental models, can be seen on nbviewer.
The most trivial GP we can think of: minimize x subject to the constraint x \ge 1.
.. literalinclude:: examples/x_greaterthan_1.py
Of course, the optimal value is 1. Output:
.. literalinclude:: examples/x_greaterthan_1_output.txt
This example comes from Section 2.4 of the GP tutorial, by S. Boyd et. al.
.. literalinclude:: examples/simple_box.py
The output is
.. literalinclude:: examples/simple_box_output.txt
Say we had a fixed mass of water we wanted to contain within a tank, but also wanted to minimize the cost of the material we had to purchase (i.e. the surface area of the tank):
.. literalinclude:: examples/water_tank.py
The output is
.. literalinclude:: examples/water_tank_output.txt
This example comes from Section 3 of Geometric Programming for Aircraft Design Optimization, by W. Hoburg and P. Abbeel.
.. literalinclude:: examples/simple_wing.py
The output is
.. literalinclude:: examples/simple_wing_output.txt