Opening a Sample Model on a Mac

In the Installing LINGO on a Mac section above, we suggested that you install the LingoDocs folder in your $HOME directory.  The LingoDocs folder contains a folder called Samples with numerous sample model. These models are drawn from a wide array of application areas.  For a complete listing of these models, see Additional Examples of LINGO Modeling. The sample model directory is titled Samples and is stored directly off the many LINGO directory.

To open a sample model in LINGO, follow these steps:

1.  Pull down the File menu and select the Open command. Migrate to where you installed your copy of the LingoDocs folder:

 macfileopen2

2.  Double-click on the LingoDocs folder then double-click on the Samples folder contained in the LingoDocs folder, at which point you should see:

 macfileopen1

3.  To read in a small transportation model, select the tran.lng model from the Sample folder and press the Open button. You should now have the model in an open window in LINGO as follows:

 mactranmodel

For details on developing a transportation model in LINGO see A Sample Transportation Model in this chapter.

You may now solve the model using the Solver|Solve command, or by pressing the Solve button on the toolbar: macsolvebutton. The optimal objective value for this model is 161. When solved, you should see the following solver status window:

mactransolverstatus

Note the objective field has a value of 161 as expected. For an interpretation of the other fields in this window, see Solver Status Window in Getting Started with LINGO.

Behind the solver status window, you will find the solution report for the model. This report contains summary information about the model as well as values for all the variables. This report’s header is reproduced below:

mactransolution

For information on interpreting the fields in the solution report, see Sample Solution Report in Getting Started with LINGO.