Main Program
The main program performs all the tasks required to do the optimization.
The steps required include:
- Create the parametric model.
- Create the simulation model.
- Add the necessary responses.
- Perform the optimization.
- Print the obtained results.
Example
if __name__ == "__main__":
# Instantiate the Fourbar parametric model with default design parameters
fbar = Fourbar ()
# Create the simulation model with the defined design parameters
fbar.createModel ()
# Add the responses used by the optimizer
fbar.addResponses ()
# This is provided for model debugging purposes
#fbar.simulate ()
# Perform the optimization
fbar.optimize ()
# Print the final results to the screen
fbar.printResults ()