added unit tests for CE/LI and LE/QI

This commit is contained in:
liangjg 2019-01-23 15:50:01 -05:00
parent cbbac7df8d
commit 0f639937b7
4 changed files with 154 additions and 1 deletions

View file

@ -110,6 +110,8 @@ def leqi(operator, timesteps, power=None, power_density=None, print_out=True):
t = operator.prev_res[-1].time[-1]
i_res = len(operator.prev_res)
chain = operator.chain
for i, (dt, p) in enumerate(zip(timesteps, power)):
# Perform SI-CE/LI CFQ4 for the first step
if i == 0:
@ -149,7 +151,7 @@ def leqi(operator, timesteps, power=None, power_density=None, print_out=True):
dt_l = dt
# Perform one last simulation
x = [copy.deepcopy(vec)]
x = [copy.deepcopy(x_new)]
op_results = [operator(x[0], power[-1])]
# Create results, write to disk