*SetGeneralConstraint() - expression

Sets a general constraint to an expression.

Syntax

*SetGeneralConstraint(gcon_name,"EXPR")

Arguments

gcon_name
The variable name of the general constraint.
Data type: varname
EXPR
A valid solver expression.
Data type: string

Example

*BeginMDL( the_model, "Model", )
 *StandardInclude(FILE)
 *SetCurrentSolverMode(MotionSolve)
 *Body( b_0, "Body 0", , , , , )
 *Body( b_1, "Body 1", , , , , )
 *Point( p_1, "Point 1" )
 *Point( p_2, "Point 2" )
 *Marker( m_0, "Slot", b_1, p_2 )
 *Marker( m_1, "Point", b_0, p_1 )
 *GeneralConstraint( gcon_0, "GeneralConstraint 0" )
 
*SetGeneralConstraint( gcon_0, `DY({m_1.id}, {m_0.id}, {m_0.id})` )
*EndMDL()

Context

*BeginMdl()

*DefineAnalysis()

*DefineAssembly()

*DefineSystem()

*BeginContext()

Comments

This statement can be used to set a general constraint defined using a *GeneralConstraint() to an expression.

This statement is applicable for MotionSolve and ADAMS.