diff --git a/misc/finiterectlat-constant-driving.py b/misc/finiterectlat-constant-driving.py index 3d6ee5e..4d3a0ea 100755 --- a/misc/finiterectlat-constant-driving.py +++ b/misc/finiterectlat-constant-driving.py @@ -237,7 +237,9 @@ t, l, m = bspec.tlm() if not math.isnan(a.ccd_distance): logging.info("Computing the far fields") - ccd_size = (50 * a.ccd_distance / (max(Nx*px, Ny*py) * ssw.wavenumber.real)) if math.isnan(a.ccd_size) else a.ccd_size + if math.isnan(a.ccd_size): + a.ccd_size = (50 * a.ccd_distance / (max(Nx*px, Ny*py) *ssw.wavenumber.real)) + ccd_size = a.ccd_size ccd_x = np.linspace(-ccd_size/2, ccd_size/2, a.ccd_resolution) ccd_y = np.linspace(-ccd_size/2, ccd_size/2, a.ccd_resolution) ccd_grid = np.meshgrid(ccd_x, ccd_y, (a.ccd_distance,), indexing='ij')