Scale

Top  Previous  Next

Variables and equations have a scale attribute.  The scale attribute for a variable is a number that all coefficients associated with that variable are multiplied by.  The scale attribute for an equation is a number that all coefficients associated with that equation are divided by.  The attribute is addressed using .Scale as follows

 

Variable scale factor is variablename.scale(setdependency)

Equation scale factor is equationname.scale(setdependency)

 

These are commonly used in calculations pre solution to specify or revise the scaling factors.

Example:

(varmodatt.gms)

Transport.scaleopt=1;

Move.scale("boston","seattle")=10.;

Notes:

The scale factors only work if the modelname.scaleopt is set to a non zero value.
Scaling is discussed in the Scaling GAMS Models chapter.
Scaling factors default to one.