Skip to content
This repository has been archived by the owner on Sep 7, 2024. It is now read-only.

fix: eew intensity site effect #75

Merged
merged 2 commits into from
May 9, 2024
Merged

Conversation

Fonger
Copy link
Contributor

@Fonger Fonger commented May 2, 2024

Hi,

I've noticed a potential issue in the code where the regional site effect parameters might not be incorporated into the PGA formula. This is fixed by 8a9f0ad

Currently, the parameter seems to default to 1.751.

If this observation is correct, it could potentially lead to less precise seismic response calculations for various regions.

I believe integrating specific site effect parameters for each area could enhance the accuracy of our earthquake impact assessments.

export const calculateIntensity = (
surfaceDistance: SurfaceDistanceToEpicenter,
distance: DistanceToEpicenter,
magnitude: number,
depth: number,
siteEffect: number = 1.751
) => {
const pga =
1.657 * Math.exp(1.533 * magnitude) * distance ** -1.607 * siteEffect;

There's also a small optimization: 009c666
We can use the intensity map to get local intensity without re-calculation.

@Fonger Fonger force-pushed the fix/site-effect branch from 51f1d42 to 009c666 Compare May 2, 2024 19:12
@whes1015 whes1015 enabled auto-merge May 8, 2024 09:01
@Fonger
Copy link
Contributor Author

Fonger commented May 9, 2024

@whes1015 Thanks for the review.

I see you enable auto-merge but it seems I need your approval to run the build workflow

image

@whes1015 whes1015 merged commit 28a43b1 into ExpTechTW:main May 9, 2024
3 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants