Skip to content
This repository was archived by the owner on Dec 22, 2021. It is now read-only.

Tesseroid should warn if ignoring cells too small#228

Merged
leouieda merged 7 commits intomasterfrom
small-tesseroid
Aug 11, 2015
Merged

Tesseroid should warn if ignoring cells too small#228
leouieda merged 7 commits intomasterfrom
small-tesseroid

Conversation

@leouieda
Copy link
Copy Markdown
Member

The code currently ignores input tesseroids that are too small (sides < 1e-6 degrees or ~ 0.1m) but does so silently. It should spit out a warning so that the user this is happening.

Also, when dividing below a size 1e-6 (horizontal) I get a ZeroDivisionError. This is because I stop the small tesseroids from going into the kernel functions but there is no check when the tesseroids are being divided. The code should calculate the effects of these tesseroids without dividing and warn the user of this.

This PR implements the tests that catch these two problems and the solutions.

Checklist:

  • Make tests for new code
  • Create/update docstrings
  • Include relevant equations and citations in docstrings
  • Code follows PEP8 style conventions
  • Code and docs have been spellchecked
  • Include new dependencies in docs, requirements.txt, README, and .travis.yml
  • Documentation builds properly
  • All tests pass
  • Can be merged
  • Changelog entry (leave for last)

The code ignores input tesseroids that are too small but does so
silently. It should spit out a warning.

Also, when dividing below a size 1e-6 (horizontal) I get a
ZeroDivisionError. The code should not divide such small tesseroids but
warn the user of this.

Made two tests that check this. They fail still because I haven't made
the correction.
@leouieda leouieda added this to the 0.4 milestone Aug 11, 2015
leouieda added a commit that referenced this pull request Aug 11, 2015
Tesseroid should warn if ignoring cells too small
@leouieda leouieda merged commit 442de32 into master Aug 11, 2015
@leouieda leouieda deleted the small-tesseroid branch August 11, 2015 21:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant