beam Module

Inheritance diagram of pyNastran.bdf.cards.elements.beam
defines:
  • CBEAM
  • BEAMOR
class pyNastran.bdf.cards.elements.beam.BEAMOR(pid, is_g0, g0, x, offt='GGG', comment='')[source]

Bases: pyNastran.bdf.cards.base_card.BaseCard

1 2 3 4 5 6 7 8 9
BEAMOR PID       G0/X1 X2 X3 OFFT
BEAMOR 39       0.6 2.9 -5.87 GOG
classmethod _init_from_empty()[source]
classmethod add_card(card, comment='')[source]
raw_fields(self)[source]
type = 'BEAMOR'
write_card(self, size=8, is_double=False)[source]

Writes the card with the specified width and precision

Parameters:
size : int (default=8)

size of the field; {8, 16}

is_double : bool (default=False)

is this card double precision

Returns:
msg : str

the string representation of the card

class pyNastran.bdf.cards.elements.beam.CBEAM(eid, pid, nids, x, g0, offt='GGG', bit=None, pa=0, pb=0, wa=None, wb=None, sa=0, sb=0, comment='')[source]

Bases: pyNastran.bdf.cards.elements.bars.LineElement

1 2 3 4 5 6 7 8 9
CBEAM EID PID GA GB X1 X2 X3 OFFT/BIT
  PA PB W1A W2A W3A W1B W2B W3B
  SA SB            

or

1 2 3 4 5 6 7 8 9
CBEAM EID PID GA GB G0     OFFT/BIT
  PA PB W1A W2A W3A W1B W2B W3B
  SA SB            

offt/bit are MSC specific fields

Adds a CBEAM card

Parameters:
pid : int

property id

mid : int

material id

nids : List[int, int]

node ids; connected grid points at ends A and B

x : List[float, float, float]

Components of orientation vector, from GA, in the displacement coordinate system at GA (default), or in the basic coordinate system

g0 : int

Alternate method to supply the orientation vector using grid point G0. Direction of is from GA to G0. is then transferred to End A

offt : str; default=’GGG’

Offset vector interpretation flag None : bit is active

bit : float; default=None

Built-in twist of the cross-sectional axes about the beam axis at end B relative to end A. For beam p-elements ONLY! None : offt is active

pa / pb : int; default=0

Pin Flag at End A/B. Releases the specified DOFs

wa / wb : List[float, float, float]

Components of offset vectors from the grid points to the end points of the axis of the shear center

sa / sb : int; default=0

Scalar or grid point identification numbers for the ends A and B, respectively. The degrees-of-freedom at these points are the warping variables . SA and SB cannot be specified for beam p-elements

comment : str; default=’‘

a comment for the card

offt/bit are MSC specific fields
Area(self)[source]

returns the area of the element face

Centroid(self)[source]
G0(self)[source]

gets G0

Ga(self)[source]

gets Ga/G1

Gb(self)[source]

gets Gb/G2

Mid(self)[source]
Nodes(self)[source]
Nsm(self)[source]

Placeholder method for the non-structural mass, \(nsm\)

classmethod add_card(card, beamor=None, comment='')[source]

Adds a CBEAM card from BDF.add_card(...)

Parameters:
card : BDFCard()

a BDFCard object

beamor : BEAMOR() or None

defines the defaults

comment : str; default=’‘

a comment for the card

center_of_mass(self)[source]

the centroid formuala is way more complicated if you consider the nonstructural mass axis

center_of_mass_xform(self)[source]

A B ———- ^ ^ | wa | wb | | 1———-2

1-2 are the nodes of the bar A-B defines the axis of the shear center

^ z

+–+ | | | | | | 2—> y | +–+ | | +—–+

cross_reference(self, model)[source]

Cross links the card so referenced cards can be extracted directly

Parameters:
model : BDF()

the BDF object

classmethod export_to_hdf5(h5_file, model, eids)[source]

exports the elements in a vectorized way

get_axes(self, model)[source]

Gets the axes of a CBAR/CBEAM, while respecting the OFFT flag.

Notes

pyNastran.bdf.cards.elements.bars.rotate_v_wa_wb() for a description of the OFFT flag.

is_passed: bool out: (wa, wb, _ihat, jhat, khat)

get_axes_by_nodes(self, model, pid_ref, node1, node2, xyz1, xyz2, log)[source]

Gets the axes of a CBAR/CBEAM, while respecting the OFFT flag.

Notes

pyNastran.bdf.cards.elements.bars.rotate_v_wa_wb() for a description of the OFFT flag.

get_edge_ids(self)[source]

Return the edge IDs

get_offt_bit_defaults(self)[source]

offt doesn’t exist in NX nastran

get_x_g0_defaults(self)[source]

X and G0 compete for the same fields, so the method exists to make it easier to write the card

Returns:
x_g0 : varies

g0 : List[int, None, None] x : List[float, float, float]

Notes

Used by CBAR and CBEAM

is_bit

is the bit flag active?

is_offt

is the offt flag active?

node_ids
nodes
nodes_ref
raw_fields(self)[source]
repr_fields(self)[source]

Gets the fields in their simplified form

Returns:
fields : List[varies]

the fields that define the card

safe_cross_reference(self, model, xref_errors)[source]
type = 'CBEAM'
uncross_reference(self)[source]

Removes cross-reference links

validate(self)[source]

card checking method that should be overwritten

write_card(self, size=8, is_double=False)[source]

Writes the card with the specified width and precision

Parameters:
size : int (default=8)

size of the field; {8, 16}

is_double : bool (default=False)

is this card double precision

Returns:
msg : str

the string representation of the card

write_card_16(self, is_double=False)[source]
pyNastran.bdf.cards.elements.beam._init_offt_bit(card, unused_eid, offt_default)[source]

offt doesn’t exist in NX nastran