pyHarm.Elements.NodeToNodeElements.Penalty3D ============================================ .. py:module:: pyHarm.Elements.NodeToNodeElements.Penalty3D Attributes ---------- .. autoapisummary:: pyHarm.Elements.NodeToNodeElements.Penalty3D.jaxf pyHarm.Elements.NodeToNodeElements.Penalty3D.jaxf Classes ------- .. autoapisummary:: pyHarm.Elements.NodeToNodeElements.Penalty3D.Penalty3D Functions --------- .. autoapisummary:: pyHarm.Elements.NodeToNodeElements.Penalty3D.evalResidual_jax Module Contents --------------- .. py:function:: evalResidual_jax(x, om, Pdir, Pslave, Pmaster, mu, N0, g, k_n, k_t, DFT, DTF) .. py:data:: jaxf .. py:data:: jaxf :value: None .. py:class:: Penalty3D(nh: int, nti: int, name: str, data: dict, CS: pyHarm.CoordinateSystem.CoordinateSystem) Bases: :py:obj:`pyHarm.Elements.NodeToNodeElements.NodeToNodeElement.NodeToNodeElement` This element is a combination of an unilateral gap element and a jenkins element on the perpendicular directions when contact is made. .. attribute:: g gap value. :type: float .. attribute:: k_n linear spring value for the unilateral gap. :type: foat .. attribute:: k_t linear spring value for the jenkins. :type: foat .. attribute:: mu friction coefficient. :type: float .. attribute:: N0 normal preload on the element. :type: float .. attribute:: jac if "analytical" uses analytical expression of jacobian, if "jax" uses automatic differentiation, if "DF" uses finite difference. :type: str .. py:attribute:: factory_keyword :type: str :value: 'Penalty3D' keyword that is used to call the creation of this class in the system factory. :type: str .. py:method:: __post_init__() .. py:method:: __flag_update__() .. py:method:: adim(lc, wc) Modifies the element properties according to the characteristic length and angular frequency. .. attribute:: k_n modified linear coefficient for the unilateral gap to apply according to the characteristic parameters. :type: float .. attribute:: k_n modified linear coefficient for the jenkins to apply according to the characteristic parameters. :type: float .. attribute:: g modified gap value according to the characteristic parameters. :type: float .. attribute:: flag_adim True if equations are to be adimensionalized :type: bool .. py:method:: evalResidual(xg, om) Computes the residual. :param xg: full displacement vector. :type xg: np.ndarray :param om: angular frequency value. :type om: float :returns: residual vector. :rtype: np.ndarray .. py:method:: _evalJaco_ana(xg, om) .. py:method:: evalJacobian(xg, om) Computes the jacobians. :param xg: full displacement vector. :type xg: np.ndarray :param om: angular frequency value. :type om: float :returns: Jacobian with respect to displacement. np.ndarray: Jacobian with respect to angular frequency. :rtype: np.ndarray