Skip to content
Snippets Groups Projects
Commit 42d8c011 authored by Dominic Kempf's avatar Dominic Kempf
Browse files

Merge branch 'cleanup/instationary' into 'master'

[cleanup] Make function names more consistent

Small name changes. I succesfully ran all tests.

See merge request !18
parents 5daceaaf 6293f249
No related branches found
No related tags found
No related merge requests found
......@@ -1328,7 +1328,7 @@ def visualize_initial_condition():
@preamble
def implicit_time_loop():
def time_loop():
ini = name_initree()
formdata = _driver_data['formdata']
params = name_parameters(formdata)
......@@ -1340,7 +1340,7 @@ def implicit_time_loop():
vector_type = type_vector(formdata)
vector = name_vector(formdata)
# TODO -> formcompiler argument
# Choose between explicit and implicit time stepping
explicit = get_option('explicit_time_stepping')
if explicit:
osm = name_explicitonestepmethod()
......@@ -1349,6 +1349,8 @@ def implicit_time_loop():
boundary = name_boundary_function(expr)
osm = name_onestepmethod()
apply_call = "{}.apply(time, dt, {}, {}, {}new);".format(osm, vector, boundary, vector)
# Setup visualization
visualize_initial_condition()
vtk_sequence_writer = name_vtk_sequence_writer()
......@@ -1374,7 +1376,7 @@ def implicit_time_loop():
""]
def time_loop():
def solve_instationary():
# Test if form is linear in ansatzfunction
linear = is_linear(_driver_data['form'])
......@@ -1385,7 +1387,7 @@ def time_loop():
if linear and matrix_free:
assert False
elif linear and not matrix_free:
implicit_time_loop()
time_loop()
if not linear and matrix_free:
assert False
elif not linear and not matrix_free:
......@@ -1413,7 +1415,7 @@ def generate_driver(formdatas, data):
if is_stationary():
vtkoutput()
else:
time_loop()
solve_instationary()
from dune.perftool.generation import retrieve_cache_items
from cgen import FunctionDeclaration, FunctionBody, Block, Value
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment