Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warn for prism gravity tensor on singular points #401

Closed
wants to merge 19 commits into from

Conversation

santisoler
Copy link
Member

Check if the gravity tensor components of a prism are being computed at any singular point. Choclo will return a np.nan on those points, but it's worth warning the user about it before they get the results. Add tests that check if the warnings are being raised on those cases.

Relevant issues/PRs:

Merge after #400 is merged.

Await until fatiando/choclo#30 is merged and released.

Add Choclo as a required dependency of Harmonica and replace the current
kernels for prisms gravity with the ones in Choclo.
Allow the `prism_gravity` function to compute the easting and northing
components of the gravitational acceleration of prisms, using Choclo
kernels for it. Add tests that compare with bare Choclo results. Remove
the dispatcher and replace it with and `if`/`else` statement for
selecting the parallelized or serialized jitted function.
Add tests against dumb Choclo calls and a Laplace equation test for the
diagonal tensor components. Improve the warning on the docstring
explaining the direction of `z`.
The tests in Choclo already cover those and they are more extensive.
Check if the gravity tensor components of a prism are being computed at
any singular point. Choclo will return a ``np.nan`` on those points, but
it's worth warning the user about it before they get the results.
Add tests that check if the warnings are being raised on those cases.
Update the expected values after we updated the gravitational constant
in Choclo.
Modify the test function that compares prism forward model with the
analytic solution for an infinite slab: locate the observation point on
top of the slab.
Rename forward_func variable to avoid confusion with the forward_func
argument of the jit functions.
Move some details to a new Notes section, improve some definition of the
parameters, improve the warning regarding the upward direction, add
a References section.
@santisoler
Copy link
Member Author

Closing this, since I merged this branch into #400

@santisoler santisoler closed this May 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant