Skip to content

Commit 25707bd

Browse files
Fix datatypes.
1 parent 86105dc commit 25707bd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

perpendicular-flap/solid-fenics/solid.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,8 @@ def neumann_boundary(x, on_boundary):
9595
Chung, J., and Hulbert, G. M. (June 1, 1993). "A Time Integration Algorithm for Structural Dynamics With Improved Numerical Dissipation:
9696
The Generalized-α Method." ASME. J. Appl. Mech. June 1993; 60(2): 371–375. https://doi.org/10.1115/1.2900803
9797
"""
98-
assert (alpha_m <= alpha_f)
99-
assert (alpha_f <= 0.5)
98+
assert (float(alpha_m) <= float(alpha_f))
99+
assert (float(alpha_f) <= 0.5)
100100

101101
gamma = Constant(0.5 + alpha_f - alpha_m)
102102
beta = Constant((gamma + 0.5)**2 / 4.)
@@ -223,7 +223,7 @@ def avg(x_old, x_new, alpha):
223223
precice.write_data(u_np1)
224224

225225
# Call to advance coupling, also returns the optimum time step value
226-
precice.advance(dt(0))
226+
precice.advance(float(dt))
227227

228228
# Either revert to old step if timestep has not converged or move to next timestep
229229
if precice.requires_reading_checkpoint(): # roll back to checkpoint

0 commit comments

Comments
 (0)