tmdsimpy.jax.nlforces.VectorJenkins

class tmdsimpy.jax.nlforces.VectorJenkins(Q, T, kt, Fs, u0=0)

Bases: NonlinearForce

Demonstration only class of JAX with vector Jenkins algorithm.

Class not intended for use in simulations, use an alternative implementation.

Parameters:
Q(1, N) numpy.ndarray

Matrix tranform from the N degrees of freedom (DOFs) of the system to the Nnl local nonlinear DOFs.

T(N, 1) numpy.ndarray

Matrix tranform from the local Nnl forces to the N global DOFs.

ktfloat

Tangential stiffness.

Fsfloat

Slip force.

u0float or None, optional

Initialization value for the slider for AFT. If u0 = None, then the zeroth harmonic is used to initialize the slider position. Highly recommended not to use u0 = None because it may result in non-unique solutions. The default is 0.

See also

tmdsimpy.nlforces.VectorJenkins

non-JAX implementation of a Jenkins element that has full functionality and can be faster.

tmdsimpy.jax.nlforces.JenkinsForce

JAX implementation of Jenkins element without vectorization.

Notes

This implementation tries to use a more efficient Jenkins implementation for AFT that requires fewer operations. However, given JAX constraints for just-in-time compliation (JIT), this approach is not good here.

The Jenkins element consists of a linear spring of stiffness kt that stretches until a slip force Fs is reached. Once the slip force is reached, an anchor point for the other side of the spring moves to maintain the slip force until reversal.

The force method is not implemented here since this is just an example of automatic differentiation for AFT.

__init__(Q, T, kt, Fs, u0=0)

Methods

__init__(Q, T, kt, Fs[, u0])

aft(U, w, h[, Nt, tol])

Implementation of the alternating frequency-time (AFT) method to extract harmonic nonlinear force coefficients.

force(X)

Template force function for evaluating the nonlinear force for a set of global displacements.

nl_force_type()

Method to return a flag for the force type.

aft(U, w, h, Nt=128, tol=1e-07)

Implementation of the alternating frequency-time (AFT) method to extract harmonic nonlinear force coefficients.

Parameters:
U(N*Nhc,) numpy.ndarray

Displacement harmonic DOFs (global)

wfloat

Frequency in rad/s. Needed in case there is velocity dependency.

hnumpy.ndarray, sorted

List of harmonics. The list corresponds to Nhc harmonic components.

Ntint power of 2, optional

Number of time steps used in evaluation. The default is 128.

tolfloat, optional

This argument is ignored, and is included for compatability of interface. The default is 1e-7.

Returns:
Fnl(N*Nhc,) numpy.ndarray

Nonlinear hamonic force coefficients

dFnldU(N*Nhc,N*Nhc) numpy.ndarray

Jacobian of Fnl with respect to U

dFnldw(N*Nhc,) numpy.ndarray

Jacobian of Fnl with respect to w

Notes

The tolerance tol is ignored because the Jenkins element converges to steady-state with two cycles of the hysteresis loop. Two cycles of the nonlinear forces are calculated automatically without the option to change this setting.

force(X)

Template force function for evaluating the nonlinear force for a set of global displacements.

Parameters:
X(N,) numpy.ndarray

Global displacements

Returns:
F(N,) numpy.ndarray

Global forces

dFdX(N,N) numpy.ndarray

Derivative of global forces with respect to global displacements X

nl_force_type()

Method to return a flag for the force type.

Returns:
int

Value indicates the force type. 0 == Instantaneous Force Type. 1 == Hysteretic Force Type.