fix Cgamma computation
@@ -1221,6 +1221,9 @@ def wake_prop(MS, use_sparse=False, sparse_format='lil', settings=None):
Surf_star.zetac
except AttributeError:
Surf_star.generate_collocations()
+ # if Surf_star.u_input_coll is None:
+ # print("computing input velocities wake")
+ # Surf_star.get_input_velocities_at_collocation_points()
params = {'zeta': [Surf_star.zetac],
'override': False,
@@ -1231,7 +1234,7 @@ def wake_prop(MS, use_sparse=False, sparse_format='lil', settings=None):
settings['vel_gen'].generate(params, uext)
# Compute induced velocities in the wake
Surf_star.u_ind_coll = np.zeros((3, M_star, N))
- MS.get_ind_velocities_at_target_collocation_points(Surf_star)
+ # MS.get_ind_velocities_at_target_collocation_points(Surf_star)
# ... and fill
# iivec = np.array(range(N), dtype=int)
@@ -1246,7 +1249,8 @@ def wake_prop(MS, use_sparse=False, sparse_format='lil', settings=None):
conv_vec = Surf_star.zetac[:, 0, iin] - Surf.zetac[:, -1, iin]
dist = np.linalg.norm(conv_vec)
conv_dir_te = conv_vec/dist
- vel = uext[0][:, 0, iin] + Surf_star.u_ind_coll[:, 0, iin] - Surf.u_input_coll[:, -1, iin]
+ # vel = uext[0][:, 0, iin] + Surf_star.u_ind_coll[:, 0, iin] - Surf.u_input_coll[:, -1, iin]
+ vel = Surf.u_input_coll[:, -1, iin]
vel_value = np.dot(vel, conv_dir_te)
cfl = settings['dt']*vel_value/dist
@@ -1258,8 +1262,10 @@ def wake_prop(MS, use_sparse=False, sparse_format='lil', settings=None):
conv_vec = Surf_star.zetac[:, mm, iin] - Surf_star.zetac[:, mm - 1, iin]
dist = np.linalg.norm(conv_vec)
conv_dir = conv_vec/dist
- vel_value = np.dot(uext[0][:, mm, iin] + Surf_star.u_ind_coll[:, mm, iin], conv_dir)
- vel_value -= np.dot(Surf.u_input_coll[:, -1, iin], conv_dir_te)
+ # vel_value = np.dot(uext[0][:, mm, iin] + Surf_star.u_ind_coll[:, mm, iin], conv_dir)
+ # vel_value -= np.dot(Surf.u_input_coll[:, -1, iin], conv_dir_te)
+ # vel = Surf_star.u_input_coll[:, mm, iin]
+ # vel_value = np.dot(vel, conv_dir)
cfl = settings['dt']*vel_value/dist
C_star[mm * N + iin, (mm - 1) * N + iin] = cfl
