![]() |
Semi-Lagrangian Library
Modular library for kinetic and gyrokinetic simulations of plasmas in fusion energy devices.
|
Interpolator for 2D tensor-product splines of arbitrary degree, on uniform and non-uniform grids (directions are independent)
Derived types and interfaces | |
| type | sll_t_spline_2d_boundary_data |
| Container for 2D boundary condition data: . x1-derivatives at x1_min and x1_max, for all values of x2; . x2-derivatives at x2_min and x2_max, for all values of x1; . mixed derivatives at the four corners a,b,c,d. More... | |
| type | sll_t_spline_interpolator_2d |
| 2D tensor-product spline interpolator More... | |
Functions/Subroutines | |
| subroutine, public | sll_s_spline_2d_compute_num_cells (degree, bc_xmin, bc_xmax, nipts, ncells) |
| Calculate number of cells from number of interpolation points. More... | |
| subroutine | s_spline_interpolator_2d__init (self, bspl1, bspl2, bc_xmin, bc_xmax) |
| Initialize a 2D tensor-product spline interpolator object. More... | |
| subroutine | s_spline_interpolator_2d__free (self) |
| Destroy local objects and free allocated memory. More... | |
| subroutine | s_spline_interpolator_2d__get_interp_points (self, tau1, tau2) |
| Get coordinates of interpolation points (2D tensor grid) More... | |
| subroutine | s_spline_interpolator_2d__compute_interpolant (self, spline, gtau, boundary_data) |
| Compute interpolating 2D spline. More... | |
Variables | |
| integer, parameter | wp = f64 |
| Working precision. More... | |
|
private |
Compute interpolating 2D spline.
Compute coefficients of 2D tensor-product spline that interpolates function values on grid. If Hermite BCs are used, function derivatives at appropriate boundaries are also needed.
| [in,out] | self | 2D tensor-product spline interpolator |
| [in,out] | spline | 2D tensor-product spline |
| [in] | gtau | function values of interpolation points |
| [in] | boundary_data | (optional) structure with boundary conditions |
Definition at line 241 of file sll_m_spline_interpolator_2d.F90.
|
private |
Destroy local objects and free allocated memory.
| [in,out] | self | 2D tensor-product spline interpolator |
Definition at line 194 of file sll_m_spline_interpolator_2d.F90.
|
private |
Get coordinates of interpolation points (2D tensor grid)
| [in] | self | 2D tensor-product spline interpolator |
| [out] | tau1 | x1 coordinates of interpolation points |
| [out] | tau2 | x2 coordinates of interpolation points |
Definition at line 219 of file sll_m_spline_interpolator_2d.F90.
|
private |
Initialize a 2D tensor-product spline interpolator object.
| [out] | self | 2D tensor-product spline interpolator |
| [in] | bspl1 | B-splines (basis) along x1 direction |
| [in] | bspl2 | B-splines (basis) along x2 direction |
| [in] | bc_xmin | boundary conditions at x1_min and x2_min |
| [in] | bc_xmax | boundary conditions at x1_max and x2_max |
Definition at line 141 of file sll_m_spline_interpolator_2d.F90.
| subroutine, public sll_m_spline_interpolator_2d::sll_s_spline_2d_compute_num_cells | ( | integer, dimension(2), intent(in) | degree, |
| integer, dimension(2), intent(in) | bc_xmin, | ||
| integer, dimension(2), intent(in) | bc_xmax, | ||
| integer, dimension(2), intent(in) | nipts, | ||
| integer, dimension(2), intent(out) | ncells | ||
| ) |
Calculate number of cells from number of interpolation points.
Important for parallelization: for given spline degree and BCs, calculate the numbers of grid cells along x1 and x2 that yield the desired number of interpolation points along x1 and x2
| [in] | degree | spline degrees along x1 and x2 |
| [in] | bc_xmin | boundary conditions at x1_min and x2_min |
| [in] | bc_xmax | boundary conditions at x1_max and x2_max |
| [in] | nipts | desired number of interpolation points along x1 and x2 |
| [out] | ncells | calculated number of grid cells along x1 and x2 |
Definition at line 111 of file sll_m_spline_interpolator_2d.F90.
|
private |
Working precision.
Definition at line 38 of file sll_m_spline_interpolator_2d.F90.
1.9.1