BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
ODENWALD
Obsidian | Level 7

Hi :

 

I have two questions :

 

1.  Frequently one needs a term as   j * T[j] :  that's no problem if  j is numeric. However if you have { j in ARCS}  and your  ARCS  are  <NY,SF>  or the like you would need something as the  order function in  GAMS  ord(j) :  What is the equivalent in Optmodel ? Add :  When I write  { j in ARCS}  essentially I leave it to SAS to determine the order in which the arcs are processed: how can I recover that order ?

 

2.  People have to use what they find at their places. So it can occur that one has to translate a model formulation from  GAMS  to  SAS (Optmodel)  ore vice versa. Are you aware of any compilation of a kind of correspondence table between the two systems ?

 

3.  What is the state of the affairs with a  MINLP solver for Optmodel ??  GAMS  can  access one.

SAS  BLACKBOX -  and  LSO - solvers both say they would perform with  around  100  variables.

Frequently you find yourself with around   600  which can technically go to  ~ 2000  variables  ......

 

I understand that  Q3  needs time for answering.  Q1  and  Q2  should go more easily.

 

Kind regards,  ODENWALD .

1 ACCEPTED SOLUTION

Accepted Solutions
RobPratt
SAS Super FREQ

1. Here's a simple example that creates an ord array to access the set members by position:

proc optmodel; 
   set S = /A B C/; 
   str ord {1..card(S)}; 
   num count init 0; 
   for {i in S} do; 
      count = count + 1; 
      ord[count] = i; 
   end; 
   print ord; 
   print ord[2];
quit;

2. I'm not aware of any such table.

3. We do have long-term plans to provide a generic MINLP solver.  For now, Blackbox is the best choice.  Coming soon, OPTMODEL will provide automated linearization for several common use cases.  Stay tuned!

View solution in original post

6 REPLIES 6
RobPratt
SAS Super FREQ

1. Here's a simple example that creates an ord array to access the set members by position:

proc optmodel; 
   set S = /A B C/; 
   str ord {1..card(S)}; 
   num count init 0; 
   for {i in S} do; 
      count = count + 1; 
      ord[count] = i; 
   end; 
   print ord; 
   print ord[2];
quit;

2. I'm not aware of any such table.

3. We do have long-term plans to provide a generic MINLP solver.  For now, Blackbox is the best choice.  Coming soon, OPTMODEL will provide automated linearization for several common use cases.  Stay tuned!

RobPratt
SAS Super FREQ

The linearization feature I mentioned is now available.  The idea is that you use the nonlinear expressions directly and then call:

solve linearize;

For several common linearizable use cases, OPTMODEL introduces the new variables and constraints for you under the hood.

ODENWALD
Obsidian | Level 7

Rob :  Thanks for the info.

Is it in  (SAS 9.4, Rev. 940_20w39) or in a more recent one

which is not yet listed ?

 

Odenwald

RobPratt
SAS Super FREQ

It is in SAS Optimization in SAS Viya 2020.1.1.

ODENWALD
Obsidian | Level 7

When will it show up in  SAS/OR ?

 

Odenwald

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

Multiple Linear Regression in SAS

Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 6 replies
  • 664 views
  • 1 like
  • 2 in conversation