FIX: Difference between revisions

From ASCEND
Jump to navigation Jump to search
Created page with '{{missing}} Category:Documentation'
 
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{missing}}
The '''FIX''' statements is used in the [[METHOD]]s part of a model to constrain particular variables in the model. A variable which has been fixed has a known value assigned to it, and ASCEND will not attempt to change that value. The FIXed variables in a model are used as the basis from which the remaining un-FIXed ([[FREE]]) variables can be calculated. By default, no variables are FIXed until an explicit command to FIX them is given.
[[Category:Documentation]]
 
<source lang="a4c">(* add this to the example on the FIX page *)
METHOD solve_x;
 
    (* reconfigure the model to solve for x such that y=0 *)
    FREE x;
    FIX y;
    y:= 0;
 
END solve_x;</source>
 
Note that variables can also be FIXed and FREEd in an ad-hoc way, using the ASCEND GUI.
 
See also [[FREE]].
 
[[Category:Syntax]]

Latest revision as of 09:03, 2 August 2010

The FIX statements is used in the METHODs part of a model to constrain particular variables in the model. A variable which has been fixed has a known value assigned to it, and ASCEND will not attempt to change that value. The FIXed variables in a model are used as the basis from which the remaining un-FIXed (FREE) variables can be calculated. By default, no variables are FIXed until an explicit command to FIX them is given.

(* add this to the example on the FIX page *)
METHOD solve_x;

    (* reconfigure the model to solve for x such that y=0 *)
    FREE x;
    FIX y;
    y:= 0;

END solve_x;

Note that variables can also be FIXed and FREEd in an ad-hoc way, using the ASCEND GUI.

See also FREE.