shell
Module¶
All shell properties are defined in this file. This includes:
PCOMP
PCOMPG
PLPLANE
PSHEAR
PSHELL
PPLANE
All shell properties are Property objects.
-
class
pyNastran.bdf.cards.properties.shell.
CompositeShellProperty
[source]¶ Bases:
pyNastran.bdf.cards.base_card.Property
- Common class for:
PCOMP
PCOMPG
dummy init
-
Material
(iply: int) → Union[MAT1, MAT8, MAT9][source]¶ Gets the material of the \(i^{th}\) ply (not the ID unless it is not cross-referenced).
- Parameters
- iplyint
the ply ID (starts from 0)
-
Mid
(iply: int) → int[source]¶ Gets the Material ID of the \(i^{th}\) ply.
- Parameters
- iplyint/str; default=’all’
the string ‘all’ (default) or the mass per area of the \(i^{th}\) ply
- Returns
- material_idint
the material id of the ith ply
-
property
TRef
¶
-
_adjust_ply_id
(iply: int) → int[source]¶ Gets the ply ID that’s stored in self.plies.
When a ply is not symmetric, this function returns the input iply. When a ply is symmetrical and the iply value is greater than the number of plies, we return the mirrored ply. For the case of a symmetrical ply, the element will always have an even number of layers.
- Parameters
- iplyint
the ply ID (0-based)
- Raises
- IndexError if iply is invalid
- ::
- Case 1 (nplies=6, len(plies)=3, lam=’SYM’):
ply 2 ply 1 ply 0 ——- sym ply 0 / 3 ply 1 / 4 ply 2 / 5
Ask for ply 3, return ply 0 Ask for ply 4, return ply 1 Ask for ply 5, return ply 2
- Case 2 (nplies=5, len(plies)=5, lam=’NO’):
ply 5 ply 4 ply 3 ply 1 ply 0
Ask for ply 3, return ply 1 Ask for ply 4, return ply 2
-
cross_reference
(model: BDF) → None[source]¶ Cross links the card so referenced cards can be extracted directly
- Parameters
- modelBDF()
the BDF object
-
get_density
(iply: int) → float[source]¶ Gets the density of the \(i^{th}\) ply
- Parameters
- iplyint
the ply ID (starts from 0)
-
get_mass_per_area
(iply='all', method: str = 'nplies') → float[source]¶ Gets the Mass/Area for the property.
\[\frac{m}{A} = \sum(\rho t) + nsm\]or
\[\frac{m}{A} - nsm = \sum(\rho t)\]and
\[\frac{m_i}{A} = rho_i t_i + nsm_i\]where \(nsm_i\) is the non-structural mass of the \(i^{th}\) ply
- Parameters
- iplystr/int; default=’all’
str : the string ‘all’ (default) or the mass per area of the \(i^{th}\) ply
- methodstr
the method to compute MassPerArea {nplies, rho*t, t}
Case 1 (iply = all)
method has no effect because the total nsm is defined
Case 2 (iply != all)
method ‘nplies’ smear the nsm based on \(n_{plies}\) (default)
\(nsm_i = nsm / n_{plies}\) # smear based on nplies
Case 3 (iply != all)
method ‘rho*t’ smear the nsm based on the mass distribution
\[nsm_i = \rho_i t_i \frac{nsm}{\sum(\rho_i t_i)}\]\[nsm_i = \rho_i t_i \frac{nsm}{\frac{m}{A} - nsm}\]Case 4 (iply != all)
method ‘t’ smear the nsm based on the thickness distribution
\[nsm_i = t_i \frac{nsm}{\sum(t_i)}\]
- .. note:: final mass calculation will be done later
-
get_mass_per_area_rho
(rhos: List[float], iply='all', method: str = 'nplies') → float[source]¶ Gets the Mass/Area for the property.
\[\frac{m}{A} = \sum(\rho t) + nsm\]or
\[\frac{m}{A} - nsm = \sum(\rho t)\]and
\[\frac{m_i}{A} = rho_i t_i + nsm_i\]where \(nsm_i\) is the non-structural mass of the \(i^{th}\) ply
- Parameters
- rhosList[float]
the densities of each ply
- iplystr/int; default=’all’
the mass per area of the \(i^{th}\) ply
- methodstr
the method to compute MassPerArea {nplies, rho*t, t}
Case 1 (iply = all)
method has no effect because the total nsm is defined
Case 2 (iply != all)
method ‘nplies’ smear the nsm based on \(n_{plies}\) (default)
\(nsm_i = nsm / n_{plies}\) # smear based on nplies
Case 3 (iply != all)
method ‘rho*t’ smear the nsm based on the mass distribution
\[nsm_i = \rho_i t_i \frac{nsm}{\sum(\rho_i t_i)}\]\[nsm_i = \rho_i t_i \frac{nsm}{\frac{m}{A} - nsm}\]Case 4 (iply != all)
method ‘t’ smear the nsm based on the thickness distribution
\[nsm_i = t_i \frac{nsm}{\sum(t_i)}\]
- .. note:: final mass calculation will be done later
-
get_mass_per_area_structure
(rhos: List[float]) → float[source]¶ Gets the Mass/Area for the property structure only (doesn’t consider nsm).
\[\frac{m}{A} = \sum(\rho t)\]- Parameters
- rhosList[float]
the densities of each ply
-
get_sout
(iply: int) → str[source]¶ Gets the the flag identifying stress/strain outpur of the \(i^{th}\) ply (not the ID). default=’NO’.
- Parameters
- iplyint
the ply ID (starts from 0)
-
get_theta
(iply: int) → float[source]¶ Gets the ply angle of the \(i^{th}\) ply (not the ID)
- Parameters
- iplyint
the ply ID (starts from 0)
-
get_thickness
(iply: Union[int, str] = 'all') → float[source]¶ Gets the thickness of the \(i^{th}\) ply.
- Parameters
- iplyint/str; default=’all’
the string ‘all’ (default) or the mass per area of the \(i^{th}\) ply
- Returns
- thicknessfloat
the thickness of the ply or plies
-
get_z_locations
() → numpy.ndarray[source]¶ Gets the z locations for the various plies.
- Parameters
- iplyint
the ply ID (starts from 0)
- Assume there are 2 plies, each of 1.0 thick, starting frommath:z=0.
- >>> pcomp.get_z_locations()
- [0., 1., 2.]
-
property
is_symmetrical
¶ Is the laminate symmetrical?
- Returns
- is_symmetricalbool
is the SYM flag active?
-
property
material_ids
¶ Gets the material IDs of all the plies
- Returns
- midsMATx
the material IDs
-
property
nplies
¶ Gets the number of plies including the core.
if Lam=SYM: returns nplies * 2 (even) else: returns nplies
-
class
pyNastran.bdf.cards.properties.shell.
PCOMP
(pid: int, mids: List[int], thicknesses: List[float], thetas: Optional[List[float]] = None, souts: Optional[List[str]] = None, nsm: float = 0.0, sb: float = 0.0, ft: Optional[str] = None, tref: float = 0.0, ge: float = 0.0, lam: Optional[str] = None, z0: Optional[float] = None, comment: str = '')[source]¶ Bases:
pyNastran.bdf.cards.properties.shell.CompositeShellProperty
1
2
3
4
5
6
7
8
9
PCOMP
PID
Z0
NSM
SB
FT
TREF
GE
LAM
MID1
T1
THETA1
SOUT1
MID2
T2
THETA2
SOUT2
MID3
T3
THETA3
SOUT3
etc.
PCOMP
701512
0.0+0
1.549-2
0.0+0
0.0+0
SYM
300704
3.7-2
0.0+0
YES
300704
3.7-2
YES
300704
3.7-2
-45.
YES
300704
3.7-2
YES
300705
.5
0.0+0
YES
Creates a PCOMP card
- pidint
property id
- midsList[int, …, int]
material ids for each ply
- thicknessesList[float, …, float]
thicknesses for each ply
- thetasList[float, …, float]; default=None
ply angle None : [0.] * nplies
- soutsList[str, …, str]; default=None
should the stress? be printed; {YES, NO} None : [NO] * nplies
- nsmfloat; default=0.
nonstructural mass per unit area
- sbfloat; default=0.
Allowable shear stress of the bonding material. Used by the failure theory
- ftstr; default=None
failure theory; {HILL, HOFF, TSAI, STRN, None}
- treffloat; default=0.
reference temperature
- gefloat; default=0.
structural damping
- lamstr; default=None
symmetric flag; {SYM, MEM, BEND, SMEAR, SMCORE, None} None : not symmmetric
- z0float; default=None
Distance from the reference plane to the bottom surface None : -1/2 * total_thickness
- commentstr; default=’’
a comment for the card
-
_properties
= ['_field_map', 'plies', 'nplies', 'material_ids']¶
-
classmethod
add_card
(card: BDFCard, comment='')[source]¶ Adds a PCOMP card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
ft
= None¶ Failure Theory [‘HILL’, ‘HOFF’, ‘TSAI’, ‘STRN’, None]
-
get_ABD_matrices
(theta_offset: float = 0.0) → numpy.ndarray[source]¶ Gets the ABD matrix
- Parameters
- theta_offsetfloat
rotates the ABD matrix; measured in degrees
-
get_Qbar_matrix
(mid_ref: Union[MAT1, MAT8], theta: float) → np.ndarray[source]¶ theta must be in radians
-
get_individual_ABD_matrices
(theta_offset: float = 0.0) → Tuple[numpy.ndarray, numpy.ndarray, numpy.ndarray][source]¶ Gets the ABD matrix
- Parameters
- theta_offsetfloat
rotates the ABD matrix; measured in degrees
-
lam
= None¶ symmetric flag - default = No Symmetry (=None)
-
nsm
= None¶ Non-Structural Mass per unit Area
-
pid
= None¶ Property ID
-
property
plies
¶
-
repr_fields
()[source]¶ Gets the fields in their simplified form
- Returns
- fieldsList[varies]
the fields that define the card
-
tref
= None¶ Reference Temperature (default=0.0)
-
type
= 'PCOMP'¶
-
class
pyNastran.bdf.cards.properties.shell.
PCOMPG
(pid: int, global_ply_ids: List[int], mids: List[int], thicknesses: List[float], thetas: Optional[List[float]] = None, souts: Optional[List[str]] = None, nsm: float = 0.0, sb: float = 0.0, ft: Optional[str] = None, tref: float = 0.0, ge: float = 0.0, lam: Optional[str] = None, z0: Optional[float] = None, comment: str = '')[source]¶ Bases:
pyNastran.bdf.cards.properties.shell.CompositeShellProperty
1
2
3
4
5
6
7
8
9
PCOMPG
PID
Z0
NSM
SB
FT
TREF
GE
LAM
GPLYID1
MID1
T1
THETA1
SOUT1
GPLYID2
MID2
T2
THETA2
SOUT2
Creates a PCOMPG card
- Parameters
- pidint
property id
- global_ply_idsList[int]
the ply id
- midsList[int, …, int]
material ids for each ply
- thicknessesList[float, …, float]
thicknesses for each ply
- thetasList[float, …, float]; default=None
ply angle None : [0.] * nplies
- soutsList[str, …, str]; default=None
should the stress? be printed; {YES, NO} None : [NO] * nplies
- nsmfloat; default=0.
nonstructural mass per unit area
- sbfloat; default=0.
Allowable shear stress of the bonding material. Used by the failure theory
- ftstr; default=None
failure theory; {HILL, HOFF, TSAI, STRN, None}
- treffloat; default=0.
reference temperature
- gefloat; default=0.
structural damping
- lamstr; default=None
symmetric flag; {SYM, MEM, BEND, SMEAR, SMCORE, None} None : not symmmetric
- z0float; default=None
Distance from the reference plane to the bottom surface None : -1/2 * total_thickness
- commentstr; default=’’
a comment for the card
-
_properties
= ['_field_map', 'plies', 'nplies', 'material_ids']¶
-
classmethod
add_card
(card: BDFCard, comment: str = '')[source]¶ Adds a PCOMPG card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
ft
= None¶ Failure Theory
[‘HILL’, ‘HOFF’, ‘TSAI’, ‘STRN’, None]
-
lam
= None¶ symmetric flag - default = No Symmetry (NO)
-
nsm
= None¶ Non-Structural Mass per unit Area
-
pid
= None¶ Property ID
-
property
plies
¶
-
pname_fid_map
= {}¶
-
repr_fields
()[source]¶ Gets the fields in their simplified form
- Returns
- fieldsList[varies]
the fields that define the card
-
tref
= None¶ Reference Temperature (default=0.0)
-
type
= 'PCOMPG'¶
-
class
pyNastran.bdf.cards.properties.shell.
PLPLANE
(pid, mid, cid=0, stress_strain_output_location='GRID', comment='')[source]¶ Bases:
pyNastran.bdf.cards.base_card.Property
Fully Nonlinear Plane Element Properties (SOL 601) Defines the properties of a fully nonlinear (i.e., large strain and large rotation) hyperelastic plane strain or axisymmetric element.
1
2
3
4
5
PLPLANE
PID
MID
CID
STR
MSC
1
2
3
4
5
6
PLPLANE
PID
MID
CID
STR
T
NX
- Referenced by:
#- CQUAD, CQUAD4, CQUAD8, CQUADX, CTRIA3, CTRIA6, CTRIAX (MSC) #- CPLSTS3, CPLSTS4, CPLSTS6, CPLSTS8 entries (NX 10)
Creates a PLPLANE card, which defines the properties of a fully nonlinear (i.e., large strain and large rotation) hyperelastic plane strain or axisymmetric element.
- Parameters
- pidint
property id
- midint
material id; MATHP / MATHE
- cidint; default=0
???
- stress_strain_output_locationstr; default=’GRID’
???
- commentstr; default=’’
a comment for the card
-
classmethod
add_card
(card, comment='')[source]¶ Adds a PLPLANE card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
cross_reference
(model: BDF) → None[source]¶ Cross links the card so referenced cards can be extracted directly
- Parameters
- modelBDF()
the BDF object
-
pid
= None¶ Property ID
-
repr_fields
()[source]¶ Gets the fields in their simplified form
- Returns
- fieldsList[varies]
the fields that define the card
-
type
= 'PLPLANE'¶
-
class
pyNastran.bdf.cards.properties.shell.
PPLANE
(pid, mid, t=0.0, nsm=0.0, formulation_option=0, comment='')[source]¶ Bases:
pyNastran.bdf.cards.base_card.Property
NX specific card
-
classmethod
add_card
(card, comment='')[source]¶ Adds a PPLANE card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
cross_reference
(model: BDF) → None[source]¶ Cross links the card so referenced cards can be extracted directly
- Parameters
- modelBDF()
the BDF object
-
pid
= None¶ Property ID
-
repr_fields
()[source]¶ Gets the fields in their simplified form
- Returns
- fieldsList[varies]
the fields that define the card
-
type
= 'PPLANE'¶
-
classmethod
-
class
pyNastran.bdf.cards.properties.shell.
PSHEAR
(pid: int, mid: int, t: float, nsm: float = 0.0, f1: float = 0.0, f2: float = 0.0, comment: str = '')[source]¶ Bases:
pyNastran.bdf.cards.base_card.Property
Defines the properties of a shear panel (CSHEAR entry).
1
2
3
4
5
6
7
PSHEAR
PID
MID
T
NSM
F1
F2
Creates a PSHEAR card
- Parameters
- pidint
property id
- midint
material id
- tfloat
shear panel thickness
- nsmfloat; default=0.
nonstructural mass per unit length
- f1float; default=0.0
Effectiveness factor for extensional stiffness along edges 1-2 and 3-4
- f2float; default=0.0
Effectiveness factor for extensional stiffness along edges 2-3 and 1-4
- commentstr; default=’’
a comment for the card
-
classmethod
add_card
(card, comment='')[source]¶ Adds a PSHEAR card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
cross_reference
(model: BDF) → None[source]¶ Cross links the card so referenced cards can be extracted directly
- Parameters
- modelBDF()
the BDF object
-
mid
= None¶ Material ID
-
pid
= None¶ Property ID
-
pname_fid_map
= {4: 't', 'T': 't'}¶
-
type
= 'PSHEAR'¶
-
class
pyNastran.bdf.cards.properties.shell.
PSHELL
(pid: int, mid1: Optional[int] = None, t: Optional[float] = None, mid2: Optional[int] = None, twelveIt3: float = 1.0, mid3: Optional[int] = None, tst: float = 0.833333, nsm: float = 0.0, z1: Optional[float] = None, z2: Optional[float] = None, mid4: Optional[int] = None, comment: str = '')[source]¶ Bases:
pyNastran.bdf.cards.base_card.Property
1
2
3
4
5
6
7
8
9
PSHELL
PID
MID1
T
MID2
12I/T**3
MID3
TS/T
NSM
Z1
Z2
MID4
PSHELL
41111
1
1.0000
1
1
0.02081
Creates a PSHELL card
- Parameters
- pidint
property id
- mid1int; default=None
defines membrane material defines element density (unless blank)
- mid2int; default=None
defines bending material defines element density if mid1=None
- mid3int; default=None
defines transverse shear material (only defined if mid2 > 0)
- mid4int; default=None
defines membrane-bending coupling material (only defined if mid1 > 0 and mid2 > 0; can’t be mid1/mid2)
- twelveIt3float; default=1.0
Bending moment of inertia ratio, 12I/T^3. Ratio of the actual bending moment inertia of the shell, I, to the bending moment of inertia of a homogeneous shell, T^3/12. The default value is for a homogeneous shell.
- nsmfloat; default=0.0
non-structural mass per unit area
- z1 / z2float; default=None
fiber distance location 1/2 for stress/strain calculations z1 default : -t/2 if thickness is defined z2 default : t/2 if thickness is defined
- commentstr; default=’’
a comment for the card
-
MassPerArea_no_xref
(model, tflag=1, tscales=None)[source]¶ Calculates mass per area.
\[\]rac{m}{A} = nsm + ho t
-
MassPerArea_structure
()[source]¶ Calculates mass per area without considering non-structural mass.
\[\]rac{m}{A} = nsm + ho t
-
classmethod
add_card
(card, comment='')[source]¶ Adds a PSHELL card from
BDF.add_card(...)
- Parameters
- cardBDFCard()
a BDFCard object
- commentstr; default=’’
a comment for the card
-
cross_reference
(model: BDF) → None[source]¶ Cross links the card so referenced cards can be extracted directly
- Parameters
- modelBDF()
the BDF object
-
classmethod
export_to_hdf5
(h5_file, model, pids)[source]¶ exports the properties in a vectorized way
-
get_ABD_matrices
(theta_offset=0.0) → numpy.ndarray[source]¶ Gets the ABD matrix
- Parameters
- theta_offsetfloat
rotates the ABD matrix; measured in degrees
-
get_individual_ABD_matrices
(theta_offset: float = 0.0) → Tuple[numpy.ndarray, numpy.ndarray, numpy.ndarray][source]¶ Gets the ABD matrix
- Parameters
- theta_offsetfloat
rotates the ABD matrix; measured in degrees
- http://www2.me.rochester.edu/courses/ME204/nx_help/index.html#uid:id503291
- Understanding Classical Lamination Theory
-
get_z_locations
() → List[float][source]¶ returns the locations of the bottom and top surface of the shell
-
property
material_ids
¶ returns the material ids
-
mid2
= None¶ Material identification number for bending -1 for plane strin
-
property
mid_ref
¶ returns the material used for mass
-
nsm
= None¶ Non-structural Mass
-
pid
= None¶ Property ID
-
pname_fid_map
= {4: 't', 'T': 't', 6: 'twelveIt3', 8: 'tst'}¶
-
repr_fields
()[source]¶ Gets the fields in their simplified form
- Returns
- fieldsList[varies]
the fields that define the card
-
t
= None¶ thickness
-
tst
= None¶ Transverse shear thickness ratio, . Ratio of the shear thickness, ts/t, to the membrane thickness of the shell, t. The default value is for a homogeneous shell.
-
twelveIt3
= None¶ Scales the moment of interia of the element based on the moment of interia for a plate
..math:: I = frac{12I}{t^3} I_{plate}
-
type
= 'PSHELL'¶