Skip to content

Modify the projection formula, add tolerance, and add tests.#8870

Merged
joa-quim merged 1 commit intoGenericMappingTools:masterfrom
Chuan1937:psmeca-fix
Jan 23, 2026
Merged

Modify the projection formula, add tolerance, and add tests.#8870
joa-quim merged 1 commit intoGenericMappingTools:masterfrom
Chuan1937:psmeca-fix

Conversation

@Chuan1937
Copy link
Contributor

When dip=90° and rank=180°, tan(90°)×sin(180°)=Inf×0, causing an error.

Change the formula in the utilmeca_proj_radius function from atan(tand×sind) to atan2(sin×sin, cos) and add an epsilon tolerance.

Fixes #8053

Test results:
image

@joa-quim joa-quim merged commit aa19d48 into GenericMappingTools:master Jan 23, 2026
7 of 14 checks passed
@Chuan1937 Chuan1937 deleted the psmeca-fix branch January 24, 2026 11:42
@Esteban82
Copy link
Member

Esteban82 commented Jan 27, 2026

In Code Validator it says that there is an error with the script of this PR.

Following bash scripts may not have execute permission:
1: ./test/seis/psmeca_radius.sh
Error: Process completed with exit code 1.

@Esteban82 Esteban82 added the enhancement Improving an existing feature label Jan 27, 2026
@Chuan1937
Copy link
Contributor Author

In Code Validator it says that there is an error with the script of this PR.

ok,I'll change the execute permission.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Improving an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

psmeca bug, -T option

3 participants