[MBDyn-users] What is the exact definition of the "AssRes" and the "AssJac" member function of the Elem class defined in base/elem.h?
Pierangelo Masarati
masarati at aero.polimi.it
Tue Jan 25 15:35:28 CET 2011
Resch Reinhard wrote:
> Dear ladies and gentlemen,
>
> I am trying to implement a user defined element which imposes a
> configuration dependent force to the system. Especially the reaction
> forces of a hydrodynamic journal plain bearing should be imposed in
> this way. For this purpose the member functions "AssRes" and "AssJac"
> have to be provided by the user defined element. I guess that for a
> simple linear time invariant element with stiffness matrix K and
> damping matrix D the member function "AssRes" should return the
> residuum -f = -K*y - D * diff(y,t). I also guess that the member
> function "AssJac" should return diff(f,diff(y,t)) + dCoef * diff(f,y)
> = D + dCoef * K.
>
> Where the factor "dCoef" seems to be a so called "derivative
> coefficient" which is defined by the following equation: delta(y) =
> dCoef * delta(diff(y,t))
>
> y ... the vector of the node
> position and rotation angles of the nodes connected to the element
> f ... the residuum e.g. the imposed forces and torques at the nodes
> connected to the element
> delta(y) ... the
> increment of y for the current time step
> diff(y,t) ... the derivative of y versus the time e.g. the vector of velocities
> and angular velocities of the nodes connected to the element
> delta(diff(y,t)) ... the increment of diff(y,t) for
> the current time step
> diff(f,y) = K ... the
> derivative of the force f versus y; in this case it is simply the
> stiffness matrix of the element
> diff(f,diff(y,t)) = D ...
> the derivative of the force f versus the diff(y,t); in this case it
> is simply the damping matrix of the element
Hello. Your understanding is fine. I only note two things:
1) the contribution to the residual of the element you describe is
f = -K*y - D*diff(y,t)
and the contribution to the Jacobian matrix is
diff(-f,diff(y,t)) + dCoef*diff(-f,y)
which is substantially the same;
2) vector "y" contains the states, which are not limited to node
positions and so, but actually contain node positions, rotation
parameters (something different from just "angles"), momentum and
momenta moments for structural nodes, and something else for other
fields, so you should not make assumptions on the contents of that
vector but only access it through the appropriate interface (e.g. by
asking nodes to provide positions, orientations and so).
Hope this helps.
Cheers, p.
PS: your project sounds pretty interesting, please let us know at your
will about its status.
More information about the MBDyn-users
mailing list