pyomo icon indicating copy to clipboard operation
pyomo copied to clipboard

model.pprint() doesn't print the model's name

Open DLWoodruff opened this issue 2 years ago • 0 comments

Summary

The pretty print of a model would be slightly prettier if it started with the model name when it is not None.

Rationale

In codes that create multiple models, is is helpful to give them names, particularly when the models are structurally similar. It would be helpful to see the name when pretty printing the model.

Description

Modify pprint() so that if the model's name is not None, print it as the first line of a pretty print.

Additional information

DLWoodruff avatar Mar 04 '22 01:03 DLWoodruff