From 61cd3b6bc53c151863bd99fb2a03b29157a876ca Mon Sep 17 00:00:00 2001 From: Adrian Kummerlaender Date: Thu, 13 Jun 2019 21:19:49 +0200 Subject: Tidy up symbolic kernel generation --- implosion.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'implosion.py') diff --git a/implosion.py b/implosion.py index e5e87bc..fb101b4 100644 --- a/implosion.py +++ b/implosion.py @@ -7,6 +7,8 @@ matplotlib.use('AGG') from D2Q9 import Lattice +import symbolic.D2Q9 as D2Q9 + def MLUPS(cells, steps, time): return cells * steps / time * 1e-6 @@ -56,7 +58,13 @@ moments = [] print("Initializing simulation...\n") -lattice = Lattice(nX = 1024, nY = 1024, tau = 0.8, geometry = box, pop_eq_src = pop_eq, boundary_src = boundary) +lattice = Lattice( + nX = 1024, nY = 1024, + geometry = box, + moments = D2Q9.moments(optimize = False), + collide = D2Q9.bgk(tau = 0.8), + pop_eq_src = pop_eq, + boundary_src = boundary) print("Starting simulation using %d cells...\n" % lattice.nCells) -- cgit v1.2.3