SteelConcentricallyBracedFrame3D
SteelConcentricallyBracedFrame3D
SteelConcentricallyBracedFrame3D(name_prefix: str = 'steel_concentrically_braced_frame_3d', num_stories: int = 5, x_bays: Optional[Sequence[float]] = None, y_bays: Optional[Sequence[float]] = None, story_heights: Optional[Sequence[float]] = None, floor_masses: Optional[Sequence[float]] = None, brace_bays_x: Optional[Dict[str, Sequence[int]]] = None, brace_bays_y: Optional[Dict[str, Sequence[int]]] = None, brace_pattern: str = 'x', brace_area_scale: float = 1.0, target_period: Optional[float] = None, column_sections: Optional[Union[str, Sequence[str], Dict[Tuple[int, int, int], str]]] = None, beam_sections: Optional[Union[str, Sequence[str], Dict[Tuple[int, str, int, int], str]]] = None, brace_sections: Optional[Union[str, Sequence[str], Dict[Tuple[str, int, int], str]]] = None, n_ele_col: int = 1, n_ele_beam: int = 1, length_unit_system: str = 'm', origin: Tuple[float, float, float] = (0.0, 0.0, 0.0), opensees_exe: Optional[str] = None, member_formulation: str = 'force_based', integration_points: int = 5, geometric_transformation: str = 'Linear', section_factory: Optional[Callable] = None, member_options: Optional[Dict[str, dict]] = None, flange_fibers: Tuple[int, int] = (12, 4), web_fibers: Tuple[int, int] = (4, 16), element_max_iterations: int = 10, element_tolerance: float = 1e-12, brace_properties: Optional[Dict[str, float]] = None)
Bases: Building
Create a rectangular 3D steel frame with perimeter axial braces.
Columns occupy every plan-grid intersection; beams connect adjacent grid points at each elevated floor. Story heights and X/Y bay widths control geometry independently. Members have six DOFs per node. The defaults are five stories, three 8 m bays in each direction, W14X90 columns, W18X35 beams, and HSS8X8X3/8 X braces in the middle perimeter bays.
Note
Floors and supports. Supplied floor masses are concentrated at
auxiliary nodes at the rectangular plan's geometric center. The center
is not calculated from member masses. No slab or shell elements are
generated. Call create_rigid_diaphragms() after assembly to connect
floor translations and in-plane rotation. Fixed-base constraints are
also explicit: call apply_fixed_base() for a standalone building,
or connect the base to a foundation in a soil-structure model.
Material-driven fiber workflow. Pass a managed uniaxial material,
G, and material_density to build(). Beams/columns automatically use
fiber sections with force-based or displacement-based elements;
braces use the same material axially.
Uniaxial Elastic stays elastic, while Steel01 can yield. AISC supplies
section geometry and J; user G supplies elastic torsion GJ. Density
supplies translational mass and rotational inertia independently of
the constitutive law. No nD reference material or initial-tangent
extraction is required. This model does not include brace buckling,
local plate buckling, fracture, or fatigue.
Select member_formulation="displacement_based" to use displacement-based members.
Local axes. Local x follows the member. AISC strong-axis Ix maps
to local Iy; AISC weak-axis Iy maps to local Iz. Fiber depth
follows local z. Both beam directions have strong-axis vertical bending.
Column_X members are strong under global X loading; Column_Y
members are strong under global Y loading. Columns on the front/back
grid lines use Column_X; remaining columns use Column_Y.
Units and loads. All inputs must use one consistent unit system.
length_unit_system converts AISC geometry only, not materials,
masses, or loads. With m, kN, tonne, s, steel E is about 200e6 and
yield stress about 345000. Floor gravity loads and member inertia
are separate: create_gravity_pattern() loads supplied floor masses;
material_density in build() adds member self-mass, not self-weight.
Examples:
Build and assemble a fixed-base elastic building:
from femora import Model
from femora.tools.buildings import SteelConcentricallyBracedFrame3D
model = Model()
elastic = model.material.uniaxial.elastic(user_name="steel", E=200e6)
frame = SteelConcentricallyBracedFrame3D(
num_stories=3, x_bays=[6.0, 6.0], y_bays=[8.0, 8.0],
story_heights=[4.0, 3.5, 3.5], floor_masses=[180, 180, 150],
column_sections=["W14X90", "W14X90", "W14X68"],
)
frame.build(model, material=elastic, G=76.923e6, material_density=7.85)
model.assembler.create_section(
meshparts=[frame.name_prefix], num_partitions=1,
partition_algorithm="kd-tree",
)
model.assembler.assemble(merge_points=True)
frame.apply_fixed_base(model)
frame.create_rigid_diaphragms(model)
gravity = frame.create_gravity_pattern(model, g=9.81)
model.process.add_step(gravity, "Apply floor gravity")
# Add a static analysis step to equilibrate gravity before lateral loading.
Use Steel01 in the same fiber workflow. Override a category's material, shear modulus, or density without changing other members:
model = Model()
steel = model.material.uniaxial.steel01(
user_name="steel", Fy=150000, E0=200e6, b=0.01,
)
elastic_beams = model.material.uniaxial.elastic(user_name="beams", E=200e6)
frame = SteelConcentricallyBracedFrame3D(
floor_masses=[250, 250, 250, 250, 200],
member_options={
"Beam_X": {"material": elastic_beams, "G": 76.923e6, "material_density": 7.85},
"Brace": {"material_density": 7.85},
},
)
frame.build(model, material=steel, G=76.923e6, material_density=7.85)
Supply custom sections without changing the building layout. A factory receives keyword arguments and must return a section managed by the supplied model. It takes precedence over automatic AISC generation:
from femora.tools.sections import aisc
def custom_section(*, model, section_name, material, category, unit_system):
return aisc.create_section(
section_name, model, material, type="Fiber", GJ=76.923e6 * aisc.get_section_properties(section_name, unit_system)["J"],
unit_system=unit_system, user_name=f"{category}_{section_name}",
)
frame = SteelConcentricallyBracedFrame3D(
member_formulation="force_based", section_factory=custom_section,
)
Create the braced-frame archetype definition.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name_prefix
|
str
|
Mesh part and recorder name prefix. |
'steel_concentrically_braced_frame_3d'
|
num_stories
|
int
|
Number of stories. Defaults to |
5
|
x_bays
|
Optional[Sequence[float]]
|
X-direction bay widths. Defaults to three 8 m bays. |
None
|
y_bays
|
Optional[Sequence[float]]
|
Y-direction bay widths. Defaults to three 8 m bays. |
None
|
story_heights
|
Optional[Sequence[float]]
|
Story heights. Defaults to |
None
|
floor_masses
|
Optional[Sequence[float]]
|
Masses (not weights) at floor COM nodes, ordered
bottom to top. Defaults to |
None
|
brace_bays_x
|
Optional[Dict[str, Sequence[int]]]
|
Braced X-bay indices on |
None
|
brace_bays_y
|
Optional[Dict[str, Sequence[int]]]
|
Braced Y-bay indices on |
None
|
brace_pattern
|
str
|
|
'x'
|
brace_area_scale
|
float
|
Multiplier applied to brace area and inertias, including custom brace_properties. |
1.0
|
target_period
|
Optional[float]
|
Optional calibration target. Defaults to |
None
|
column_sections
|
Optional[Union[str, Sequence[str], Dict[Tuple[int, int, int], str]]]
|
AISC name for all columns, a bottom-to-top list
(last entry repeats), or mapping |
None
|
beam_sections
|
Optional[Union[str, Sequence[str], Dict[Tuple[int, str, int, int], str]]]
|
AISC name, bottom-to-top list, or mapping
|
None
|
brace_sections
|
Optional[Union[str, Sequence[str], Dict[Tuple[str, int, int], str]]]
|
AISC name, bottom-to-top list, or mapping
|
None
|
n_ele_col
|
int
|
Number of elements per column member. |
1
|
n_ele_beam
|
int
|
Number of elements per beam member. |
1
|
length_unit_system
|
str
|
Unit system passed to AISC section creation. |
'm'
|
origin
|
Tuple[float, float, float]
|
Building origin. |
(0.0, 0.0, 0.0)
|
opensees_exe
|
Optional[str]
|
Optional OpenSees executable path for validation. |
None
|
member_formulation
|
str
|
|
'force_based'
|
integration_points
|
int
|
Integer 2-10; default 5. Number of Lobatto section evaluation points per force-based element, including its ends. These are not mesh nodes or cross-section fibers. |
5
|
geometric_transformation
|
str
|
|
'Linear'
|
section_factory
|
Optional[Callable]
|
Optional callable receiving |
None
|
member_options
|
Optional[Dict[str, dict]]
|
Overrides keyed by |
None
|
flange_fibers
|
Tuple[int, int]
|
|
(12, 4)
|
web_fibers
|
Tuple[int, int]
|
|
(4, 16)
|
element_max_iterations
|
int
|
Default 10. Internal force-based compatibility iterations, separate from the global analysis iteration limit. |
10
|
element_tolerance
|
float
|
Default |
1e-12
|
brace_properties
|
Optional[Dict[str, float]]
|
Optional shared custom brace geometry with exactly
|
None
|
Raises:
| Type | Description |
|---|---|
ValueError
|
Story data, brace layout, member categories, or modeling options are invalid or a fiber/element combination is unsupported. |
Note
The constructor defines a building; it does not build, assemble,
apply supports, run gravity, or launch OpenSees. target_period
stores a calibration target; it does not automatically tune stiffness.
Use n_ele_col/n_ele_beam to subdivide members, fiber counts to
refine cross-sections, and integration_points to sample along
each force-based element. These are three independent controls.
Attributes
Methods:
build
build(model, material: Material, material_density: float = 0.0, *, G: Optional[float] = None) -> CompositeMesh
Create members and floor-mass nodes as a registered mesh part.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Femora model receiving materials, sections, transformations, element definitions, and the named building mesh part. |
required |
material
|
Material
|
Managed uniaxial material for the fiber workflow. Elastic gives elastic fibers; Steel01 or another compatible uniaxial law gives nonlinear fibers. No separate E or initial tangent is required. nD materials are not accepted. |
required |
material_density
|
float
|
Mass density for additional member translational and rotational inertia. Defaults to zero. This is separate from floor masses and does not create member gravity loads. |
0.0
|
G
|
Optional[float]
|
Positive shear modulus for the uniaxial workflow. Torsional stiffness is G times the AISC-tabulated J. G is not inferred from the uniaxial material. Category overrides may supply G. |
None
|
Returns:
| Type | Description |
|---|---|
CompositeMesh
|
CompositeMesh registered under |
CompositeMesh
|
part with |
Raises:
| Type | Description |
|---|---|
ValueError
|
AISC sections cannot be resolved, a custom section belongs to another model, or fiber/brace materials are invalid. |
Note
Call this before assembly. Supports, diaphragms, patterns, recorders, and analysis steps are separate API calls. Built-in fibers use rectangular flange/web or HSS-wall patches with elastic torsion; rolled fillets and rounded corners are not included. In the uniaxial workflow, member masses and rotational inertias use AISC area/inertias, including nonlinear axial braces. Density overrides apply per category. Fiber stiffness follows the actual fiber geometry, which can differ slightly from tabulated geometry.
get_coordinates
Return X, Y, and Z coordinate arrays for grid and floor elevations.
apply_fixed_base
Fix all base structural grid nodes for fixed-base period checks.
create_rigid_diaphragms
Connect each floor's structural grid nodes to its auxiliary mass node.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Assembled model containing this building. |
required |
verbose
|
bool
|
Print a floor-by-floor constraint summary; default True. |
True
|
Raises:
| Type | Description |
|---|---|
ValueError
|
The building mesh has not been assembled. |
Note
Constraints act in the global XY plane. The auxiliary mass node retains Ux, Uy, Rz; its Uz, Rx, Ry are fixed. Structural floor joints retain their own vertical displacement and bending rotations. This creates in-plane rigid floor behavior, not a slab mesh. Use a compatible analysis constraint handler, such as Transformation. Call before creating a pushover pattern at the floor mass nodes.
create_gravity_pattern
Create downward floor loads using the nonnegative gravity magnitude g.
Pass g=9.81 for gravity in m/s2. The negative Z sign is applied
internally. Negative or nonfinite values raise ValueError.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Assembled Femora model containing the building. |
required |
g
|
float
|
Finite nonnegative acceleration magnitude. Zero is permitted. |
required |
Returns:
| Type | Description |
|---|---|
Pattern
|
Managed Plain pattern with a constant time series. Each supplied |
Pattern
|
floor weight is shared equally among its structural plan-grid nodes. |
Pattern
|
The pattern is not automatically added to the process. |
Raises:
| Type | Description |
|---|---|
ValueError
|
g is negative/nonfinite or the mesh is not assembled. |
Note
These loads use floor_masses only. Member self-mass added during
build is not automatically converted to additional weight. Run a
static analysis after adding this pattern; hold gravity with
model.actions.load_const() before starting a conventional pushover.
create_pushover_pattern
create_pushover_pattern(model, *, time_series: TimeSeries, base_shear: float, direction: Union[str, float] = 'x', distribution: Union[str, Sequence[float]] = 'mass_height', mode_shape: Optional[Sequence[float]] = None, eccentricity: Tuple[float, float] = (0.0, 0.0)) -> Pattern
Create reference horizontal loads at this frame's floor mass nodes.
Assemble the model and call create_rigid_diaphragms() first. Each
floor resultant acts at the auxiliary node at the rectangular plan's
geometric center, where the supplied floor mass is concentrated.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Assembled Femora model containing this building. |
required |
time_series
|
TimeSeries
|
Mandatory time series managed by this model. Use a linear series for conventional displacement-controlled pushover. A constant series does not supply an adjustable load factor. |
required |
base_shear
|
float
|
Positive reference total horizontal force, in the model's force units, before time-series scaling. |
required |
direction
|
Union[str, float]
|
|
'x'
|
distribution
|
Union[str, Sequence[float]]
|
|
'mass_height'
|
mode_shape
|
Optional[Sequence[float]]
|
For |
None
|
eccentricity
|
Tuple[float, float]
|
Global |
(0.0, 0.0)
|
Returns:
| Type | Description |
|---|---|
Pattern
|
Managed Plain load pattern with six-component nodal loads. Add it |
Pattern
|
to |
Pattern
|
sum to |
Pattern
|
factor; this is a net signed resultant for modal distributions. |
Raises:
| Type | Description |
|---|---|
ValueError
|
Inputs are invalid, floor nodes are missing or ambiguous, or rigid diaphragms have not been created. |
get_modes
get_modes(num_modes: int, *, material: Optional[Union[Dict[str, object], Callable]] = None, material_density: Optional[float] = None, opensees_exe: Optional[str] = None, print_results: bool = False, plot: bool = False, plot_scale: Optional[float] = None, G: Optional[float] = None) -> Dict[str, np.ndarray]
Return modal frequencies, periods, and eigenvectors.
This method builds a copy of the braced frame in a separate temporary
Model instance, applies fixed-base and rigid-diaphragm constraints,
runs OpenSees from a temporary Tcl script, and parses modal data from
OpenSees output.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
num_modes
|
int
|
Number of eigen modes to request from OpenSees. |
required |
material
|
Optional[Union[Dict[str, object], Callable]]
|
Material definition for the isolated modal model. Use
|
None
|
material_density
|
Optional[float]
|
Density used by |
None
|
opensees_exe
|
Optional[str]
|
Optional OpenSees executable path. If omitted, the
|
None
|
print_results
|
bool
|
If |
False
|
plot
|
bool
|
If |
False
|
plot_scale
|
Optional[float]
|
Optional deformation scale for plotting. If omitted, a scale is estimated from the mesh size and eigenvector magnitudes. |
None
|
G
|
Optional[float]
|
Shear modulus for modal builds using a uniaxial material. Supply
a material dictionary such as |
None
|
Returns:
| Type | Description |
|---|---|
Dict[str, ndarray]
|
Dictionary with |
Dict[str, ndarray]
|
|
Dict[str, ndarray]
|
returned node-tag order. The eigenvector array has shape |
Dict[str, ndarray]
|
|
Dict[str, ndarray]
|
|
Dict[str, ndarray]
|
COM markers, to distinguish coincident structural and mass nodes. |
Material ownership
get_modes() builds a separate temporary Model() so modal
analysis cannot accidentally mutate the user's active model. For
that reason, do not pass a Material object from another model.
Use a material dictionary or a callable factory so the material is
created inside the temporary modal model with the correct managers
and tags.
Returned modes describe the tangent state reached by this method's gravity setup, not an assumed amplitude-independent mode of a yielding structure.
Examples:
Use the same fiber workflow for elastic modes:
get_recorders
get_recorders(model, *, file_name: Optional[str] = None, delta_t: Optional[float] = None, element_responses: Optional[List[str]] = None, node_responses: Optional[List[str]] = None, whole_model: bool = False, acceleration_basis: str = 'unspecified', abscissa: str = 'time_s')
Return one managed VTKHDF recorder, never a list or fallback recorder.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Model containing the assembled building. |
required |
file_name
|
Optional[str]
|
Output base name; defaults to the building name plus .vtkhdf extension. VTKHDF adds the MPI rank to the name. |
None
|
delta_t
|
Optional[float]
|
Optional recording interval; None records every step. |
None
|
element_responses
|
Optional[List[str]]
|
VTKHDF defaults to |
None
|
node_responses
|
Optional[List[str]]
|
Defaults to displacement, velocity, acceleration.
VTKHDF accepts these names or |
None
|
whole_model
|
bool
|
False filters by this building's region. True records the entire domain. Use True in standalone examples to retain auxiliary floor-mass nodes that are not connected to a VTK-supported structural element. Do not use whole-model scope unintentionally for large soil-structure models. |
False
|
acceleration_basis
|
str
|
|
'unspecified'
|
abscissa
|
str
|
Index label, normally |
'time_s'
|
Returns:
| Type | Description |
|---|---|
|
One managed VTKHDF recorder. Add it to |
|
|
the analysis; creating them does not start recording. |
Raises:
| Type | Description |
|---|---|
ValueError
|
Model is not assembled, the building is missing, acceleration basis is unknown, or responses are unsupported. |
Note
force3D uses global element-end forces; localForce3D uses
element-local forces. Each stores 12 components: Fx, Fy, Fz, Mx,
My, Mz at end i followed by the same at end j. Truss moments are
zero. Unsupported element responses may also be written as zeros;
zero output does not prove an element implements that response.
Force fields require an OpenSees binary with VTKHDF force support;
inspect the resulting CellData fields, not just the exported command.
Fiber strains/stresses require separate section/fiber recorders:
continuum stress3D6/strain3D6 are not beam-fiber output.
get_results
Open BuildingResults using this live building's explicit membership.
model defaults to the model used by build(), which must still be
alive and assembled. This call creates no metadata files. For a separate
Python session, use BuildingResults.open(source, metadata=path)
with an explicitly exported structural index instead.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
source
|
str | Path | list
|
VTKHDF filename, glob, or partition paths. |
required |
model
|
Model | None
|
Optional explicit assembled model. |
None
|
units
|
dict | None
|
Unit labels; values are not converted. |
None
|
acceleration_basis
|
str | None
|
Recorded acceleration convention. |
None
|
abscissa
|
str | None
|
Recorded time/load-factor index label. |
None
|
Returns:
| Name | Type | Description |
|---|---|---|
BuildingResults |
A lazy structure-specific wrapper around ResultSet. Close it explicitly or use a context manager. |
export_metadata
Explicitly export a compressed HDF5 structural index, not a Python model.
Call after assembly. Stores physical members, actual tags, floor joints,
unique section/material descriptions, local transformations, and units.
No histories are stored. export_to_tcl() never calls this method.
Supply units such as dict(length="m", force="kN", moment="kN*m",
acceleration="m/s^2"); force units cannot be inferred from geometry.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
Model
|
Assembled model containing this building. |
required |
path
|
str | Path
|
Explicit output HDF5 filename; overwritten if present. |
required |
units
|
dict | None
|
Unit labels, without any numerical conversion. |
None
|
acceleration_basis
|
str | None
|
Relative/absolute/unspecified; defaults to the basis supplied to get_recorders(). |
None
|
abscissa
|
str | None
|
Table index name, e.g. time_s or load_factor. |
None
|
view_story
Print or plot a story layout with braced bay locations.
estimate_fixed_base_period
estimate_fixed_base_period(model, opensees_exe: Optional[str] = None, num_modes: int = 6, work_dir: Optional[Union[str, Path]] = None) -> Dict[str, object]
Run a fixed-base OpenSees eigen check and return periods/mode types.
calibrate_to_target_period
calibrate_to_target_period(model, target_period: Optional[float] = None, direction: str = 'x', tolerance: float = 0.1, max_iterations: int = 8, opensees_exe: Optional[str] = None) -> Dict[str, object]
Scale brace geometry toward a fixed-base period target.
Use an Elastic uniaxial material for period calibration. This changes axial stiffness while holding the already assembled nodal masses fixed; it is not a nonlinear capacity calibration.