Skip to content

Commit

Permalink
enh: lamination parameters implemented for A and B
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelpsilva07 committed Oct 22, 2024
1 parent 42da54d commit 4db971d
Showing 1 changed file with 30 additions and 4 deletions.
34 changes: 30 additions & 4 deletions composipy/core/property.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,24 @@ def A(self):
'''[A] Matrix as numpy.ndarray '''

if not self._xiA is None:
raise NotImplementedError

U1, U2, U3, U4, U5 = self.plies.Invariants()
xi1, xi2, xi3, xi4 = self._xiA
T = self._total_thickness
A11 = T*(U1 + U2*xi1 + U3*xi3)
A12 = T*(-U3*xi3 + U4)
A13 = T*(U2*xi2/2 + U3*xi4)
A21 = T*(-U3*xi3 + U4)
A22 = T*(U1 - U2*xi1 + U3*xi3)
A23 = T*(U2*xi2/2 - U3*xi4)
A31 = T*(U2*xi2/2 + U3*xi4)
A32 = T*(U2*xi2/2 - U3*xi4)
A33 = T*(-U3*xi3 + U5)

self._A = np.array([[A11, A12, A13],
[A21, A22, A23],
[A31, A32, A33]])

if self._A is None:
self._A = np.zeros(9).reshape(3,3)

Expand All @@ -183,9 +200,18 @@ def A(self):

@property
def B(self):
'''[B] Matrix as numpy.ndarray '''
if not self._xiB is None:
raise NotImplementedError
'''[B] Matrix as numpy.ndarray
Note
----
Matrix [B] will be zero if defined using lamination parameters.
'''
if (not self._xiA is None
and not self._xiD is None):
self._A = np.array([[0., 0., 0.],
[0., 0., 0.],
[0., 0., 0.]])

if self._B is None:
self._B = np.zeros(9).reshape(3,3)

Expand Down

0 comments on commit 4db971d

Please sign in to comment.