Solved

Question about sets that involve the dollar symbol ‘$’

  • 27 May 2020
  • 1 reply
  • 127 views

Badge +1

Hi all,

I would like to define a set of valid CAPEX units.  To this end, I wrote:

Set SI_Valid_CAPEX_Cost_Units {

    Definition: {

        data{$/kW,$/MJ}


    }

}

However, I obtain the compilation error “The symbol “$” is not expected.”  The error points to the line data{$/kW,$/MJ}

 

I can’t figure out why, since I defined another set this way:

Set PossibleUnits {

Definition: data { g, kg, oz, j, kj, kcal };

}

 

icon

Best answer by Curious AIMMS-bot 27 May 2020, 15:28

View original

1 reply

Badge +1

Alright ! I should put my elements between single quotes '$/kW' when declaring them, as follows:

data{'$/kW','$/MJ'}

With special characters, it is mandatory.

Reply


Didn't find what you were looking for? Try searching on our documentation pages:

AIMMS Developer & PRO | AIMMS How-To | AIMMS SC Navigator