Module Expr Str Import alias Import alias Import alias Import alias ImportFrom alias alias ImportFrom alias alias alias ImportFrom alias ImportFrom alias ImportFrom alias ClassDef bases NameLoad body Expr Str Assign NameStore Call NameLoad keyword Str keyword AttributeLoad NameLoad attr Assign NameStore Call NameLoad Num keyword Str FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num keyword NameLoad Assign AttributeStore NameLoad attr Num Assign AttributeStore NameLoad attr ListLoad Num Num Num Num Num Num Num decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore ListLoad Num Num Num Num Num Num Assign AttributeStore NameLoad attr BinOpAdd BinOpAdd BinOpSub BinOpMult BinOpMult BinOpMult BinOpMult SubscriptLoad NameLoad Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpSub BinOpAdd BinOpMult BinOpMult SubscriptLoad NameLoad Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult SubscriptLoad NameLoad Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad NameLoad Index Num BinOpMult BinOpMult SubscriptLoad NameLoad Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpAdd BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult SubscriptLoad NameLoad Index Num BinOpAdd BinOpMult BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult SubscriptLoad NameLoad Index Num BinOpAdd BinOpMult BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num BinOpMult BinOpMult SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body Expr Str FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad Call NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Call NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Call NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr Str Assign AttributeStore AttributeLoad AttributeLoad NameLoad attr attr attr Num Assign AttributeStore AttributeLoad AttributeLoad NameLoad attr attr attr Num decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore SubscriptStore AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Call NameLoad BinOpDiv Num BinOpMult BinOpMult NameLoad NameLoad NameLoad BinOpDiv Num BinOpMult BinOpMult BinOpMult NameLoad NameLoad NameLoad NameLoad BinOpMult Num NameLoad Num Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign NameStore BinOpPow BinOpAdd BinOpPow BinOpDiv BinOpMult Num NameLoad BinOpMult NameLoad NameLoad Num BinOpMult Num Num Num Assign NameStore BinOpPow BinOpDiv NameLoad BinOpMult Num Num BinOpDiv Num Num Assign NameStore BinOpPow BinOpDiv BinOpMult BinOpMult BinOpMult Num NameLoad NameLoad NameLoad BinOpMult NameLoad NameLoad Num Assign NameStore Num Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign NameStore BinOpPow BinOpAdd BinOpPow BinOpDiv BinOpMult Num NameLoad BinOpMult NameLoad NameLoad Num BinOpMult Num Num Num Assign NameStore BinOpPow BinOpDiv NameLoad BinOpMult Num Num BinOpDiv Num Num Assign NameStore BinOpPow BinOpDiv BinOpMult BinOpMult BinOpMult Num NameLoad NameLoad NameLoad BinOpMult NameLoad NameLoad Num Assign NameStore Num Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Assign NameStore Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Num Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Num Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Num Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Num Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str While CompareLt NameLoad Num body Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Assign NameStore SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore BinOpAdd NameLoad Num Expr Call NameLoad NameLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Num Expr Call NameLoad NameLoad SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Num Expr Call NameLoad NameLoad SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Num Expr Call NameLoad NameLoad SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Num Expr Call NameLoad NameLoad SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num SubscriptLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Index Num Num decorator_list decorator_list If CompareEq NameLoad Str body Import alias Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad NameLoad attr
N/A N/A 
Test the CONMIN optimizer component
     used Golinski's speed reducer problem
 N/A pkg_resources N/A sys N/A unittest N/A numpy openmdao.main.datatypes.api Float Array openmdao.main.api Component Assembly set_as_top openmdao.main.eggchecker check_save_load openmdao.lib.drivers.conmindriver CONMINdriver openmdao.util.testutil assert_rel_error OptGolinskiComponent N/A Component N/A N/A  From the University of Buffalo MDO Test Suite Problem 2.4
    EXAMPLE   - Golinski's Speed Reducer Test Problem
                (Minimize the speed reducer weight with
                 7 design variables X(1)-X(7) with upper & lower bounds
                 of a gear box.

         MINIMIZE OBJ = 0.7854*X(1)*X(2)**2 * (3.3333*X(3)**2  +
                        14.9334*X(3) - 43.0934) -
                        1.5079*X(1) * (X(6)**2 + X(7)**2) +
                        7.477 * (X(6)**3 + X(7)**3) +
                        0.7854 * (X(4)*X(6)**2 + X(5) * X(7)**2)

          with variable bounds as:
            Width of gear face X(1)  in cm
            2.6 <= X(1) <= 3.6
            teeth module  X(2)       in cm
            0.7 <= X(2) <= 0.8
            number of pinion teeth X(3)
            17  <= X(3) <= 28
            shaft 1 length between bearings X(4) in cm
            7.3 <= X(4) <= 8.3
            shaft 2 length between bearings X(5) in cm
            7.3 <= X(5) <= 8.3
            diameter of shaft 1 X(6)  in cm
            2.9 <= X(6) <= 3.9
            diameter of shaft 2 X(7)  in cm
            5.0 <= X(7) <= 5.5

         Subject to:

              G(1) = 27.0 / (X(1) * X(2)**2 * X(3) ) .LE. 1.0

              G(2) = 397.5 / ( X(1) * X(2)**2 * X(3)**2 ) .LE. 1.0

              G(3) = 1.93 * X(4)**3 /( X(2) * X(3)* X(6)**4) .LE. 1.0

              G(4) = 1.93 * X(5)**3 /( X(2) * X(3)* X(7)**4) .LE. 1.0

              G(5) = SQRT((745.0 * X(4)/ ( X(2) * X(3))**2 + 16.9 * 1.0e6 ) /
                     (110.0 * X(6)**3)  .LE. 1.0

              G(6) = SQRT((745.0 * X(5)/ ( X(2) * X(3))**2 + 157.5 * 1.0e6 ) /
                     (85.0 * X(7)**3)      .LE. 1.0

              G(7) = (X(2) * X(3) )/40.0   .LE. 1.0

              G(8) = 5.0 * X(2) / X(1)     .LE. 1.0

              G(9) = X(1) / (12.0 *X(2) )  .LE. 1.0

              G(10) = 2.6 / X(1)           .LE. 1.0

              G(11) = X(1) / 3.6           .LE. 1.0

              G(12) = 0.7 / X(2)           .LE. 1.0

              G(13) = X(2) / 0.8           .LE. 1.0

              G(14) = 17.0 / X(3)          .LE. 1.0

              G(15) = X(3) / 28.0          .LE. 1.0

              G(16) = 7.3 / X(4)           .LE. 1.0

              G(17) = X(4) / 8.3           .LE. 1.0

              G(18) = 7.3 / X(5)           .LE. 1.0

              G(19) = X(5) / 8.3           .LE. 1.0

              G(20) = 2.9 / X(6)           .LE. 1.0

              G(21) = X(6) / 3.9           .LE. 1.0

              G(22) = 5.0 / X(7)           .LE. 1.0

              G(23) = X(7) / 5.5           .LE. 1.0

              G(24) = (1.5 * X(6) + 1.9 ) / X(4)   .LE. 1.0

              G(25) = (1.1 * X(7) + 1.9 ) / X(5)   .LE. 1.0

              note: G(10) and G(11) are side constraints of X(1)
                    G(12) and G(13) are side constraints of X(2)
                    G(14) and G(15) are side constraints of X(3)
                    G(16) and G(17) are side constraints of X(4)
                    G(18) and G(19) are side constraints of X(5)
                    G(20) and G(21) are side constraints of X(6)
                    G(22) and G(23) are side constraints of X(7)

    This problem is solved by 2 step process:

    1.  Low Level optimization for X(1), X(6) and X(7)

    2.  High Level (using Conmin) for X(2), X(3), X(4), X(5)

         X = (3.3,0.59,25.0,7.9,7.599999,3.0,5.0999999)
    The optimum design is known to be
         OBJ = 0.2985138e+04
    and the corresponding X-vector is
         X = (3.5,0.7,17.0,7.3,7.3,3.35,5.286518)
     N/A x N/A Array iotype in dtype N/A numpy float N/A result N/A Float 0.0 iotype out __init__ N/A N/A self N/A N/A N/A N/A N/A N/A super OptGolinskiComponent self __init__ N/A N/A self x N/A N/A numpy array N/A 3.3 0.7 25.0 7.9 7.5999999 3.0 5.09999999 dtype float N/A N/A self opt_objective 2985.1384 N/A N/A self opt_design_vars N/A 3.3 0.7 17.0 7.3 7.3 3.3502 5.2865 N/A execute N/A N/A self N/A N/A N/A calculate the new objective value N/A cf N/A 0.7854 3.3333 14.9334 43.0934 1.508 7.477 N/A N/A self result N/A N/A N/A N/A N/A N/A N/A N/A cf N/A 0 N/A N/A self x N/A 0 N/A N/A self x N/A 1 N/A N/A self x N/A 1 N/A N/A N/A N/A N/A cf N/A 1 N/A N/A self x N/A 2 N/A N/A self x N/A 2 N/A N/A cf N/A 2 N/A N/A self x N/A 2 N/A cf N/A 3 N/A N/A N/A cf N/A 4 N/A N/A self x N/A 0 N/A N/A N/A N/A self x N/A 5 N/A N/A self x N/A 5 N/A N/A N/A self x N/A 6 N/A N/A self x N/A 6 N/A N/A cf N/A 5 N/A N/A N/A N/A N/A self x N/A 5 N/A N/A self x N/A 5 N/A N/A self x N/A 5 N/A N/A N/A N/A self x N/A 6 N/A N/A self x N/A 6 N/A N/A self x N/A 6 N/A N/A cf N/A 0 N/A N/A N/A N/A N/A self x N/A 3 N/A N/A self x N/A 5 N/A N/A self x N/A 5 N/A N/A N/A N/A self x N/A 4 N/A N/A self x N/A 6 N/A N/A self x N/A 6 N/A N/A GolinskiTestCase N/A N/A unittest TestCase N/A N/A test CONMIN optimizer component setUp N/A N/A self N/A N/A N/A N/A self top N/A set_as_top N/A Assembly N/A N/A N/A N/A self top add driver N/A CONMINdriver N/A N/A N/A N/A self top add comp N/A OptGolinskiComponent N/A N/A N/A N/A N/A N/A self top driver workflow add comp N/A N/A N/A N/A self top driver iprint 0 N/A N/A N/A N/A self top driver itmax 30 N/A tearDown N/A N/A self N/A N/A N/A N/A self top None N/A getx0 N/A N/A self g11 g12 N/A N/A N/A x00 N/A N/A N/A N/A self top comp x N/A 0 N/A max N/A 27.0 N/A N/A g11 g11 g12 N/A 397.5 N/A N/A N/A g11 g11 g12 g12 N/A 5.0 g11 2.6 N/A x00 N/A getx5 N/A N/A self g11 g12 g13 N/A N/A N/A A1 N/A N/A N/A N/A N/A 745.0 g13 N/A g11 g12 2 N/A 0.169 100000000.0 0.5 N/A g21 N/A N/A A1 N/A 1100.0 0.1 N/A 1.0 3.0 N/A g22 N/A N/A N/A N/A N/A 1.93 g13 g13 g13 N/A g11 g12 0.25 N/A g23 2.9 N/A x05 N/A max g21 g22 g23 N/A x05 N/A getx6 N/A N/A self g11 g12 g14 N/A N/A N/A A2 N/A N/A N/A N/A N/A 745.0 g14 N/A g11 g12 2 N/A 0.1575 1000000000.0 0.5 N/A g31 N/A N/A A2 N/A 850.0 0.1 N/A 1.0 3.0 N/A g32 N/A N/A N/A N/A N/A 1.93 g14 g14 g14 N/A g11 g12 0.25 N/A g33 5.0 N/A x06 N/A max g31 g32 g33 N/A x06 N/A test_opt1 N/A N/A self N/A N/A N/A N/A N/A N/A N/A self top driver add_objective comp.result N/A iter 1 N/A N/A N/A N/A N/A self top driver add_parameter comp.x[1] 0.7 0.8 N/A N/A N/A N/A N/A self top driver add_parameter comp.x[2] 17.0 28.0 N/A N/A N/A N/A N/A self top driver add_parameter comp.x[3] 7.3 8.3 N/A N/A N/A N/A N/A self top driver add_parameter comp.x[4] 7.3 8.3 N/A N/A N/A N/A N/A self top driver add_constraint 40.0/(comp.x[2] * comp.x[3]) > 1.0 N/A N/A iter 4 N/A N/A g00 N/A N/A N/A N/A self top comp x N/A 0 N/A g11 N/A N/A N/A N/A self top comp x N/A 1 N/A g12 N/A N/A N/A N/A self top comp x N/A 2 N/A g13 N/A N/A N/A N/A self top comp x N/A 3 N/A g14 N/A N/A N/A N/A self top comp x N/A 4 N/A g15 N/A N/A N/A N/A self top comp x N/A 5 N/A g16 N/A N/A N/A N/A self top comp x N/A 6 N/A N/A N/A N/A N/A self top comp set x[0] N/A N/A self getx0 g11 g12 N/A N/A N/A N/A N/A self top comp set x[5] N/A N/A self getx5 g11 g12 g13 N/A N/A N/A N/A N/A self top comp set x[6] N/A N/A self getx6 g11 g12 g14 N/A N/A N/A N/A self top run N/A iter N/A iter 1 N/A N/A assert_rel_error self N/A N/A N/A self top comp opt_objective N/A N/A N/A N/A self top driver eval_objective 0.01 N/A N/A assert_rel_error self N/A N/A N/A N/A self top comp opt_design_vars N/A 1 N/A N/A N/A N/A self top comp x N/A 1 0.1 N/A N/A assert_rel_error self N/A N/A N/A N/A self top comp opt_design_vars N/A 2 N/A N/A N/A N/A self top comp x N/A 2 0.01 N/A N/A assert_rel_error self N/A N/A N/A N/A self top comp opt_design_vars N/A 3 N/A N/A N/A N/A self top comp x N/A 3 0.01 N/A N/A assert_rel_error self N/A N/A N/A N/A self top comp opt_design_vars N/A 4 N/A N/A N/A N/A self top comp x N/A 4 0.05 N/A N/A N/A N/A __name__ __main__ N/A N/A nose N/A N/A N/A N/A sys argv append --cover-package=openmdao N/A N/A N/A N/A sys argv append --cover-erase N/A N/A N/A nose runmodule