@@ -187,8 +187,8 @@ def test_bounding():
187187 np .linspace (Rmin , Rmax , nx ),
188188 np .linspace (Zmin , Zmax , ny ),
189189 np .zeros ((nx , ny )), # psi2d
190- [],
191- [], # psi1d, fpol
190+ np . linspace ( 0.0 , 1.0 , nx ), # psi1d
191+ np . linspace ( 0.0 , 1.0 , nx ), # fpol1d
192192 make_regions = False ,
193193 )
194194
@@ -216,7 +216,12 @@ def psi_func(R, Z):
216216 )
217217
218218 eq = tokamak .TokamakEquilibrium (
219- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
219+ r1d ,
220+ z1d ,
221+ psi_func (r2d , z2d ),
222+ np .linspace (0.0 , 1.0 , nx ), # psi1d
223+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
224+ make_regions = False ,
220225 )
221226
222227 assert len (eq .x_points ) == 1
@@ -245,8 +250,8 @@ def test_wall_anticlockwise():
245250 np .linspace (Rmin , Rmax , nx ),
246251 np .linspace (Zmin , Zmax , ny ),
247252 np .zeros ((nx , ny )), # psi2d
248- [],
249- [], # psi1d, fpol
253+ np . linspace ( 0.0 , 1.0 , nx ), # psi1d
254+ np . linspace ( 0.0 , 1.0 , nx ), # fpol1d
250255 wall = wall ,
251256 make_regions = False ,
252257 )
@@ -275,8 +280,8 @@ def test_wall_clockwise():
275280 np .linspace (Rmin , Rmax , nx ),
276281 np .linspace (Zmin , Zmax , ny ),
277282 np .zeros ((nx , ny )), # psi2d
278- [],
279- [], # psi1d, fpol
283+ np . linspace ( 0.0 , 1.0 , nx ), # psi1d
284+ np . linspace ( 0.0 , 1.0 , nx ), # fpol1d
280285 wall = wall ,
281286 make_regions = False ,
282287 )
@@ -312,7 +317,12 @@ def psi_func(R, Z):
312317 )
313318
314319 return tokamak .TokamakEquilibrium (
315- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
320+ r1d ,
321+ z1d ,
322+ psi_func (r2d , z2d ),
323+ np .linspace (0.0 , 1.0 , nx ), # psi1d
324+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
325+ make_regions = False ,
316326 )
317327
318328
@@ -335,7 +345,12 @@ def psi_func(R, Z):
335345 )
336346
337347 return tokamak .TokamakEquilibrium (
338- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
348+ r1d ,
349+ z1d ,
350+ psi_func (r2d , z2d ),
351+ np .linspace (0.0 , 1.0 , nx ), # psi1d
352+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
353+ make_regions = False ,
339354 )
340355
341356
@@ -359,7 +374,12 @@ def psi_func(R, Z):
359374 )
360375
361376 return tokamak .TokamakEquilibrium (
362- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
377+ r1d ,
378+ z1d ,
379+ psi_func (r2d , z2d ),
380+ psi_func (np .linspace (1.6 , 2.0 , nx ), np .zeros (nx )), # psi1d
381+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
382+ make_regions = False ,
363383 )
364384
365385
@@ -382,7 +402,13 @@ def psi_func(R, Z):
382402 )
383403
384404 return tokamak .TokamakEquilibrium (
385- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
405+ r1d ,
406+ z1d ,
407+ psi_func (r2d , z2d ),
408+ psi_func (np .linspace (1.6 , 2.0 , nx ), np .zeros (nx )), # psi1d
409+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
410+ make_regions = False ,
411+ settings = {"nx_inter_sep" : 1 },
386412 )
387413
388414
@@ -405,7 +431,13 @@ def psi_func(R, Z):
405431 )
406432
407433 return tokamak .TokamakEquilibrium (
408- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False # psi1d, fpol
434+ r1d ,
435+ z1d ,
436+ psi_func (r2d , z2d ),
437+ psi_func (np .linspace (1.6 , 2.0 , nx ), np .zeros (nx )), # psi1d
438+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
439+ make_regions = False ,
440+ settings = {"nx_inter_sep" : 1 },
409441 )
410442
411443
@@ -431,8 +463,16 @@ def psi_func(R, Z):
431463 + np .exp (- ((R - r0 ) ** 2 + (Z - 2 * z0 ) ** 2 ) / 0.3 ** 2 )
432464 )
433465
466+ settings .update (nx_inter_sep = 1 )
467+
434468 return tokamak .TokamakEquilibrium (
435- r1d , z1d , psi_func (r2d , z2d ), [], [], make_regions = False , settings = settings
469+ r1d ,
470+ z1d ,
471+ psi_func (r2d , z2d ),
472+ psi_func (np .linspace (1.6 , 2.0 , nx ), np .zeros (nx )), # psi1d
473+ np .linspace (0.0 , 1.0 , nx ), # fpol1d
474+ make_regions = False ,
475+ settings = settings ,
436476 )
437477
438478
0 commit comments