<s> """<STR_LIT>""" <EOL> from openmdao . main . api import Assembly <EOL> from openmdao . lib . drivers . api import SLSQPdriver <EOL> from openmdao . lib . optproblems import sellar <EOL> class SellarIDF ( Assembly ) : <EOL> """<STR_LIT>""" <EOL> def configure ( self ) : <EOL> """<STR_LIT>""" <EOL> self . add ( '<STR_LIT>' , SLSQPdriver ( ) ) <EOL> self . add ( '<STR_LIT>' , sellar . Discipline1_WithDerivatives ( ) ) <EOL> self . add ( '<STR_LIT>' , sellar . Discipline2_WithDerivatives ( ) ) <EOL> self . driver . workflow . add ( [ '<STR_LIT>' , '<STR_LIT>' ] ) <EOL> self . driver . add_objective ( '<STR_LIT>' ) <EOL> self . driver . add_parameter ( ( '<STR_LIT>' , '<STR_LIT>' ) , low = - <NUM_LIT> , high = <NUM_LIT> ) <EOL> self . driver . add_parameter ( ( '<STR_LIT>' , '<STR_LIT>' ) , low = <NUM_LIT:0.0> , high = <NUM_LIT> ) <EOL> self . driver . add_parameter ( '<STR_LIT>' , low = <NUM_LIT:0.0> , high = <NUM_LIT> ) <EOL> self . driver . add_parameter ( '<STR_LIT>' , low = - <NUM_LIT> , high = <NUM_LIT> ) <EOL> self . driver . add_parameter ( '<STR_LIT>' , low = - <NUM_LIT> , high = <NUM_LIT> ) <EOL> self . driver . add_constraint ( '<STR_LIT>' ) <EOL> self . driver . add_constraint ( '<STR_LIT>' ) <EOL> self . driver . add_constraint ( '<STR_LIT>' ) <EOL> self . driver . add_constraint ( '<STR_LIT>' ) <EOL> self . driver . iprint = <NUM_LIT:0> <EOL> if __name__ == "<STR_LIT:__main__>" : <EOL> import time <EOL> prob = SellarIDF ( ) <EOL> prob . dis1 . z1 = prob . dis2 . z1 = <NUM_LIT> <EOL> prob . dis1 . z2 = prob . dis2 . z2 = <NUM_LIT> <EOL> prob . dis1 . x1 = <NUM_LIT:1.0> <EOL> prob . dis2 . y1 = <NUM_LIT> <EOL> tt = time . time ( ) <EOL> prob . run ( ) <EOL> ttot = time . time ( ) - tt <EOL> print "<STR_LIT:\n>" <EOL> print "<STR_LIT>" % ( prob . dis1 . z1 , prob . dis2 . z2 , prob . dis1 . x1 ) <EOL> print "<STR_LIT>" % ( prob . dis1 . y1 , prob . dis2 . y2 ) <EOL> print "<STR_LIT>" , prob . driver . eval_objective ( ) <EOL> print "<STR_LIT>" , ttot , "<STR_LIT>" </s>
