-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Labels
enhancementNew feature or requestNew feature or request
Description
To have the Smart grid fully functional for Wakefield simulations, we need to adapt the wake potential integration in wakeSolver.py to account for non uniform integration path. Hence, dz is no longer a float but an array of values:
# ... inside WakeSolver ...
# both in calc_long_WP_3d(self, **kwargs)
# and in calc_long_WP(self, Ezt=None,**kwargs):
for n in range(len(s)):
for k in range(nz):
ts = (z[k]+s[n])/self.v-zmin/self.v-self.t[0]+ti
it = int(ts / dt) # find index for t
if it < nt:
WP[n] = WP[n] + (Ezt[k, it]) * dz # compute integral
pbar.update(1)
WP = WP/(self.q*1e12) # [V/pC]
WP_3d[i0+i,j0+j,:] = WP
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request