aboutsummaryrefslogtreecommitdiff
path: root/boltzgen.py
diff options
context:
space:
mode:
Diffstat (limited to 'boltzgen.py')
-rw-r--r--boltzgen.py16
1 files changed, 6 insertions, 10 deletions
diff --git a/boltzgen.py b/boltzgen.py
index 6d410c3..27a34fa 100644
--- a/boltzgen.py
+++ b/boltzgen.py
@@ -9,16 +9,12 @@ argparser.add_argument('language', help = 'Target language (currently either "op
args = argparser.parse_args()
lbm = LBM(D2Q9)
-geometry = Geometry(32,32)
+generator = Generator(
+ descriptor = D2Q9,
+ moments = lbm.moments(),
+ collision = lbm.bgk(f_eq = lbm.equilibrium(), tau = 0.6))
-src = source(
- args.language,
- D2Q9,
- lbm.moments(),
- lbm.bgk(f_eq = lbm.equilibrium(), tau = 0.6),
- "",
- 'float',
- geometry
-)
+geometry = Geometry(32,32)
+src = generator.kernel(args.language, 'float', geometry)
print(src)