Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | List of all members
shammath::paving_function_general_3d< Tvec > Struct Template Reference

A structure for 3D paving functions with general boundary conditions (periodic or reflective per directions). More...

#include <shammath/include/shammath/paving_function.hpp>

Public Types

using Tscal = shambase::VecComponent< Tvec >
 

Public Member Functions

Tvec f (Tvec x, int i, int j, int k) const
 Applies the paving function with periodic or reflective boundary conditions.
 
Tvec f_inv (Tvec x, int i, int j, int k) const
 Applies the inverse of the paving function.
 
AABB< Tvec > f_aabb (const AABB< Tvec > &aabb, int i, int j, int k) const
 
AABB< Tvec > f_aabb_inv (const AABB< Tvec > &aabb, int i, int j, int k) const
 
std::vector< std::array< int, 3 > > get_paving_index_intersecting (AABB< Tvec > aabb) const
 

Public Attributes

Tvec box_size
 The size of the box in each dimension.
 
Tvec box_center
 The center of the box in each dimension.
 
bool is_x_periodic
 The boundary condition in each dimension.
 
bool is_y_periodic
 
bool is_z_periodic
 

Static Public Attributes

static constexpr bool can_deform_aabb = false
 

Detailed Description

template<typename Tvec>
struct shammath::paving_function_general_3d< Tvec >

A structure for 3D paving functions with general boundary conditions (periodic or reflective per directions).

Template Parameters
TvecA vector type.

Definition at line 142 of file paving_function.hpp.

Member Typedef Documentation

◆ Tscal

template<typename Tvec >
using shammath::paving_function_general_3d< Tvec >::Tscal = shambase::VecComponent<Tvec>

Definition at line 147 of file paving_function.hpp.

Member Function Documentation

◆ f()

template<typename Tvec >
Tvec shammath::paving_function_general_3d< Tvec >::f ( Tvec  x,
int  i,
int  j,
int  k 
) const
inline

Applies the paving function with periodic or reflective boundary conditions.

Parameters
xThe input vector.
iThe periodic index along the x-axis.
jThe periodic index along the y-axis.
kThe periodic index along the z-axis.
Returns
The transformed vector.

Definition at line 178 of file paving_function.hpp.

◆ f_aabb()

template<typename Tvec >
AABB< Tvec > shammath::paving_function_general_3d< Tvec >::f_aabb ( const AABB< Tvec > &  aabb,
int  i,
int  j,
int  k 
) const
inline

Definition at line 204 of file paving_function.hpp.

◆ f_aabb_inv()

template<typename Tvec >
AABB< Tvec > shammath::paving_function_general_3d< Tvec >::f_aabb_inv ( const AABB< Tvec > &  aabb,
int  i,
int  j,
int  k 
) const
inline

Definition at line 208 of file paving_function.hpp.

◆ f_inv()

template<typename Tvec >
Tvec shammath::paving_function_general_3d< Tvec >::f_inv ( Tvec  x,
int  i,
int  j,
int  k 
) const
inline

Applies the inverse of the paving function.

Parameters
xThe input vector.
iThe periodic index along the x-axis.
jThe periodic index along the y-axis.
kThe periodic index along the z-axis.
Returns
The inverse transformed vector.

Definition at line 195 of file paving_function.hpp.

◆ get_paving_index_intersecting()

template<typename Tvec >
std::vector< std::array< int, 3 > > shammath::paving_function_general_3d< Tvec >::get_paving_index_intersecting ( AABB< Tvec >  aabb) const
inline

Definition at line 212 of file paving_function.hpp.

Member Data Documentation

◆ box_center

template<typename Tvec >
Tvec shammath::paving_function_general_3d< Tvec >::box_center

The center of the box in each dimension.

Definition at line 157 of file paving_function.hpp.

◆ box_size

template<typename Tvec >
Tvec shammath::paving_function_general_3d< Tvec >::box_size

The size of the box in each dimension.

Definition at line 152 of file paving_function.hpp.

◆ can_deform_aabb

template<typename Tvec >
constexpr bool shammath::paving_function_general_3d< Tvec >::can_deform_aabb = false
inlinestaticconstexpr

Definition at line 145 of file paving_function.hpp.

◆ is_x_periodic

template<typename Tvec >
bool shammath::paving_function_general_3d< Tvec >::is_x_periodic

The boundary condition in each dimension.

true means periodic boundary condition. false means reflective boundary condition.

Definition at line 165 of file paving_function.hpp.

◆ is_y_periodic

template<typename Tvec >
bool shammath::paving_function_general_3d< Tvec >::is_y_periodic

Definition at line 166 of file paving_function.hpp.

◆ is_z_periodic

template<typename Tvec >
bool shammath::paving_function_general_3d< Tvec >::is_z_periodic

Definition at line 167 of file paving_function.hpp.


The documentation for this struct was generated from the following file: