-
Notifications
You must be signed in to change notification settings - Fork 30
[FEAT]: Dipole grid and 1D improvements #155
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Moving the files grid.md, ensembles.md, indices.md to new folder `docs/internal`. Should organize things a little better, but the folder name might need to be changed. ALSO: - Update the README's with the updated TOC's. - Consistent Markdown syntax: - consistent use of dashes/equals & hashtags for header level - no double empty lines - headings in descending-by-one order - denote links with <>'s - Add a language to each fenced (three backticks) code blocks
This commit adds ionGrid to the default aether.json file (in share/run/aether.json). The ionGrid specs set here hold no importance, but these three values need to be set to enable the tests to pass. Ideally, this is moved from the settings file to a function which reads the inputs (and either sets the default values or catches the error), but for now this works.
Drafted first in python. This code makes plots & is adjustable. I commented everything so it's hopefully understandable... Reach out with questions. Similar to SAMI2/3 grid. It's B_par & B_perp aligned, made in dipole (p,q) coords, and specified w/ (nf, nz). Code hands back (r,lat) though, not (q,p) or anything like that... Code needs to be able to be modified for tilted, offset dipole so I left all the for-loops and didn't spend any time optimizing.
…lizing mag grid Paper on this from 2006: <https://arxiv.org/pdf/physics/0606044>
…lizing mag grid Paper on this from 2006: <https://arxiv.org/pdf/physics/0606044>
Working. Need to port to init_mag_grid.cpp
Code can run in 1D (alt)
Couple issues remain: - Longitudes are sometimes nan in output files? - nLats needs to be even. And it's not checked. - Ghost cells probably not implemented correctly.
Netcdf files can't be ready by xarray (python) when a dimension has the same name as a variable. This is a problem for "z". Renames all `(x,y,z,time)` -> `(n_x, n_y, n_z, n_time)` > there are two output_netcdf files. I dont think the other is used?
clean out old comments, improve comments that are gonna be left, refactor a bit. - Some nan's in lon are removed by changing the transform.cpp. It's not a bug so I included it in this commit. - Style in transform.coo too.
- not all ionGrid options are used for sphere/dipole grid. I'll add a doc page on this in the next commit...
! I removed the section about passing btwn N/S hemispheres, since that's undecided.
> Probably won't work. But a decent starting point, I hope. Feel free to revert this commit if it's broken.
Though I could do something clever. It's wasn't. Glad I caught this, geez
## Documentation changes: - Update description of geographic & dipole grids - Rearrange `.md` files, complete docs might be easier to generate with this ## test passing - I found an issue that caused tests to fail. this was a quick fix to the input files. ## DIPOLE GRID > big one here - I rewrote the magnetic grid to be in dipole coordinates. *should* be field-aligned. - Very similar to SAMI2/3 grid - Changed inputs, docs, etc. to support this.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Addresses #152 , #153 , and some other things.
Couple changes here. Putting this all into one PR for ease of merging, but a lot of changes were made:
Type of change
Please delete options that are not relevant.
to not work as expected)
How Has This Been Tested?
A lot.
Tested dipole grid with various input params, couldn’t break it using sensible inputs:
Aaron R tested the 1D runs with neutrals.
Test configuration
Checklist:
develop
(notmaster
) branchCHANGELOG.md
, summarizing the changes