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

Add unit test for 1D constant lambda #1598

Merged
merged 1 commit into from
Aug 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -67,5 +67,6 @@ Anthony Walker (@anthony-walker), Oregon State University
Bryan Weber (@bryanwweber), University of Connecticut
Armin Wehrfritz (@awehrfritz)
Richard West (@rwest), Northeastern University
Shumeng Xie (@yeanment), National University of Singapore
Chao Xu (@12Chao), Northeastern University
Thorsten Zirwes (@g3bk47), Karlsruhe Institute of Technology
5 changes: 5 additions & 0 deletions test/python/test_onedim.py
Original file line number Diff line number Diff line change
Expand Up @@ -1282,6 +1282,7 @@ def run_case(self, phi, T, width, P):
sim.solve(loglevel=0, auto=True)
self.assertTrue(all(sim.T >= T - 1e-3))
self.assertTrue(all(sim.spread_rate >= -1e-9))
assert np.allclose(sim.L, sim.L[0])
return sim

@utilities.slow_test
Expand Down Expand Up @@ -1391,6 +1392,7 @@ def run_case(self, phi, T, width, P):
sim.solve(loglevel=0, auto=True)
self.assertTrue(all(sim.T >= T - 1e-3))
self.assertTrue(all(sim.spread_rate >= -1e-9))
assert np.allclose(sim.L, sim.L[0])
return sim

@utilities.slow_test
Expand Down Expand Up @@ -1436,6 +1438,7 @@ def solve(self, phi, T, width, P):
sim.burner.mdot = gas.density * 0.15
sim.solve(loglevel=0, auto=True)
self.assertGreater(sim.T[1], T)
assert np.allclose(sim.L, 0)

def test_case1(self):
self.solve(phi=0.5, T=500, width=2.0, P=0.1)
Expand Down Expand Up @@ -1530,6 +1533,7 @@ def run_stagnation(self, xh2, mdot, width):
sim.solve(loglevel=0, auto=True)

assert sim.T.max() > tburner + tsurf
assert np.allclose(sim.L, sim.L[0])
self.sim = sim

def test_stagnation_case1(self):
Expand Down Expand Up @@ -1717,6 +1721,7 @@ def solve(self, phi, T, width, P):
sim.reactants.mdot = gas.density * axial_velocity
sim.solve(loglevel=0, auto=True)
self.assertGreater(sim.T[-1], T + 100)
assert np.allclose(sim.L, sim.L[0])
return sim

def test_restart(self):
Expand Down
Loading