LINGO TUTORIAL. WHAT IS LINGO : LINGO is a software tool designed to efficiently build and solve linear, nonlinear, and integer optimization models. CREATING.

Slides:



Advertisements
Similar presentations
IENG313 Operation Research I
Advertisements

Word Processing and Desktop Publishing Software
What is GAMS?. While they are not NLP solvers, per se, attention should be given to modeling languages like: GAMS- AIMMS-
Templates and Styles Excel Advanced. Templates are pre- designed and formatted spreadsheets –They provide consistency of layout/structure –They.
Microsoft Office 2007 Excel Chapter 8 Formula Auditing, Data Validation, and Complex Problem Solving.
Getting Started: Ansoft HFSS 8.0
Programming in Visual Basic
Lecture 2 Introduction to C Programming
Introduction to C Programming
 2005 Pearson Education, Inc. All rights reserved Introduction.
 2000 Prentice Hall, Inc. All rights reserved. Chapter 2 - Introduction to C Programming Outline 2.1Introduction 2.2A Simple C Program: Printing a Line.
Introduction to C Programming
By Hrishikesh Gadre Session II Department of Mechanical Engineering Louisiana State University Engineering Equation Solver Tutorials.
 2007 Pearson Education, Inc. All rights reserved Introduction to C Programming.
XP New Perspectives on Microsoft Office Word 2003 Tutorial 1 1 Microsoft Office Word 2003 Tutorial 1 – Creating a Document.
Introduction to C Programming
COMPREHENSIVE Excel Tutorial 8 Developing an Excel Application.
Chapter 9 Introduction to ActionScript 3.0. Chapter 9 Lessons 1.Understand ActionScript Work with instances of movie clip symbols 3.Use code snippets.
A detailed guide on how to set-up your printing storefront. Please Note: Storefronts are compatible with all browsers, however for optimal use of the admin.
Introduction to MATLAB ENGR 1187 MATLAB 1. Programming In The Real World Programming is a powerful tool for solving problems in every day industry settings.
An Introduction to Microsoft Word. Microsoft Word This program allows you to type letters, papers, reports and even books. It is available through the.
XP New Perspectives on Microsoft Access 2002 Tutorial 41 Microsoft Access 2002 Tutorial 4 – Creating Forms and Reports.
Microsoft Word 2010 Chapter 1 Creating, Formatting, and Editing a Word Document with Pictures.
Using a Spreadsheet Chapter 5.
Microsoft Office 2007 Word Chapter 1 Creating and Editing a Word Document.
For Version 6.0 and later Lattice3D Reporter Tutorial For Version 6.0 and later LATTICE TECHNOLOGY, INC.
Microsoft Office 2003 Illustrated Brief Document Creating a.
MagicInfo Pro Scheduler Now that a template has been created from content imported into the Library, the user is ready to begin scheduling content to.
Microsoft Access Lesson 1 Lexington Technology Center February 11, 2003 Bob Herring On the Web at
1 ADVANCED MICROSOFT EXCEL Lesson 9 Applying Advanced Worksheets and Charts Options.
An Introduction to Microsoft Word. Microsoft Word This program allows you to type letters, papers, and other documents. This program allows you to type.
· Adding and Renaming Worksheets
Microsoft Access 2000 Presentation 2 Creating Databases Part I (Creating Tables)
Productivity Programs Common Features and Commands.
Chapter 17 Creating a Database.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Chapter 2 Chapter 2 - Introduction to C Programming.
1 ADVANCED MICROSOFT WORD Lesson 14 – Editing in Workgroups Microsoft Office 2003: Advanced.
McGraw-Hill Technology Education © 2004 by the McGraw-Hill Companies, Inc. All rights reserved. Office Access 2003 Lab 2 Modifying a Table and Creating.
Introduction to Visual Basic Programming. Introduction Simple Program: Printing a Line of Text Another Simple Program: Adding Integers Memory Concepts.
Word 2003 The Word Screen. Word 2003 Screen File Menu –Holds the options for creating a new document, opening a document, saving a document, printing.
Introduction to Word Processing.  Learn uses of word-processing software  Differentiate between typewriter and word- processing software  Explore various.
Introducing Dreamweaver. Dreamweaver The web development application used to create web pages Part of the Adobe creative suite.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 1 Chapter 2 - Introduction to C Programming Outline.
Unit 3: Text, Fields & Tables DT2510: Advanced CAD Methods.
CorrectWrongHome Desktop 100 Toolbars Best Friends MiscNerdville
1 EPIB 698C Lecture 1 Instructor: Raul Cruz-Cano
Linear Programming McGraw-Hill/Irwin Copyright © 2012 by The McGraw-Hill Companies, Inc. All rights reserved.
MS WORD INFORMATION TECHNOLOGY MANAGEMENT SERVICE Training & Research Division.
Understanding Word Vocabulary
1 Lecture 2 - Introduction to C Programming Outline 2.1Introduction 2.2A Simple C Program: Printing a Line of Text 2.3Another Simple C Program: Adding.
LINGO TUTORIAL.
Formula Auditing, Data Validation, and Complex Problem Solving
Excel Tutorial 8 Developing an Excel Application
SQL and SQL*Plus Interaction
Microsoft Office Access 2010 Lab 2
IENG 212 LAB 1 Research Assıstant: Kehınde Adewale ADESINA
Chapter 2 - Introduction to C Programming
Current outstanding balance
Chapter 2 - Introduction to C Programming
The How-to-Guide for Using Word
Microsoft Excel All editions of Microsoft office.
Chapter 2 - Introduction to C Programming
Chapter 2 - Introduction to C Programming
Chapter 2 - Introduction to C Programming
Chapter 2 - Introduction to C Programming
Word Processing and Desktop Publishing Software
Chapter 2 - Introduction to C Programming
Introduction to C Programming
IENG 212 LAB 1 Research Assıstant: Kehınde Adewale ADESINA
Presentation transcript:

LINGO TUTORIAL

WHAT IS LINGO : LINGO is a software tool designed to efficiently build and solve linear, nonlinear, and integer optimization models. CREATING A LINGO MODEL: An optimization model consists of three parts: Objective function: This is single formula that describes exactly what the model should optimize. Variables: These are the quantities that can be changed to produce the optimal value of the objective function. Constraints: These are formulas that define the limits on the values of the variables.

PRIMARY RULES Comments in the model are initiated with an exclamation point (!) and appear in green text. LINGO specified operators and functions appear in blue text. All other text is shown in black. Each LINGO statement must end in a semi-colon (;). Variable names are not case-sensitive and must begin with a letter (A-Z). Other characters in the variable name may be letters, numbers (0-9), or the underscore character (_). Variable names can be up to 32 characters in length.

LINGO OPERATORS: Exponentiation: ^ Multiplication: * Division: / Addition: + Subtraction: - The relational operators are used when defining the constraints for a model. They are as follows: The expression is equal: = The left side of the expression is less than or equal to the right side: <= The left side of the expression is greater than or equal to the right side: >=

COMMON LINGO ERROR MESSAGES: Unable to open file: filename Retype filename correctly Invalid input: A syntax error has occurred Check the line LINGO suggests for missing semi-colons, etc. Unmatched parenthesis Close the parenthesis set No relational operator found Make sure all constraints contain =, =

Unterminated condition Put a colon at the end of each conditional statement in a set operator The model’s dimensions exceed the capacity of this version No feasible solution found Check model’s consistency and constraints Unbounded solution Add constraints Unrecognized variable name: variable name Check spelling

A SIMPLE EXAMPLE: MAX = 3*x1+x2; x1 <= 4; x1+x2 <= 7; Once the LINGO model has been entered into the LINGO Model window, the model can be solved by clicking the Solve button on the toolbar, by selecting LINGO Solve from the menus.

If no errors are found, then the LINGO Solver Status window appears.

REPORTS: LINGO will notify you of any errors it has encountered. The best way to get information about these errors is to consult the Error Messages section in the software’s proprietary tutorial.

This window shows the values of each variable that will produce the optimal value of the objective function. The reduced cost for any variable that is included in the optimal solution is always zero. For variables not included in the optimal solution, the reduced cost shows how much the value of the objective function would decrease (for a MAX problem) or increase (for a MIN problem) if one unit of that variable were to be included in the solution. For example, if the reduced cost of a certain variable was 5, then the optimal value of the MAX problem would decrease by 5 units if 1 unit of the variable were to be added.

A SIMPLE EXAMPLE: A cookie store can produce drop cookies and decorated cookies, which sell for $1 and $1.50 apiece,respectively. The two bakers each work 8 hours per day and can produce up to 400 drop cookies and 200 decorated cookies. It takes 1 minute to produce each drop cookie and 3 minutes to produce each decorated cookie. What combination of cookies produced will maximize the baker's profit ?

SOLUTION: Model: MAX = 1*Drop + 1.5*Deco; Drop <= 400; Deco <= 200; 1/60*Drop + 3/60*Deco <=16; Drop>=0; Deco>=0;

1. File Menu Commands: NewOpens a new model window. OpenOpens an existing model previously saved to disk. SaveSaves the contents of the current window to disk. Save AsSaves the contents of the current window to a new name. CloseCloses the current window. PrintPrints the contents of the current window. Print SetupConfigures your printer. Print PreviewDisplays the contents of the current window as it would appear if printed Log OutputOpens a log file for logging output to the command window. Take CommandsRuns a command script contained in a file. Export FileExports a model in MPS or MPI file format. LicensePrompts you for a new license password to upgrade your system. Database User Info Prompts you for a user id and password for database access via function. ExitExits LINGO.

2. Edit Menu Commands: UndoUndoes the last change. RedoRedoes the last undo command. CutCuts the current selection from the document. CopyCopies the current selection to the clipboard. PastePastes the contents of the clipboard into the document. Paste SpecialPastes the contents of the clipboard into the document, allowing choice as to how the object is pasted. Select AllSelects the entire contents of the current window. FindSearches the document for the occurrence of a specified text string. Find NextRepeats the find operation for the last string specified. ReplaceReplaces a specified text string with a new string. Go To LineMoves the cursor to a specified line number. Match ParenthesisFinds the parenthesis that closes a selected parenthesis. Paste FunctionPastes a template of a selected Select FontSpecifies a font for a selected block of text. Insert New ObjectEmbeds an OLE (Object Linking and Embedding) object into the document. LinksControls the links to external objects in your document. Object PropertiesSpecifies the properties of a selected, embedded object.

3. LINGO Menu Commands: SolveSolves the model in the current window. SolutionGenerates a solution report window for the current model. RangeGenerates a range analysis report for the current window. OptionsSets system options. GenerateGenerates the algebraic representation for the current model. PictureDisplays a graphical picture of a model in matrix form. DebugTracks down formulation errors in infeasible and unbounded linear programs. Model StatisticsDisplays a brief report regarding the technical detail of a model. LookGenerates a formulation report for the current window.