Plugin SeismicLab AspasiaZerva
Jump to navigation
Jump to search
| Description |
|---|
| This plugin simulates seismic ground motion according to the approach proposed by Aspasia Zerva (1992). Plugin version: 1.0 Last modified: 21/12/2024 LabRPS version: All Author: Koffi Daniel |
| Author |
| Koffi Daniel |
| Download |
| None |
| Features |
| Aspasia Zerva 1992 |
| Plugin Version |
| 1.0 |
| Date last modified |
| 21/12/2024 |
| LabRPS Version(s) |
| All |
| Default shortcut |
| None |
| See also |
| None |
Aspasia Zerva 1992
This plugin simulates seismic ground motion according to the approach proposed by Aspasia Zerva (1992).
Wittig Sinha Equal Floors
This is the only RPS feature that the plugin implements. It belongs to the simulation method group. This feature implements the seismic ground motion simulation method according to Aspasia Zerva (1992)
Feature Dependency
The features required by this feature are summarized in the following table:
- A simulation points feature
- A frequency discretization feature
- A randomness provider feature
- A modulation function(time envelop)
- A spectrum feature
Properties
- DataStandardDeviation: The standard deviation of the excitation.
- DataDominantFrequency: The dominant frequency of the earthquake excitation.
- DataDampingRatio: The bandwidth of the earthquake excitation.
- DataEnvelopValueAtNinetyPercentDuration: The value of the envelop function at 90 percent of the duration.
- DataNormalizedDurationTimeAtPeak: The normalized duration time when ground motion achieves peak.
Scripting
import LabRPS
import SeismicLab
import SeismicLabObjects
from LabRPS import Vector as vec
import time
def simulate():
# Plugin
installResuslt = SeismicLab.installPlugin("SeismicLabPlugin")
if not installResuslt:
LabRPS.Console.PrintError("The installation the SeismicLabPlugin has failed.\n")
return None
installResuslt = SeismicLab.installPlugin("AspasiaZervaPlugin")
if not installResuslt:
LabRPS.Console.PrintError("The installation the AspasiaZervaPlugin has failed.\n")
return None
# Document
doc = LabRPS.newDocument()
# Simulation
sim = SeismicLabObjects.makeSimulation(doc, "Simulation")
if not sim:
LabRPS.Console.PrintError("The simulation does not exist.\n")
return None
# Simulation points
loc = SeismicLabObjects.makeFeature("SimulationPoints", "Simulation", "Horizontal Distribution", "Location Distribution")
if not loc:
LabRPS.Console.PrintError("Error on creating the location distribution.\n")
return None
# Frequencies
frequency = SeismicLabObjects.makeFeature("Frequencies", "Simulation", "Double Index Frequency Discretization", "Frequency Distribution")
if not frequency:
LabRPS.Console.PrintError("Error on creating the frequency distribution.\n")
return None
# Spectrum
spectrum = SeismicLabObjects.makeFeature("Spectrum", "Simulation", "Clough-Penzien Spectrum", "Spectrum")
if not spectrum:
LabRPS.Console.PrintError("Error on creating the spectrum model.\n")
return None
# Spectrum decomposition
spectrumD = SeismicLabObjects.makeFeature("Envelop", "Simulation", "Bogdanoff Goldberg Bernard Modulation Function", "Modulation Function")
if not spectrumD:
LabRPS.Console.PrintError("Error on creating the modulation function.\n")
return None
# Random phase
randomness = SeismicLabObjects.makeFeature("RandomPhases", "Simulation", "Uniform Random Phases", "Randomness Provider")
if not randomness:
LabRPS.Console.PrintError("The creation of the randomness provider was not successuful.\n")
return None
# Simulation method
simMethod = SeismicLabObjects.makeFeature("SimulationMethod", "Simulation", "Aspasia Zerva 1992", "Simulation Method")
if not simMethod:
LabRPS.Console.PrintError("Error on creating the simulation method.\n")
return None
sim.Stationarity = False
# Run simulation and output the first(0) sample
# store starting time
begin = time.time()
velocities = sim.simulate(0)
# store end time
end = time.time()
LabRPS.Console.PrintMessage(f"Total runtime of the simulaltion is {end - begin} seconds\n")
if LabRPS.GuiUp:
import SeismicLabGui
import GeneralToolsGui
SeismicLabGui.setActiveSimulation(sim)
GeneralToolsGui.GeneralToolsPyTool.showArray(sim.getSimulationData().numberOfTimeIncrements, sim.getSimulationData().numberOfSpatialPosition + 1, velocities, True)
doc.recompute()
simulate()