IF conditions
*IF, value1, oper, value2
*ELSEIF, value1, oper, value2
*ELSE
*ENDIF
Processes a group of commands conditionally
*IF-conditions can be utilized to process a group of commands in the user model input file conditionally.- The command sequence to be processed starts with
*IF,*ELSEIFor*ELSEdepending on the condition and ends with*ENDIFor*ELSE.*IF-conditions can be nested.
*IF,x_sym,eq,0
SPRI,1+offs,3+offs,,,spring_w,,0;
*ELSE
SPRI,1+offs,3+offs,,,spring_w,,,0;
*ENDIF
Input Data⚓︎
| Parameter | Description |
|---|---|
val1 |
First numerical value to be compared → Real, integer or a mathematical term in MATLAB-syntax |
oper |
Operation label for the Boolean condition → eq = Equal → ne = Not equal → lt = Less than → le = Less than or equal → ge = Greater than or equal → gt = Greater than |
val2 |
Second numerical value to be compared → Real, integer or a mathematical term in MATLAB-syntax |