Generating Fragility Curves for Seismic Risk Assessment

fragility curves combined for "Generating Fragility Curves for Seismic Risk Assessment"

In the field of performance-based earthquake engineering, fragility curves are indispensable tools. These probabilistic functions describe the likelihood that a structure or component will exceed a certain damage state when subjected to varying levels of seismic intensity—typically measured using Spectral Acceleration (Sa) or Peak Ground Acceleration (PGA).

At QuakeLogic, we help researchers, engineers, and emergency planners develop and automate fragility analysis as part of seismic resilience studies. This blog post introduces a fully open-source Python script developed by our team that reads structural response data and generates fragility curves for multiple damage states.

What Are Fragility Curves?

A fragility curve is a cumulative distribution function (CDF) that defines the conditional probability:

P(Damage ≥ State | Intensity Measure)

This means that, for a given level of shaking (e.g., 0.3g Sa), the curve tells you the probability that a structure will exceed a limit-state such as Moderate or Complete damage.

We typically use lognormal distributions to model fragility because they capture the exponential rise in damage probability with increasing shaking intensity.

Engineering Demand Parameters (EDPs) and Intensity Measures (IMs)

In seismic fragility analysis, the relationship is between:

  • EDP (Engineering Demand Parameter): A measurable response of the structure.
  • IM (Intensity Measure): A scalar value representing the strength of ground shaking.

Common EDPs:

  • Maximum interstory drift ratio (MIDR) – most widely used for buildings
  • Peak floor acceleration
  • Residual drift
  • Relative displacement
  • Roof displacement
  • Member strains or rotations (for local component fragility)

Common IMs:

  • PGA (Peak Ground Acceleration)
  • Sa(T1) – Spectral acceleration at fundamental period (T1)
  • PGV (Peak Ground Velocity)
  • Arias Intensity
  • CAV (Cumulative Absolute Velocity)

Choosing the right IM and EDP depends on the structure type, the available data, and the analysis objective.

Understanding the Fragility Curve Plot

The plot generated by the code shows the fragility curves for multiple damage states. Here’s how to read it:

  • X-axis: Intensity Measure (IM)
    In our example, this is Sa(T1) (spectral acceleration), but it can be PGA, PGV, or any other meaningful measure of shaking intensity.
  • Y-axis: Probability of Exceedance
    This is the probability that the structure’s response (EDP) will exceed the defined threshold for each damage state.

Interpretation:

A steeper curve implies a rapid transition from low to high damage probability — common for brittle systems or clearly defined performance thresholds.Methodology Overview

As the intensity of shaking (IM) increases, the probability of damage naturally increases.

Fragility curves slope upwards — from 0 to 1 — showing this increasing probability.

Robust structures have curves that shift rightward, indicating a lower probability of damage at a given IM.

  1. Input Data: Simulated or observed structural responses (e.g., drift ratios) vs. seismic intensities.
  2. Damage States: Thresholds for damage classification (e.g., 1%, 3%, 4%, 5% drift).
  3. Binning: The Sa values are grouped and used to calculate the fraction of samples exceeding each damage threshold.
  4. Curve Fitting: We fit a lognormal CDF to the exceedance probabilities using non-linear regression.
  5. Visualization: Fragility curves are plotted for each damage state.

Example Output

fragility curves combined for "Generating Fragility Curves for Seismic Risk Assessment"

Input Format (input.txt)

A simple tab-separated file with the following columns:

Sa_T1_g    MaxDrift_ratio
0.1        0.0043
0.15       0.0098
...        ...

You can download an example file here.

Python Code: Fragility Curve Generator

################################################################################
# Fragility Curve Generator for Seismic Risk Analysis
#
# This script calculates and visualizes fragility curves for structural
# components or systems based on nonlinear response data from a suite of
# ground motions.
#
# Fragility curves represent the conditional probability that a structure
# will exceed a predefined damage state for a given ground motion intensity
# measure (IM), typically spectral acceleration (Sa). These curves are
# essential tools for probabilistic seismic risk assessment and
# performance-based earthquake engineering.
#
# The script uses a lognormal cumulative distribution function (CDF) to fit
# observed probabilities of exceedance derived from drift thresholds and
# structural response data. Drift ratios are compared against damage state
# thresholds to calculate these probabilities at various IM bins.
#
# Generated by: QuakeLogic Inc.
# Contact: support@quakelogic.net
################################################################################

import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
from scipy.stats import lognorm
from scipy.optimize import curve_fit

def run():
    try:
        df = pd.read_csv("input.txt", sep='t')
    except FileNotFoundError:
        print("❌ input.txt not found. Please ensure it exists in the working directory.")
        return

    IMs = df['Sa_T1_g'].values
    EDPs = df['MaxDrift_ratio'].values

    damage_states = {
        'Slight': 0.01,
        'Moderate': 0.03,
        'Extensive': 0.04,
        'Complete': 0.05
    }

    fragility_results = {}
    unique_IMs = np.linspace(min(IMs), max(IMs), 20)
    tolerance = 0.05

    for ds, threshold in damage_states.items():
        prob_exceed = []
        for im in unique_IMs:
            edp_subset = EDPs[np.abs(IMs - im) < tolerance]
            if len(edp_subset) > 0:
                prob = np.mean(edp_subset >= threshold)
            else:
                prob = 0
            prob_exceed.append(prob)

        def lognorm_cdf(x, mu, sigma):
            return lognorm.cdf(x, s=sigma, scale=np.exp(mu))

        prob_array = np.array(prob_exceed)
        if np.all(prob_array == 0) or np.all(prob_array == 1):
            print(f"⚠️ Skipping '{ds}' — flat probability distribution (all 0s or all 1s)")
            fragility_results[ds] = (np.nan, np.nan)
            continue

        try:
            popt, _ = curve_fit(lognorm_cdf, unique_IMs, prob_exceed, p0=[np.log(np.mean(unique_IMs)), 0.5])
            mu, sigma = popt
            fragility_results[ds] = (mu, sigma)
            print(f"✔️ Fitted '{ds}': mu = {mu:.3f}, sigma = {sigma:.3f}")
        except Exception as e:
            print(f"❌ Failed to fit for '{ds}': {e}")
            fragility_results[ds] = (np.nan, np.nan)

    plt.figure(figsize=(10, 6))
    x_vals = np.linspace(min(IMs), max(IMs), 300)
    for ds, (mu, sigma) in fragility_results.items():
        if np.isnan(mu): continue
        plt.plot(x_vals, lognorm.cdf(x_vals, s=sigma, scale=np.exp(mu)), label=ds)

    plt.ylim(0, 1)
    plt.xlabel("Spectral Acceleration Sa(T1) [g]", fontsize=12)
    plt.ylabel("Probability of Exceedance", fontsize=12)
    plt.title("Seismic Fragility Curves by Damage State", fontsize=14)
    plt.grid(True, linestyle='--', alpha=0.7)
    plt.legend(title="Damage State")
    plt.tight_layout()
    plt.savefig("fragility_curves_combined.png", dpi=300)
    plt.show()
    print("📈 Fragility plot saved as 'fragility_curves_combined.png'")

if __name__ == '__main__':
    run()

Summary

This fragility analysis tool allows engineers and researchers to:

  • Automate fragility curve generation from drift or response data
  • Visualize performance thresholds for multiple damage states
  • Incorporate results into risk models or decision-making tools

Need Help?

QuakeLogic Inc. provides advanced tools and consulting for:

  • Earthquake early warning systems
  • Structural health monitoring (SHM)
  • Fragility model development
  • Shake table testing and seismic instrumentation

📧 Reach out to us anytime: support@quakelogic.net

Last reviewed: 2026-07-04

Executive Summary

Shake table testing helps engineers reproduce controlled motion so components, assemblies, models, and equipment can be evaluated under defined seismic or vibration inputs. This article is maintained as a QuakeLogic engineering resource for readers evaluating terminology, applications, instrumentation, and practical implementation considerations. The content is educational and should be reviewed against project-specific requirements, applicable standards, manufacturer documentation, and qualified engineering judgment.

Key Takeaways

  • Start with the engineering objective, operating environment, required measurements, and decision workflow.
  • Use calibrated instrumentation, documented configuration, appropriate sampling, and traceable data handling where results support engineering decisions.
  • Interpret results in context; boundary conditions, installation quality, noise, bandwidth, and site conditions can materially affect conclusions.
  • Use standards and references as guidance, not as substitutes for project-specific engineering review.

Technical Explanation

A credible engineering workflow links the physical system, the measurement chain, data acquisition, processing, interpretation, and reporting. For testing, that means documenting the input, payload, fixture, limits, safety controls, and acceptance criteria. For monitoring, that means documenting sensor type, placement, orientation, coupling, timing, communications, maintenance, alarm logic, and review procedures.

Engineering Applications

Use CasePrimary QuestionUseful Documentation
Research or educationWhat behavior can be measured, demonstrated, or repeated?Test plan, configuration notes, input data, calibration records, and observations.
Infrastructure or facility monitoringIs response normal, changing, or outside expected limits?Baseline data, event records, thresholds, inspection notes, and engineering review.
Product or system selectionWhich specifications matter for the application?Measurement range, bandwidth, accuracy, environment, integration needs, and deliverables.

People Also Ask

What information should be gathered before selecting equipment?

Define the measurement objective, expected amplitude and frequency range, installation environment, data format, timing requirements, communications, reporting needs, and applicable standards.

How can data quality be protected?

Use appropriate sensor mounting, calibration, channel naming, time synchronization, clipping checks, noise review, and documented maintenance procedures.

When is human engineering review required?

Human review is required when results affect safety, compliance, operations, procurement, structural assessment, or emergency response decisions.

Related Technologies and Resources

References

Recommended Media

Media placeholder: Add an original diagram, workflow graphic, comparison chart, product illustration, lab photograph, or installation schematic after technical review. Do not use stock imagery where readers need to inspect real equipment or engineering details.

Discuss an Application with QuakeLogic

QuakeLogic supports seismic monitoring, earthquake early warning, structural health monitoring, infrasound monitoring, vibration monitoring, data acquisition, robotics education, and shake table testing workflows. For project-specific guidance, contact QuakeLogic with the application, measurement objective, environment, and required deliverables.

🌍 Understanding P-Waves and S-Waves: Earth’s Early Earthquake Messengers

Scared employees hiding under office desks during earthquake for "Understanding the Earthquake Shaking: The Modified Mercalli Intensity Scale

When the Earth rumbles, seismic waves are the carriers of its message — rippling through the ground, shaking buildings, and providing valuable insight into the structure of our planet. Among these waves, P-waves and S-waves are the first responders. But what are they, how do they differ, and why do they matter so much in earthquake monitoring and early warning systems?

Let’s break it down.

p wave s wave for "🌍 Understanding P-Waves and S-Waves: Earth’s Early Earthquake Messengers"

🔹 What is a P-Wave?

P-wave stands for Primary wave — and true to the name, it’s the first seismic wave to arrive at a recording station after an earthquake occurs.

⚙️ Key Characteristics:

  • Type: Compressional (Longitudinal) wave
  • Motion: Particles move back and forth in the same direction as the wave travels
  • Speed: Fastest seismic wave (~5–8 km/s in the crust)
  • Medium: Travels through solids, liquids, and gases
  • Damage Potential: Generally low — it’s more of an early signal than a shaker

🎧 Analogy:

Think of how sound travels in air: the molecules compress and expand. P-waves do the same in rock — they compress and dilate the material as they pass.

🔹 What is an S-Wave?

S-wave stands for Secondary wave, because it arrives after the P-wave.

⚙️ Key Characteristics:

  • Type: Shear (Transverse) wave
  • Motion: Particles move perpendicular to the direction the wave is traveling — like side-to-side or up-and-down
  • Speed: Slower than P-waves (~3–4.5 km/s)
  • Medium: Only travels through solids — blocked by fluids like water or molten rock
  • Damage Potential: Higher shaking intensity, causes most of the ground motion we feel

🎧 Analogy:

Imagine shaking a rope up and down — the wave moves forward, but the rope oscillates vertically. That’s how S-waves move through the ground.

📊 Side-by-Side Comparison

FeatureP-WaveS-Wave
Full NamePrimary WaveSecondary Wave
TypeCompressional / LongitudinalShear / Transverse
Particle MotionBack-and-forth (in wave direction)Side-to-side or up-and-down
SpeedFastest (~5–8 km/s)Slower (~3–4.5 km/s)
MediumSolids, liquids, gasesSolids only
Arrival TimeFirstSecond
DamageMinimalSignificant shaking

🛰️ Why Are These Waves Important?

Both waves play critical roles in earthquake science and early warning systems:

  • P-waves act as an early warning signal. Systems like Taiwan’s P-Alert and algorithms like Prof. Y.M. Wu’s Pd method use the first few seconds of the P-wave to estimate earthquake magnitude and issue warnings before the damaging S-wave arrives.
  • S-waves are typically responsible for the actual shaking people feel and the structural damage during an earthquake.

With each second of early warning, we gain the opportunity to save lives, pause critical infrastructure, and reduce casualties.

📉 How Do They Look on a Seismogram?

On a typical seismogram:

  • P-waves appear as small, fast, high-frequency wiggles.
  • S-waves follow with larger amplitude and lower frequency, marking the start of strong shaking.

🔚 Final Thoughts

Understanding P-waves and S-waves isn’t just a scientific curiosity — it’s the foundation of modern earthquake early warning (EEW) systems. These waves help us detect earthquakes in real time, reduce risk, and save lives before the most damaging ground motions arrive.

If you’re looking for a reliable and cost-effective solution, we highly recommend the P-Alert sensor. Engineered for rapid P-wave detection and early warning, P-Alert offers real-time alerts, easy deployment, and proven performance in high-seismic-risk regions like Taiwan and beyond.

Protect your people and infrastructure — choose P-Alert.

palert 2 for "🌍 Understanding P-Waves and S-Waves: Earth’s Early Earthquake Messengers"

Last reviewed: 2026-07-04

Executive Summary

Earthquake early warning combines rapid detection, local or regional algorithms, alert logic, and response procedures before strong shaking reaches a site. This article has been expanded as an engineering resource for readers evaluating earthquake early warning concepts, instrumentation choices, and monitoring workflows. The discussion is educational and should be paired with project-specific review by qualified engineers, applicable codes, owner requirements, and equipment documentation.

Key Takeaways

  • Define the engineering objective before selecting sensors, test equipment, trigger thresholds, or reporting workflows.
  • Use calibrated instrumentation, documented installation practices, time synchronization, and traceable data handling where measurement quality matters.
  • Interpret measured data in context: site conditions, structure type, noise environment, sampling rate, bandwidth, and boundary conditions all affect conclusions.
  • Use authoritative references and project-specific criteria rather than relying on generic thresholds or unsupported performance claims.

Technical Explanation

In practical earthquake early warning work, the engineering system is more than a sensor or a test platform. A credible workflow includes the measurement objective, instrument selection, mounting or boundary conditions, sampling and timing strategy, data validation, event or response detection, engineering review, and reporting. Weakness in any part of that chain can reduce confidence in the final interpretation.

For monitoring applications, engineers should document sensor orientation, coupling, environmental exposure, dynamic range, frequency bandwidth, data logger configuration, clock synchronization, communications, and maintenance procedures. For testing applications, engineers should document input motion, fixture design, payload properties, control limits, safety interlocks, acceptance criteria, and post-test data review.

Engineering Applications

ApplicationEngineering QuestionTypical Evidence Needed
Research and educationHow does a structure, component, or sensor respond under controlled conditions?Test plan, calibrated data, input motion, boundary conditions, and repeatable observations.
Critical infrastructureIs the asset response normal, changing, or potentially unsafe after an event?Baseline data, event records, thresholds, inspection workflow, and engineering sign-off.
Industrial facilitiesCan monitoring support operational continuity and response decisions?Site-specific criteria, reliable telemetry, alarm logic, maintenance records, and documented procedures.

People Also Ask

What should be specified before buying equipment?

Specify the measurement objective, frequency range, amplitude range, environment, data format, timing needs, installation constraints, reporting requirements, and applicable standards or owner criteria.

Why do references and standards matter?

They provide terminology, acceptance criteria, test methods, and documentation expectations. They do not replace engineering judgment, but they reduce ambiguity and make results easier to review.

How should data quality be checked?

Review calibration status, timing, clipping, sensor orientation, signal-to-noise ratio, environmental artifacts, data completeness, and whether the record supports the engineering decision being made.

Related QuakeLogic Resources

References

Recommended Diagram or Download

Media placeholder: Add an original diagram showing the measurement chain from sensor or test platform to data acquisition, analysis, engineering interpretation, and reporting. Where this article becomes a buyer guide or application note, create a downloadable PDF version after engineering review.

Discuss a Monitoring or Testing Application

QuakeLogic supports seismic monitoring, earthquake early warning, structural health monitoring, infrasound monitoring, vibration monitoring, data acquisition, and shake table testing applications. For project-specific guidance, contact QuakeLogic with the asset type, measurement objective, site constraints, and required deliverables.

Tired of Low-Frequency Noise Harassment? QuakeLogic Has the Solution

AdobeStock Photoroom for "Tired of Low-Frequency Noise Harassment? QuakeLogic Has the Solution"

If you’ve ever been bothered by a deep, persistent rumble in your home—something you feel more than hear—you’re not alone.

Across the country, families are reporting a disturbing rise in low-frequency noise harassment, often caused intentionally by neighbors using subwoofers, industrial equipment, or other infrasound sources. The effects can be both physical and psychological: headaches, stress, loss of sleep, and a deep sense of unease in your own space.

This isn’t just a nuisance. It’s harassment. And it’s hard to prove—until now.


Why Low-Frequency Noise Is Dangerous to Your Health

Infrasound (low-frequency sound below 20 Hz) is often imperceptible to the human ear—but your body still feels it, and the long-term exposure can have serious consequences:

🧠 Headaches & Migraines – Constant infrasound exposure can trigger tension and pain, even when you’re unaware of the source.
🛌 Sleep Disturbance & Fatigue – These low-frequency vibrations can disrupt deep sleep cycles, leaving you exhausted, irritable, and less focused.
💓 Increased Stress & Anxiety – The body interprets infrasound as a warning signal, activating your stress response and leading to chronic anxiety.
🎯 Cognitive Impairment – Extended exposure has been linked to reduced concentration, memory issues, and mental fog.
🩺 Cardiovascular Strain – Some studies suggest that long-term infrasound exposure can increase blood pressure and heart rate.

This is more than an annoyance—it’s a silent health threat. If you’re experiencing symptoms without a clear cause, infrasound may be the hidden culprit.


The Power of Infrasound Detection at Your Fingertips

At QuakeLogic, we believe everyone has the right to peace in their own home. That’s why we proudly offer the Raspberry Boom Seismo-Acoustic Monitor, a powerful, affordable tool designed to detect and pinpoint infrasound disturbances.

Our infrasound sensor is built with advanced technology capable of detecting low-frequency sound waves that conventional microphones can’t capture. These invisible sound waves can penetrate walls, travel long distances, and cause real harm—but Raspberry Boom gives you the power to fight back.

With it, you can:

Detect and log infrasound events in real-time
Identify patterns and timing of the harassment
Pinpoint the source with location tracking when used in a small sensor network
Create compelling evidence for police reports or legal action
Reclaim peace in your home and protect your loved ones


Why QuakeLogic AIR Is the Best Choice

  • Plug & Play Simplicity – No technical background? No problem. QuakeLogic AIR comes with free, user-friendly software to get you started immediately.
  • Live Monitoring and History Logs – Stay aware of what’s happening and when.
  • Affordable Protection – Priced with families in mind, this powerful tool is available right now on our website.

A Smart Investment in Peace of Mind

Low-frequency noise harassment is real, and it’s affecting more people every day. Whether you suspect a neighbor is deliberately targeting you, or you’re just unsure of what’s causing that strange vibration in your home, QuakeLogic AIR Infrasonic sensor gives you the power to know, prove, and act.

Why QuakeLogic?

At QuakeLogic, we specialize in advanced monitoring solutions for seismic, vibration, and acoustic. Our AIR Infrasound Monitor represents the cutting edge of noise harassment detection—bridging the gap between traditional sound level meters and intelligent, cloud-connected monitoring systems.

Conclusion

Noise harassment is more than an inconvenience—it’s a public health issue. With the right tools, individuals, communities, and organizations can detect, document, and resolve noise disputes effectively. QuakeLogic’s AIR Infrasound Monitor transforms subjective complaints into actionable evidence, empowering a healthier, quieter future.

Take control of your environment today. Explore the AIR Infrasound Monitor and empower your community with the evidence needed to ensure a healthier, quieter future.

🛒 Buy now and protect your peace:

🔒 Protect your family.
🧘‍♀️ Regain your peace.
⚖️ Build your case with real, scientific data.

Seeing (and hearing) is believing. Don’t let invisible noise take over your life—let QuakeLogic help you fight back.


Last reviewed: 2026-07-04

Executive Summary

Infrasound monitoring measures low-frequency acoustic energy below the common audible range and is used for environmental, industrial, defense, and research applications. This article has been expanded as an engineering resource for readers evaluating infrasound monitoring concepts, instrumentation choices, and monitoring workflows. The discussion is educational and should be paired with project-specific review by qualified engineers, applicable codes, owner requirements, and equipment documentation.

Key Takeaways

  • Define the engineering objective before selecting sensors, test equipment, trigger thresholds, or reporting workflows.
  • Use calibrated instrumentation, documented installation practices, time synchronization, and traceable data handling where measurement quality matters.
  • Interpret measured data in context: site conditions, structure type, noise environment, sampling rate, bandwidth, and boundary conditions all affect conclusions.
  • Use authoritative references and project-specific criteria rather than relying on generic thresholds or unsupported performance claims.

Technical Explanation

In practical infrasound monitoring work, the engineering system is more than a sensor or a test platform. A credible workflow includes the measurement objective, instrument selection, mounting or boundary conditions, sampling and timing strategy, data validation, event or response detection, engineering review, and reporting. Weakness in any part of that chain can reduce confidence in the final interpretation.

For monitoring applications, engineers should document sensor orientation, coupling, environmental exposure, dynamic range, frequency bandwidth, data logger configuration, clock synchronization, communications, and maintenance procedures. For testing applications, engineers should document input motion, fixture design, payload properties, control limits, safety interlocks, acceptance criteria, and post-test data review.

Engineering Applications

ApplicationEngineering QuestionTypical Evidence Needed
Research and educationHow does a structure, component, or sensor respond under controlled conditions?Test plan, calibrated data, input motion, boundary conditions, and repeatable observations.
Critical infrastructureIs the asset response normal, changing, or potentially unsafe after an event?Baseline data, event records, thresholds, inspection workflow, and engineering sign-off.
Industrial facilitiesCan monitoring support operational continuity and response decisions?Site-specific criteria, reliable telemetry, alarm logic, maintenance records, and documented procedures.

People Also Ask

What should be specified before buying equipment?

Specify the measurement objective, frequency range, amplitude range, environment, data format, timing needs, installation constraints, reporting requirements, and applicable standards or owner criteria.

Why do references and standards matter?

They provide terminology, acceptance criteria, test methods, and documentation expectations. They do not replace engineering judgment, but they reduce ambiguity and make results easier to review.

How should data quality be checked?

Review calibration status, timing, clipping, sensor orientation, signal-to-noise ratio, environmental artifacts, data completeness, and whether the record supports the engineering decision being made.

Related QuakeLogic Resources

References

Recommended Diagram or Download

Media placeholder: Add an original diagram showing the measurement chain from sensor or test platform to data acquisition, analysis, engineering interpretation, and reporting. Where this article becomes a buyer guide or application note, create a downloadable PDF version after engineering review.

Discuss a Monitoring or Testing Application

QuakeLogic supports seismic monitoring, earthquake early warning, structural health monitoring, infrasound monitoring, vibration monitoring, data acquisition, and shake table testing applications. For project-specific guidance, contact QuakeLogic with the asset type, measurement objective, site constraints, and required deliverables.