Repository navigation
Built on SCTL 2.1.0. Documentation: https://biest.readthedocs.io
New
- Field periods:
Surfacedeclares its field periods, andFieldPeriodBIOp,SurfaceOp,VacuumFieldandTaylorStatework on one field period (#9).FieldPeriodBIOp::Evaland the vacuum-field classes also take data on half a field period and complete it by stellarator symmetry, withbiest::Paritygiving the parity of the data (#10). - Off-surface evaluation:
OffSurfaceOpsplits its panels until their Legendre coefficients are within the tolerance and the area element is resolved, and can fit them to given fields such as the density. For the rotating ellipse of virtual-casing, at 3, 6 and 9 digits requested, the field off the surface gets 3.7, 7.3 and 10.6 digits, against 1.9, 3.3 and 3.6 with panels fit to the surface alone (#9). - Near quadrature between surfaces: the potential of one surface at the grid points of another nearby surface, in place of the trapezoidal rule (#9).
- Singular quadrature chosen at run time from the tolerance and the grid anisotropy, or given by
SingularQuadParams(#9). VacuumFieldandTaylorStatecan be used as objects that keep their operators from one call to the next (#9).ExtVacuumField::GetTargetCoordandIntVacuumField::GetTargetCoordreturn the points of the field grid (#10).- Unit tests for the operators and solvers, CI, and documentation on Read the Docs (#8).
Performance
SurfaceOpuses 1D transforms of rows and columns in place of 2D FFTW plans; the singular correction uses SmallGEMM in place of BLAS; temporaries are in scratch memory. W7-X on 96 threads: inner solves take 4.1-7.0 s, against 8.4-21.5 s (#9).- Repeated calls of the operators,
VacuumField::ComputeandTaylorState::Computemake no heap allocations (#9).
Fixes
SurfaceOp::SurfCurlread the wrong entries for every vector field after the first (#8).BoundaryIntegralOpgave every surface the normal orientation of the last one; with surfaces of opposite grid orientation, kernels that use the source normal had errors of 4e-2 (#8).FieldPeriodBIOp::Evalresampled the density with theNFPgiven toSetupSingularin place of the one given toEval(#8).IntVacuumField: the field of the currentI0read the wrong grid coordinates whenNFP > 1(#8).VacuumFieldon a toroidal shell: the vector potential of the second basis field included the first, and the fluxes were measured on one surface only (#8).VacuumFieldandTaylorStatechoose the outer and inner surfaces by enclosed volume in place of area (#8).CompleteVecFieldassumed that the toroidal index increases counterclockwise; data ordered clockwise gave a discontinuous surface (#8).OffSurfaceOpstopped refining at 8 panel nodes per grid point, which lost accuracy on surfaces that need more (#8).WriteVTKwithhalf_periodwrote a scalar that changes sign, such as B.n, with the wrong sign on the mirrored half (#10).TaylorStatenow compiles with Clang and Intel icpx, and the code compiles without warnings with GCC, Clang and icpx (#11).
Interface changes
FieldPeriodBIOp<Real, HedgehogOrder>is the one public layer-potential class, without theCOORD_DIM,KDIM0andKDIM1parameters;BoundaryIntegralOpis internal.SetupSingulartakes a tolerance and aSingularQuadParams, or the field periods and grids of a surface, and optional fields to resolve.Eval(U, F, NFP, src_Nt, src_Np, half_period = false, parity = Parity::Even)(#9, #10).SingularQuadParamsreplaces the template parametersUPSAMPLE,PATCH_DIM0andRAD_DIMofBoundaryIntegralOp,FieldPeriodBIOp,VacuumFieldandTaylorState;SingularCorrection::Setuptakesskip_tandskip_pin place ofTRG_SKIP(#9).- The
SurfaceOpconstructor takesNFPand the toroidal orientation.SurfaceOp::CompleteVecField(X, half_period, NFP, Nt, Np, Y, parity, tor_orient, dtheta = 0)replaces the version withis_surf(#9, #10). WriteVTKtakes the parity ofF(#10).VacuumField::EvalOffSurfacetakestor_flux,pol_fluxand aJfor each surface in place ofJ0, and its targets by reference (#9).OffSurfaceOp::SetupandSetupSurfacetake optional fields for the panels to resolve;SetupSurfaceandSetTargetsset up the panels and the targets separately (#9).biest::Matis removed; usesctl::Tensor(#9).applications/virtual-casingis removed; it is superseded by hiddenSymmetries/virtual-casing (#8).
Full Changelog: v1.0.0...v2.0.0