pub enum StageSpec {
Static {
id: String,
steps: u32,
integrator: IntegratorSpec,
algorithm: AlgorithmSpec,
convergence: Option<ConvergenceSpec>,
hold_patterns_after: Vec<u32>,
},
Modal {
id: String,
modes: u32,
},
Reset {
id: String,
},
Transient {
id: String,
steps: u32,
dt: f64,
damping: DampingSpec,
ground_motions: Vec<GroundMotionSpec>,
algorithm: AlgorithmSpec,
convergence: Option<ConvergenceSpec>,
},
}Variants§
Static
Modal
A single eigenvalue solve (core::modal_analysis) for the domain’s
current state — not iterative like Static/Transient, so this
stage always takes exactly one advance() step regardless of the
caller’s step budget (decode.rs’s compile_stages hardcodes
steps: 1 for it). modes is the number of lowest-frequency modes
to compute (1..=free_dof_count).
Reset
Reverts the model to its initial state (OpenSees reset): displacements, velocities and
every element/material history return to their as-built values and time to 0. Like
OpenSees, it does not undo holdPatternsAfter freezes (loadConst): a held pattern
stays applied at its frozen factor, so a later stage sees that load in full from its
first step; patterns that were not held ramp again from 0. Load patterns and their
loads stay defined. Takes no steps and records nothing.
Transient
Newmark-beta time-history analysis (core::TransientAnalysis,
fixed at the unconditionally-stable “average acceleration”
parameters — see its own doc comment). steps fixed-size dt
increments; ground_motions (zero or more) each add a uniform
inertial excitation along one axis, on top of whatever LoadPattern
reference loads are already active (e.g. a preceding Static
stage’s frozen gravity).
Fields
damping: DampingSpecground_motions: Vec<GroundMotionSpec>algorithm: AlgorithmSpecOmitted algorithms preserve the original linear Newmark solve.
convergence: Option<ConvergenceSpec>Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for StageSpec
impl<'de> Deserialize<'de> for StageSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl StructuralPartialEq for StageSpec
Source§impl Tsify for StageSpec
impl Tsify for StageSpec
const DECL: &'static str = "export type StageSpec = { kind: \"static\"; id: string; steps: number; integrator: IntegratorSpec; algorithm: AlgorithmSpec; convergence?: ConvergenceSpec; holdPatternsAfter: number[] } | { kind: \"modal\"; id: string; modes: number } | { kind: \"reset\"; id: string } | { kind: \"transient\"; id: string; steps: number; dt: number; damping: DampingSpec; groundMotions: GroundMotionSpec[]; algorithm?: AlgorithmSpec; convergence?: ConvergenceSpec };"
const SERIALIZATION_CONFIG: SerializationConfig
Source§type JsType = JsType
type JsType = JsType
#[wasm_bindgen] extern "C" { .. }.
[Ts<T>] is #[repr(transparent)] over this and passes it across the
ABI as a plain JS handle, which any other representation would break.fn into_js(&self) -> Result<Self::JsType, Error>where
Self: Serialize,
fn from_js<T>(js: T) -> Result<Self, Error>
Auto Trait Implementations§
impl Freeze for StageSpec
impl RefUnwindSafe for StageSpec
impl Send for StageSpec
impl Sync for StageSpec
impl Unpin for StageSpec
impl UnsafeUnpin for StageSpec
impl UnwindSafe for StageSpec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T, U> Imply<T> for U
impl<T> Scalar for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.