Skip to content

Commit

Permalink
fix typo and logical error
Browse files Browse the repository at this point in the history
  • Loading branch information
smiet committed Nov 10, 2023
1 parent 0c830ab commit 18386db
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/simsopt/geo/surface.py
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,7 @@ def inverse_fourier_transform_field(self, A_mns, A_mnc, normalization=None, **kw

if not stellsym:
field = field + A_mnc[0, ntor]
if normalization is not none:
if normalization is not None:
if type(normalization) is not float:
raise ValueError("normalization must be a float")
field = field * normalization
Expand Down
2 changes: 1 addition & 1 deletion src/simsopt/geo/surfacerzfourier.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def from_other_surface(cls, other: "SurfaceRZFourier", **kwargs):
# recalculate the quadpoints if necessary (grid_range is not stored in the
# surface object, so assume that if it is given, the gridpoints should be
# recalculated to the specified size)
if ntheta is not otherntheta and nphi is not othernphi and grid_range is not None:
if ntheta is not otherntheta or nphi is not othernphi or grid_range is not None:
kwargs["quadpoints_phi"], kwargs["quadpoints_theta"] = Surface.get_quadpoints(
ntheta=ntheta, nphi=nphi, nfp=other.nfp, range=grid_range)
else:
Expand Down

0 comments on commit 18386db

Please sign in to comment.