-
Notifications
You must be signed in to change notification settings - Fork 258
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
Sp reimplement #1211
Sp reimplement #1211
Conversation
@sgkang Here is my implementation of the SP simulation. Very lightweight as it inherits almost everything from the DC Simulation. |
from scipy.interpolate import NearestNDInterpolator, LinearNDInterpolator | ||
|
||
|
||
def readSeepageModel(fname, mesh=None, xsurf=None, ysurf=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure this has a place in SimPEG right now...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to bring this in.
Codecov Report
@@ Coverage Diff @@
## main #1211 +/- ##
==========================================
- Coverage 81.99% 81.81% -0.19%
==========================================
Files 159 162 +3
Lines 24411 24481 +70
==========================================
+ Hits 20016 20028 +12
- Misses 4395 4453 +58
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking great. Your SP implementation is concise and elegant.
Played a little bit with the sparse inversion, and it seems working well.
It seemed the sensitivity (or Ainv) is not updated while inversion, but it would be nice if you could check.
It would be great to add some tutorials at least for each of three source types, and further replicate Craig's field example.
Above example is accessible through: https://curvenote.com/@sgkang09/researches/sp-3d-inv-charge.2
Thanks Seogi for the review. I've made the requested updates and will pull this in. Feels good to not have the leftover pieces from before the simulation switchover in the codebase anymore! We can add tutorials and such in another PR. |
Summary
Reimplements the SP method in SimPEG.
PR Checklist
expect style.
GRAV
,EM
, etc.)to a Pull Request
@simpeg/simpeg-developers
when ready for review.What does this implement/fix?
This reimplements the SP code in SimPEG, making heavy use of the existing DC formulation. It is written that the
q
property is the model.It also defines a few new maps that are specific to the SP methodology, one relating the secondary current density vector defined at cell-centers to
q
by taking the negative divergence of it. The second relates the hydraulic head to theq
. These two maps are simple extensions of theLinearMap
. Together with the simple formulation relating toq
these should mimic all of the previous functionality of the SP code.Additional information
I went back and forth deciding on the name of the module this lives, i.e. it is either
spontaneous_potential
orself_potential
. I went in favor ofspontaneous
purely because the wordself
has a common meaning in python programming. But I'm happy either way.