You are on page 1of 7

AS-022

Product(s): Feature(s): Directory: Files:

Computing a Compliance Matrix Using Utility Subroutine GTCMAT


ADAMS/Solver (C++) Utility subroutine GTCMAT

Compliance.zip compliance.adm, compliance.acf, compliance.f

Problem Statement This example shows you how to use the GTCMAT utility subroutine to obtain a compliance matrix using ADAMS/Solver (C++). GTCMAT can be called during a dynamic or a static simulation. For more information, see the Theoretical Overview on the computation of the compliance following the example. Model Description The model consists of two wheels connected to ground by bushings. MARKER/4 and MARKER/9 are located at the center of each wheel. Compute the compliance between the two MARKERs above. Running the GTCMAT example To obtain the required compliance: 1. Compile the file compliance.f and create the library compliance.dll. 2. Run the stand-alone solver using file compliance.acf. Tip: On Windows, open a shell window and type C> adams05r2 ru-u compliance.dll compliance.acf exit ADAMS/Solver runs the model and it writes a file name cMat.dat that has the computed compliance matrix. Theoretical Overview The input parameters in the GTCMAT utility subroutine are: 1. The number of MARKERs 2. The ADAMS ids of the MARKERs id 1 , id 2 , etc. The compliance matrix C computed by ADAMS/Solver (C++) is:

~ y=Cu

MSC.ADAMS 2005r2

-1-

August 2005

Column matrix y has this form:

DX (id1 ) DY (id ) 1 DZ (id1 ) RX (id1 ) y = RY (id 1 ) RZ (id ) 1 DX (id 2 ) DY (id 2 ) M


where:

DX (id 1 ) , DY (id1 ) , and DZ (id1 ) are the global displacement of MARKER/ id 1 in the X, Y, and Z directions respectively. RX (id1 ) , RY (id 1 ) , and RZ (id 1 ) are the global rotations of MARKER/ id 1 in
the X, Y, and Z directions respectively. These rotations do not coincide with the measures AX (id 1 ) , AY (id 1 ) and AZ (id 1 ) provided in the MSC.ADAMS function language. For example, the AX (id 1 ) rotation is defined as follows:

AX = ATAN 2( z i y j , z i z j )

where z i is the z-axis of marker I, y j is the y-axis of maker j, and z j is the


z-axis of marker j. For more information, see the ADAMS/Solver online help.

Rotations RX (id 1 ) , RY (id 1 ) and RZ (id 1 ) , however, have no equivalent functions in the MSC.ADAMS language. They are defined as follows:

RX 0 sin( Psi ) sin(Theta ) cos( Psi ) Psi RY = 0 cos( Psi ) sin(Theta ) sin( Psi ) Phi RZ 1 cos(Theta ) 0 Theta

(1)

where Psi, Phi and Theta are the Euler angles defining the orientation of the corresponding marker.

MSC.ADAMS 2005r2

-2-

August 2005

Column matrix u has this form:

Fx1 Fy 1 Fz1 Mx1 u = My1 Mz 1 Fx 2 Fy 2 M

(2)

where Fx1 , Fy1 , Fz1 , Mx1 , My1 , and Mz1 correspond to applied forces and torques acting on MARKER/id1. The applied forces and torques act along the global axes. Algorithm to compute the compliance In order to obtain the compliance matrix C , ADAMS/Solver (C++) first linearizes the system as follows:

& X = AX + Bu y temp = CX

(3) (4)

& systems states, and X stands for the corresponding time derivative. These vectors are defined as follows:
V X= X & & V X= & X

Notice that there is no D matrix. Vector X stands for the perturbation of the

MSC.ADAMS 2005r2

-3-

August 2005

Vector u is defined exactly as shown in Equation 2 above. Vector y temp is defined as follows:

y temp

DX (id 1 ) DY (id ) 1 DZ (id 1 ) Psi (id1 ) = Phi(id1 ) Theta (id ) 1 DX (id 2 ) DY (id 2 ) M

The next step consists of solving for X using Equation 3:

& X = A 1B u + A 1 X

(5)

Putting Equation 5 into Equation 4, we obtain the following temporary result:

& y temp = [CA 1B] u + CA 1 X


1

(6)

& Notice that the term CA X can be safely discarded because it corresponds to the time derivatives of the perturbed states. Therefore,
y temp = [CA 1B] u
(7)

The final step consists in finding a relationship between y and y temp . From Equation 1, we can compute

y = R y temp
Combining Equations 8 and 7, we finally obtain:

(8)

y = [ RCA 1B] u

MSC.ADAMS 2005r2

-4-

August 2005

Therefore, the returned compliance matrix is

~ C = [RCA 1B]
Custom compliances

(9)

Custom compliances can be computed using the LINEAR/STATE command. You are required, however, to export matrices and compute a matrix inversion and matrix multiplications. This is the approach followed by third-party utilities. First, define your INPUT and OUTPUT objects. Then, invoke the LINEAR/STATE command with the option to export the results to a file: LIN/STATE, PINPUT=1, POUTPUT=2, FILE=data FORMAT=matlab This command exports the A, B, C and D matrices. Notice that the D matrix should be identically zero. Next, import those matrices into a program like MATLAB and evaluate:

~ C = [CA 1B]
~

The custom compliance is C . Dynamic/Static compliances A dynamic compliance is calculated while the system is performing a dynamic simulation. A static compliance is calculated while the system is in static equilibrium. This section explains the relationship between those two matrices. Assume that the linearized system has n displacement states and n velocity states:

V X = nx1 X nx1

For this case, Equation 3 can be written as follows:

& Vnx1 C nxn & = X nx1 I nxn

K nxn Vnx1 Bnxm u mx1 + 0 nxn X nx1 0 nxm

MSC.ADAMS 2005r2

-5-

August 2005

From this equation, we obtain that

0 A 1 = 1 K nxn

K 1C nxn I mxm

Next, the compliance matrix Equation 9 can be written as follows:

~ C = [Rmxn

0 S mxn ] 1 K nxn

I mxm Bnxm K 1C nxn 0 nxm

(10)

where we assumed that:

RC = [Rmxn

S mxn ]

Finally, after performing the matrix multiplications shown in Equation 10, we obtain:

~ 1 C = S mxn K nxn Bmxn

(11)

The fundamental conclusion is that if the stiffness of the linearized system is not dependent on the velocities and accelerations of the system, then the compliance matrices are not dependent on the velocities of the system. The reason is because the only term in Equation 11 that depends on the state of the linearized system is matrix K nxn . One example where the compliance has a dependency on the velocities of the system would be the case of an applied force with a function expression as follows:

f = xv 2
Notice that in this case, the linearized stiffness velocity.

f depends on the magnitude of the x

As long as the forces acting on the system do not create a velocity-dependent stiffness, the velocities of the system will have no effect on the computed compliance.

MSC.ADAMS 2005r2

-6-

August 2005

Remarks Compliance matrices can now be computed during dynamic simulations. This is new feature available only when using ADAMS/Solver (C++). Custom compliance matrices can be built using the LINEAR command using the STATEMAT option. However, you are required to do the matrix operations to compute the desired compliance.

MSC.ADAMS 2005r2

-7-

August 2005

You might also like