Skip to content

Pattern

Pattern

Pattern(pattern_type: str)

Bases: ABC

Abstract base class for OpenSees load/excitation patterns.

Pattern instances do not self-register. A :class:PatternManager owns tag assignment and lifecycle operations for a local model context.

Parameters:

Name Type Description Default
pattern_type str

OpenSees pattern type name, such as Plain, UniformExcitation, or MultipleSupport.

required

Attributes:

Name Type Description
tag Optional[int]

Manager-assigned OpenSees load-pattern tag. It remains None until the instance is added to a manager.

pattern_type

OpenSees pattern type name used by concrete classes.

Attributes

tag instance-attribute

tag: Optional[int] = None

_owner instance-attribute

_owner: object | None = None

pattern_type instance-attribute

pattern_type = pattern_type

Methods:

_require_tag

_require_tag() -> int

Return the assigned tag or fail if the instance is unmanaged.

Returns:

Type Description
int

The manager-assigned integer tag.

Raises:

Type Description
ValueError

If this pattern has not been added to a manager.

to_tcl abstractmethod

to_tcl() -> str

Render the OpenSees pattern command.

Returns:

Type Description
str

TCL command string or TCL block for this pattern.