RE: [AMPL 6685] Displaying variables after optimization

203 views
Skip to first unread message

Robert Fourer

unread,
Mar 4, 2013, 4:23:24 PM3/4/13
to am...@googlegroups.com

By default the AMPL "display" statement arranges tables so that there are more rows than columns.  If a "(tr)" appears in the display then AMPL has transposed the table, using the earlier index for the columns and the later index for the rows; you can suppress this transposition by setting something like

 

   option display_transpose -10000;

 

where the negative number is larger than the difference between the numbers of rows and numbers of columns.  If a "(tr)" does not appear then AMPL has used the earlier index for the rows and the later index for the columns; you can force a transposition similarly but with a positive value:

 

   option display_transpose 10000;

 

For a three-dimensional array, AMPL's display statement chooses to "slice" on the index that has the fewest different values; this can also be overridden but it's hard for me to explain in the current situation because I do not know what the definition of X looked like.

 

Bob Fourer

4...@ampl.com

 

 

From: am...@googlegroups.com [mailto:am...@googlegroups.com]

On Behalf Of lorenz...@gmail.com
Sent: Tuesday, February 26, 2013 9:18 AM
To: am...@googlegroups.com
Subject: [AMPL 6685] Displaying variables after optimization

 

I want to modify the display of variables after the optimization.
I have a set of variables X [N, N, V]. If I use the command "display X;" it gives me back X[V, *, *] (with the index of the rows as N and index of columns as N).
I wanto to change it in X[N, *, *] (with the index of the rows as V and index of columns as N). Is it possible?

Thanks

 

Reply all
Reply to author
Forward
0 new messages