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

1D tests on dev don't run #313

Closed
evaneschneider opened this issue Jul 20, 2023 · 6 comments
Closed

1D tests on dev don't run #313

evaneschneider opened this issue Jul 20, 2023 · 6 comments
Labels

Comments

@evaneschneider
Copy link
Collaborator

When trying to run a test on the dev branch with ny = 1 and nz = 1 in a parameter file, the code exits with the following error:

Invalid boundary conditions. Must select between 1 (periodic), 2 (reflective), 3 (transmissive), 4 (custom), 5 (mpi).

This happens even though the boundary conditions are set in the parameter file, and appear to be read in, since the code correctly outputs:

Parameter values: nx = 100, ny = 1, nz = 1, tout = 0.200000, init = Riemann, boundaries = 3 3 3 3 3 3

before it fails.

@evaneschneider
Copy link
Collaborator Author

Removing the "if" statements in the Check_Custom_Boundary function in boundary_conditions.cpp fixes the boundary error, but the Riemann problems are still broken. The issue is that the initial conditions are not getting set, because the code never enters the loop.

@bcaddy
Copy link
Collaborator

bcaddy commented Jul 21, 2023

I fixed the underflow issue in the Riemann ICs (see PR #314). I'm not sure exactly what you want done in the boundary condition code so I didn't touch that. The tests still don't run though even with both fixes, after the first time step it returns all NaNs.

Once these issues are resolved we should add 1D and 2D sod tests to the system tests so we don't have this issue again.

@alwinm
Copy link
Collaborator

alwinm commented Jul 22, 2023

Output from git bisect

Before this change, running 1-D sod.txt from examples completed successfully (though I don't guarantee numerical accuracy, I can say that the output from sod.txt has been consistent since main branch).

I'm not sure what the bug is and I should caveat that multiple types of things go wrong after this commit so the bug could still be in any number of things, not sure if its this particular commit.

531efcbd2bbbd6b18f4b5a05f3e29f938f09a9ae is the first bad commit
commit 531efcbd2bbbd6b18f4b5a05f3e29f938f09a9ae
Author: Bob Caddy <r.Caddy@pitt.edu>
Date:   Tue Jun 20 15:27:40 2023 -0400

    Make all IC functions use parameter struct as arg
    
    Now all the initial condition functions just take the parameters struct
    as the argument instead of a bunch of Reals.

 src/grid/grid3D.h                     |  43 ++++++----
 src/grid/initial_conditions.cpp       | 153 +++++++++++++++++-----------------
 src/system_tests/mhd_system_tests.cpp |   3 +
 3 files changed, 104 insertions(+), 95 deletions(-)

@alwinm
Copy link
Collaborator

alwinm commented Jul 22, 2023

With VL and bypassing the above bugs it runs. With SIMPLE and bypassing the above bugs it does not run. I think the differences between VL and SIMPLE warrant further investigation.

@alwinm
Copy link
Collaborator

alwinm commented Jul 22, 2023

Ignore my above comments which I initially intended as adding info to the problem, and were helpful for me personally, but no longer useful as of #315 .

@evaneschneider
Copy link
Collaborator Author

Solved in PR #315

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants