Stat/Math
Software Support
Software Consulting
Software Availability
Purchasing Software
Software Price
Contact

User Support
Documentation
Knowledge Base
Education
Consulting
Podcasts

Systems & Services
Cyberinfrastructure
Supercomputers
Grid Computing
Storage
Visualization
Digital Libraries & Data

Results & Impact
Publications
Grants & Grant Info
Events & Outreach
Economic Impact
Survey Results

About RT
Leadership
Vision & Planning
News & Features

# LINGO Interactive Execution

Lingo is basically designed for interactive execution. In this section, an annotative sample of interactive execution is addressed. Annotation is given after ! sign. The ! sign is the symbol for comments, which must end with a semi-colon [unlike Gino]. Lingo will ignore all the command or comment after the ! sign. The other main difference from Gino is that all functions in Lingo begin with @ [for example, @ABS, rather than ABS, denotes the absolute value function].

```:               ! The prompt is a colon;
:               ! The Lingo system is case insensative;
:               ! MODEL is the command used to signify the beginning of model input;
:               !
: model         ! The prompt changes to a question mark, as the model is entered;
? min=2*x+3*y;  ! MIN is the reserved keyword meaning minimum in a model;
? x+y>5;        ! Note that every INPUT must end with a semicolon (;);
? x>0;
? y>0;
? end           ! END statement will terminate the model;

:go             ! GO command will solve the model;

ROWS=      4 VARS=      2 NO. INTEGER VARS=      0  ( ALL ARE LINEAR)
NONZEROES=      7 CONSTRAINT NONZ=     4(     4 ARE +- 1) DENSITY= .583
SMALLEST AND LARGEST ELEMENTS IN ABSOLUTE VALUE=    1.00000    5.00000
NO. < :   0 NO. =:   0 NO. > :   3, OBJ=MIN, GUBS <=   2
SINGLE COLS=    0

MAJOR STEP=     1 SUM INF.=  5.00000     OBJ.=  10.0000
MAJOR STEP=     1 SUM INF.=  .000000E+00 OBJ.=  10.0000
MAJOR STEP=     1 SUM INF.=  .000000E+00 OBJ.=  10.0000

OPTIMUM FOUND AT STEP          1
SOLUTION OBJECTIVE VALUE =     10.00

VARIABLE           VALUE        REDUCED COST
X        5.000000            .0000000E+00
Y        .0000000E+00        1.000000

ROW    SLACK OR SURPLUS      DUAL PRICE
1        10.00000            1.000000
2        .0000000E+00       -2.000000
3       -5.000000            .0000000E+00
4        .0000000E+00        .0000000E+00

:               ! If the meaning of this is unclear, talk to your instructor!;
: look all      ! The current model can be displayed with the LOOK commanl;

MODEL:
1) MIN= 2 * X + 3 * Y ;
2) X + Y > 5 ;
3) X > 0 ;
4) Y > 0 ;
END

: del 4         ! DEL will delete the fourth row of current model;
: look 2 3      ! You can specify a particular range to LOOK at;

2) X + Y > 5 ;
3) X > 0 ;

: ext           ! EXT will extend the current model;
? y > 0;        ! You can experiment the new input.  Here the deleted;
? end           ! row is recovered.  END will terminate the model input;

: save          ! This command asks to save the current model in a file;
! Lingo asks you to provide a file name;
FILE NAME=
save.out        ! This is an arbitrary file name;
! The filename may be included with the save command;
: save foo.bar

: take save.out ! TAKE command can retrieve the model saved by SAVE;
! Command files may also be created with an editor;
: look all      ! Use LOOK ALL command to check the content of save.out;

MODEL:
1) MIN= 2 * X + 3 * Y ;
2) X + Y > 5 ;
3) X > 0 ;
4) Y > 0 ;
END
```

From the previous screens, a few of the fundamental Lingo commands are introduced. However, there are still more commands for general use. To get a list of available command, you need to type COMMANDS at the Lingo prompt. To get help for a specific command, you need to type HELP LOOK at the system colon prompt, where LOOK can be replaced by any command that you need help with.