Tiny GAMS GuideNote: this Tiny GAMS Guide refers to GAMS Release 2.50. Step 1 Double click on GAMS icon
Step 2 After the first install, you might be asked to create a new GAMS project. You can create a new project by going to File, then Project, and then New Project:
Step 3 Specify where you want to locate in your computer the GAMS project and create a folder for the GAMS project:
Step 4 Inside the GAMS project folder, type the name of the project, in the File name, and then click Open:
It is not necessary that the name of the project folder be the same as the name of project. In fact, one project folder can be a host of two or more GAMS projects.
Step 5 To enter your GAMS model, create a new file, called gms file, by going to File and then New:
Step 6 A blank file opens up:
Step 7 Enter your GAMS code:
Step 8 Save your file by going to File and then Save as. Step 9 Before you can run your GAMS code, it is a good idea always to choose the solver you want to use. To do that, go to File and choose Options:
Step 10 Click on Solvers tab:
Step 11 Under NLP, choose the applicable GAMS solver by clicking on the small square in front of the solver to change it to a cross:
Step 12 Click OK. Step 13 To run the code, press F9
or click on the shortcut button
Step 14 In the right portion of the GAMS window, the LOG file is going to appear. The LOG file tells you of any errors in your code, and if there are no errors, it tells you that the solution is found, which is indicated by the statement ‘Status: Normal completion’:
Step 15 Open the GAMS LST file and go all the way to the bottom of the file to see the solution:
Tiny GAMS Guide by Dr Muhammad Al-Salamah, Industrial Engineering, KFUPM, Dhahran, Saudi Arabia الدكتور محمد بن فهد السلامة، هندسة صناعية، جامعة الملك فهد، الظهران، السعودية |