3.1. Initialisation
- imcalculator.__init__(acc, dt, damping=0.05, unit='g')[source]
Initializes the imcalculator with the input ground-motion record.
The acceleration is converted to g on input so that all downstream methods use a consistent unit system. The original unit label is stored in
self.unitfor reference.- Parameters:
acc (list or numpy.ndarray) – Acceleration time series. Units are specified by the
unitparameter.dt (float) – Time step of the accelerogram (s).
damping (float, optional) – Damping ratio (default is 0.05, i.e. 5%).
unit (str, optional) – Unit of the input acceleration. Accepted values are
"g"(default),"m/s2", or"m/s^2".
- Raises:
ValueError – If
unitis not one of the accepted strings.