valA()

value of a scalar variable

[ ... valA("ScalarVariable") ... ] [ ... valA("VectorVariable",iArg) ... ]

For the given "ScalarVariable", the RightHandSide or CONSTRUCT statement is evaluated and returns the current value, IF it is a number. Otherwise, return 0.

For the given "VectorVariable", the component specified via iArg is returned. Note that, if a floating point variable is supplied as iArg, it is converted to the nearest integer value.

Other than the ConstructClause within a begin_construct{ environment, the value can be updated in every timestep as the corresponding statements are evaluated whenever valA() is called, e.g. within an INTEGRATION statement.

# Initialization of variables begin_construct{} "repeatedAlias" = "0" "repeatedCOG" = "0" end_construct # (Re-)Definition of variables -> "repeatedAlias" = CONSTRUCT( %CONSTRUCT_Area%, "membrane" ) # scalar alias/construct variable -> "repeatedCOG" = CONSTRUCT( %CONSTRUCT_COG%, "wheel" ) # vector valued alias/construct variable # Usage within formula [INTEGRATION($INT_n$) = ( %PUBLICVALUE%, [ valA("repeatedAlias") ], %INTEGRATION_Header%, "Area of the membrane" ) [INTEGRATION($INT_n1$) = ( %PUBLICVALUE%, [ valA("repeatedCOG",1) ], %INTEGRATION_Header%, "x-coordinate of wheel-COG" ) [INTEGRATION($INT_n2$) = ( %PUBLICVALUE%, [ valA("repeatedCOG",2) ], %INTEGRATION_Header%, "y-coordinate of wheel-COG" ) [INTEGRATION($INT_n3$) = ( %PUBLICVALUE%, [ valA("repeatedCOG",3) ], %INTEGRATION_Header%, "z-coordinate of wheel-COG" )

Attention: The RightHandSideExpression can only contain expressions that yield a scalar result. Evaluations on the pointcloud are not possible, as they would not be meaningful.

Attention: Currently, it is necessary to initialize variables which are re-evaluated in each timestep by a construct statement (see example above). This initialization should be a number and not an arbitrary character string!

Attention: Handle with care, as for each evaluation of this function, the MESHFREE text parser is employed. It searches in the list of aliases, and recursively interprets the alias on text-basis, then the tesxt-result is transformed into a numerical value. The performance is expectedly low. Hence, pointwise evaluation might be costly.