GAMS Display style

2019-07-23 02:27发布

How do I display a text in GAMS? For example: in MATLAB I can use disp('MATLAB'), then I will get the output as MATLAB.

Is it possible to have like this in GAMS. In fact, I am new with GAMS environment.

Regards

2条回答
Evening l夕情丶
2楼-- · 2019-07-23 03:09

There are actually two ways:

  • $log "text to display" if you want it to appear during the compilation phase (and shows only in .log file)
  • display "text to display" ; if you want it to appear during the execution phase (and shows only in .lst file)
查看更多
Root(大扎)
3楼-- · 2019-07-23 03:23

display "Hi, warning message here!"

... should work. This will appear in your .LST file, which you should get familiar with reading for debugging purposes.

查看更多
登录 后发表回答