CrossSectionalData¶
- class CrossSectionalData(dll: SofDll)¶
Bases:
objectThis class provides abstractions to load and access information about the cross-sectional values, contained in keys
9/PROP:0(total section) of the CDB file. Refer to SOFiHELP - CDBase for further information on this key.Data are stored in a
pandas.DataFramehaving the following columns:ID: property numberMNO: material ID of the sectionA: cross-sectional gross area [m2]AY: shear area Y [m2]AZ: shear area Z [m2]IT: torsional moment of inertia [m2]IY: moment of inertia YY [m4]IZ: moment of inertia ZZ [m4]EM: elastic modulus [kNm-2]GM: shear modulus [kNm-2]SW: nominal weight of the material [kNm-3]
The
DataFrameuses a MultiIndex with levelIDto enable fast lookups via thegetmethod. The index column is not dropped from theDataFrame.Note
Not all available quantities are retrieved and stored. In particular:
MRF: material ID of the reinforcementIYZ: moment of inertia Y-ZYS: coordinate of elastic centroidZS: coordinate of elastic centroidYSC: coordinate of shear centreZSC: coordinate of shear centre
are currently not included.
This is a deliberate design choice and may be changed in the future without breaking the existing API.
- get(section_id: int, quantity: str, default: float | int | None = None) float | int¶
Retrieve the requested nodal load.
- Parameters:
- Returns:
value – The requested value if found. If not found, returns
defaultwhen it is not None.- Return type:
- Raises:
LookupError – If the requested data is not found and
defaultis None.
- get_data(deep: bool = True) DataFrame¶
Return the
pandas.DataFramecontaining all the loaded properties.- Parameters:
deep (bool, default True) – When
deep=True, a new object will be created with a copy of the calling object’s data and indices. Modifications to the data or indices of the copy will not be reflected in the original object (refer topandas.DataFrame.copy()documentation for details).