SemiDiscreteOT 1.0
Semi-Discrete Optimal Transport Library
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
SemiDiscreteOT< dim, spacedim > Class Template Reference

Main class for the semi-discrete optimal transport solver. More...

#include <SemiDiscreteOT.h>

Inheritance diagram for SemiDiscreteOT< dim, spacedim >:
Inheritance graph
[legend]
Collaboration diagram for SemiDiscreteOT< dim, spacedim >:
Collaboration graph
[legend]

Public Member Functions

 SemiDiscreteOT (const MPI_Comm &mpi_communicator)
 Constructor for the SemiDiscreteOT class.
 
void run ()
 Runs the solver with the current configuration.
 
void configure (std::function< void(SotParameterManager &)> config_func)
 Configure the solver parameters programmatically.
 
void setup_source_measure (Triangulation< dim, spacedim > &tria, const DoFHandler< dim, spacedim > &dh, const Vector< double > &density, const std::string &name="source")
 Setup source measure from standard deal.II objects (simplified API for tutorials)
 
void setup_target_measure (const std::vector< Point< spacedim > > &points, const Vector< double > &weights)
 Set up the target measure from a discrete set of points and weights.
 
void prepare_multilevel_hierarchies ()
 Pre-computes the multilevel hierarchies for source and/or target. This must be called after setting up the base measures and before calling solve() if multilevel computation is desired.
 
void prepare_source_multilevel ()
 Pre-computes the multilevel hierarchy for the source.
 
void prepare_target_multilevel ()
 Pre-computes the multilevel hierarchy for the target.
 
SotSolver< dim, spacedim > * get_solver ()
 Get a pointer to the solver object.
 
const SotParameterManager::SolverParametersget_solver_params () const
 Get a reference to the solver parameters.
 
const Vector< double > & get_coarsest_potential () const
 Get the coarsest potential from the multilevel solve.
 
Vector< double > solve (const Vector< double > &initial_potential=Vector< double >())
 Run the optimal transport computation based on the current configuration. This method handles single-level, multilevel, and epsilon scaling automatically.
 
void save_discrete_measures ()
 Saves the discrete source and target measures to files.
 
void set_distance_function (const std::function< double(const Point< spacedim > &, const Point< spacedim > &)> &dist)
 Sets the distance function to be used by the solver.
 

Public Attributes

ConditionalOStream pcout
 A conditional output stream for parallel printing.
 

Protected Member Functions

void save_results (const Vector< double > &potentials, const std::string &filename, bool add_epsilon_prefix=true)
 Saves the results of the computation.
 
void normalize_density (LinearAlgebra::distributed::Vector< double > &density)
 Normalizes the density vector.
 

Protected Attributes

MPI_Comm mpi_communicator
 The MPI communicator.
 
const unsigned int n_mpi_processes
 The number of MPI processes.
 
const unsigned int this_mpi_process
 The rank of the current MPI process.
 
std::unique_ptr< SotSolver< dim, spacedim > > sot_solver
 The semi-discrete optimal transport solver.
 
SotParameterManager param_manager
 The parameter manager.
 
SotParameterManager::MeshParameterssource_params
 A reference to the source mesh parameters.
 
SotParameterManager::MeshParameterstarget_params
 A reference to the target mesh parameters.
 
SotParameterManager::SolverParameterssolver_params
 A reference to the solver parameters.
 
SotParameterManager::MultilevelParametersmultilevel_params
 A reference to the multilevel parameters.
 
SotParameterManager::PowerDiagramParameterspower_diagram_params
 A reference to the power diagram parameters.
 
SotParameterManager::TransportMapParameterstransport_map_params
 A reference to the transport map parameters.
 
std::string & selected_task
 A reference to the selected task.
 
std::string & io_coding
 A reference to the I/O coding.
 
std::unique_ptr< DoFHandler< dim, spacedim > > initial_fine_dof_handler
 The initial fine DoF handler.
 
std::unique_ptr< Vector< double > > initial_fine_density
 The initial fine density.
 
bool is_setup_programmatically_ = false
 A flag to indicate if the setup is done programmatically.
 
std::string source_mesh_name = "source"
 The name of the source mesh.
 
parallel::fullydistributed::Triangulation< dim, spacedim > source_mesh
 The source mesh.
 
Triangulation< dim, spacedim > target_mesh
 The target mesh.
 
DoFHandler< dim, spacedim > dof_handler_source
 The DoF handler for the source mesh.
 
DoFHandler< dim, spacedim > dof_handler_target
 The DoF handler for the target mesh.
 
std::unique_ptr< VTKHandler< dim, spacedim > > source_vtk_handler
 The VTK handler for the source mesh.
 
DoFHandler< dim, spacedim > vtk_dof_handler_source
 The DoF handler for the source VTK mesh.
 
Vector< double > vtk_field_source
 The source field from the VTK file.
 
Triangulation< dim, spacedim > vtk_tria_source
 The triangulation from the source VTK file.
 
std::unique_ptr< FiniteElement< dim, spacedim > > fe_system
 The finite element system.
 
std::unique_ptr< Mapping< dim, spacedim > > mapping
 The mapping.
 
std::unique_ptr< FiniteElement< dim, spacedim > > fe_system_target
 The target finite element system.
 
std::unique_ptr< Mapping< dim, spacedim > > mapping_target
 The target mapping.
 
LinearAlgebra::distributed::Vector< double > source_density
 The source density.
 
Vector< double > target_density
 The target density.
 
std::vector< Point< spacedim > > target_points
 The target points.
 
std::vector< Point< spacedim > > source_points
 The source points.
 
std::unique_ptr< MeshManager< dim, spacedim > > mesh_manager
 The mesh manager.
 
std::unique_ptr< EpsilonScalingHandlerepsilon_scaling_handler
 The epsilon scaling handler.
 

Private Member Functions

void mesh_generation ()
 Generates the source and target meshes.
 
void load_meshes ()
 Loads the source and target meshes from files.
 
Vector< double > run_sot (const Vector< double > &initial_potential=Vector< double >())
 Run single-level SOT computation.
 
void compute_power_diagram ()
 Computes the power diagram of the target points.
 
void compute_transport_map ()
 Computes the transport map from the source to the target measure.
 
void compute_conditional_density ()
 Computes the conditional density of the source measure.
 
Vector< double > run_multilevel (const Vector< double > &initial_potential=Vector< double >())
 Run multilevel SOT computation (dispatcher method).
 
Vector< double > run_combined_multilevel (const Vector< double > &initial_potential=Vector< double >())
 Run combined source and target multilevel SOT computation.
 
Vector< double > run_source_multilevel (const Vector< double > &initial_potential=Vector< double >())
 Run source-only multilevel SOT computation.
 
Vector< double > run_target_multilevel (const Vector< double > &initial_potential=Vector< double >())
 Run target-only multilevel SOT computation.
 
void setup_source_finite_elements (bool is_multilevel=false)
 Sets up the finite elements for the source mesh.
 
void setup_target_finite_elements ()
 Sets up the finite elements for the target mesh.
 
void setup_finite_elements ()
 Sets up the finite elements for both the source and target meshes.
 
void setup_target_points ()
 Sets up the target points.
 
void setup_multilevel_finite_elements ()
 Sets up the finite elements for a multilevel computation.
 
template<int d = dim, int s = spacedim>
std::enable_if< d==3 &&s==3 >::type run_exact_sot ()
 Runs the exact semi-discrete optimal transport solver.
 
void load_hierarchy_data (const std::string &hierarchy_dir, int specific_level=-1)
 Loads the hierarchy data from a directory.
 
void assign_potentials_by_hierarchy (Vector< double > &potentials, int coarse_level, int fine_level, const Vector< double > &prev_potentials)
 Assigns potentials by hierarchy.
 
std::vector< std::pair< std::string, std::string > > get_target_hierarchy_files () const
 Gets the target hierarchy files.
 
std::vector< std::string > get_mesh_hierarchy_files () const
 Gets the mesh hierarchy files.
 
void load_target_points_at_level (const std::string &points_file, const std::string &density_file)
 Loads the target points at a specific level.
 
void save_interpolated_fields ()
 

Private Attributes

std::vector< std::vector< std::vector< size_t > > > child_indices_
 The child indices for the multilevel hierarchy.
 
bool has_hierarchy_data_ {false}
 A flag to indicate if the hierarchy data is loaded.
 
std::vector< Point< spacedim > > target_points_coarse
 The coarse level target points.
 
Vector< double > target_density_coarse
 The coarse level target densities.
 
double current_distance_threshold {0.0}
 The current distance threshold for computations.
 
Vector< double > coarsest_potential
 The coarsest level potential for the multilevel solve.
 

Detailed Description

template<int dim, int spacedim = dim>
class SemiDiscreteOT< dim, spacedim >

Main class for the semi-discrete optimal transport solver.

This class orchestrates the entire process of solving a semi-discrete optimal transport problem. It manages the source and target measures, the solver, and the various numerical strategies that can be employed.

Template Parameters
dimThe dimension of the source mesh.
spacedimThe dimension of the space the mesh is embedded in.

Definition at line 77 of file SemiDiscreteOT.h.

Constructor & Destructor Documentation

◆ SemiDiscreteOT()

template<int dim, int spacedim>
SemiDiscreteOT< dim, spacedim >::SemiDiscreteOT ( const MPI_Comm &  mpi_communicator)

Constructor for the SemiDiscreteOT class.

Parameters
mpi_communicatorThe MPI communicator.

Definition at line 8 of file SemiDiscreteOT.cc.

Member Function Documentation

◆ run()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::run ( )

Runs the solver with the current configuration.

Definition at line 2592 of file SemiDiscreteOT.cc.

Here is the caller graph for this function:

◆ configure()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::configure ( std::function< void(SotParameterManager &)>  config_func)

Configure the solver parameters programmatically.

Parameters
config_funcA lambda function that takes a reference to the SotParameterManager and modifies its parameters.

Definition at line 32 of file SemiDiscreteOT.cc.

◆ setup_source_measure()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_source_measure ( Triangulation< dim, spacedim > &  tria,
const DoFHandler< dim, spacedim > &  dh,
const Vector< double > &  density,
const std::string &  name = "source" 
)

Setup source measure from standard deal.II objects (simplified API for tutorials)

Parameters
triaA standard Triangulation
dhA DoFHandler on the provided triangulation
densityA standard Vector containing the density values
nameAn optional name for the source mesh (used for saving and hierarchy generation)

This method internally handles the conversion to distributed objects when needed for parallel computation.

Definition at line 51 of file SemiDiscreteOT.cc.

◆ setup_target_measure()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_target_measure ( const std::vector< Point< spacedim > > &  points,
const Vector< double > &  weights 
)

Set up the target measure from a discrete set of points and weights.

Parameters
pointsA vector of target points.
weightsA vector of weights/densities for each target point.

Definition at line 131 of file SemiDiscreteOT.cc.

◆ prepare_multilevel_hierarchies()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::prepare_multilevel_hierarchies ( )

Pre-computes the multilevel hierarchies for source and/or target. This must be called after setting up the base measures and before calling solve() if multilevel computation is desired.

Definition at line 175 of file SemiDiscreteOT.cc.

◆ prepare_source_multilevel()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::prepare_source_multilevel ( )

Pre-computes the multilevel hierarchy for the source.

Parameters
source_levelThe level of the source hierarchy to prepare.

Definition at line 1845 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ prepare_target_multilevel()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::prepare_target_multilevel ( )

Pre-computes the multilevel hierarchy for the target.

Parameters
target_levelThe level of the target hierarchy to prepare.

Definition at line 1897 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ get_solver()

template<int dim, int spacedim = dim>
SotSolver< dim, spacedim > * SemiDiscreteOT< dim, spacedim >::get_solver ( )
inline

Get a pointer to the solver object.

Returns
Pointer to the solver object.

Definition at line 144 of file SemiDiscreteOT.h.

◆ get_solver_params()

template<int dim, int spacedim = dim>
const SotParameterManager::SolverParameters & SemiDiscreteOT< dim, spacedim >::get_solver_params ( ) const
inline

Get a reference to the solver parameters.

Returns
Reference to the solver parameters.

Definition at line 150 of file SemiDiscreteOT.h.

◆ get_coarsest_potential()

template<int dim, int spacedim = dim>
const Vector< double > & SemiDiscreteOT< dim, spacedim >::get_coarsest_potential ( ) const
inline

Get the coarsest potential from the multilevel solve.

Returns
Reference to the coarsest potential vector.

Definition at line 156 of file SemiDiscreteOT.h.

◆ solve()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::solve ( const Vector< double > &  initial_potential = Vector<double>())

Run the optimal transport computation based on the current configuration. This method handles single-level, multilevel, and epsilon scaling automatically.

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
A vector containing the computed optimal transport potentials for the target points.

Definition at line 196 of file SemiDiscreteOT.cc.

◆ save_discrete_measures()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::save_discrete_measures ( )

Saves the discrete source and target measures to files.

Definition at line 2404 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ set_distance_function()

template<int dim, int spacedim = dim>
void SemiDiscreteOT< dim, spacedim >::set_distance_function ( const std::function< double(const Point< spacedim > &, const Point< spacedim > &)> &  dist)
inline

Sets the distance function to be used by the solver.

Parameters
distThe distance function.

Definition at line 177 of file SemiDiscreteOT.h.

◆ save_results()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::save_results ( const Vector< double > &  potentials,
const std::string &  filename,
bool  add_epsilon_prefix = true 
)
protected

Saves the results of the computation.

Parameters
potentialsThe computed optimal transport potentials.
filenameThe name of the file to save the results to.
add_epsilon_prefixWhether to add an epsilon prefix to the filename.

Definition at line 1982 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ normalize_density()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::normalize_density ( LinearAlgebra::distributed::Vector< double > &  density)
protected

Normalizes the density vector.

Parameters
densityThe density vector to normalize.

Definition at line 337 of file SemiDiscreteOT.cc.

◆ mesh_generation()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::mesh_generation ( )
private

Generates the source and target meshes.

Definition at line 216 of file SemiDiscreteOT.cc.

◆ load_meshes()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::load_meshes ( )
private

Loads the source and target meshes from files.

Definition at line 234 of file SemiDiscreteOT.cc.

◆ run_sot()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::run_sot ( const Vector< double > &  initial_potential = Vector<double>())
private

Run single-level SOT computation.

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
Vector containing the optimal transport potentials for the target points.

Definition at line 748 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ compute_power_diagram()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::compute_power_diagram ( )
private

Computes the power diagram of the target points.

Definition at line 2124 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ compute_transport_map()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::compute_transport_map ( )
private

Computes the transport map from the source to the target measure.

Definition at line 2010 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ compute_conditional_density()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::compute_conditional_density ( )
private

Computes the conditional density of the source measure.

Definition at line 2239 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ run_multilevel()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::run_multilevel ( const Vector< double > &  initial_potential = Vector<double>())
private

Run multilevel SOT computation (dispatcher method).

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
Vector containing the optimal transport potentials for the target points.

Definition at line 1759 of file SemiDiscreteOT.cc.

◆ run_combined_multilevel()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::run_combined_multilevel ( const Vector< double > &  initial_potential = Vector<double>())
private

Run combined source and target multilevel SOT computation.

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
Vector containing the optimal transport potentials for the target points.

Definition at line 1472 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ run_source_multilevel()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::run_source_multilevel ( const Vector< double > &  initial_potential = Vector<double>())
private

Run source-only multilevel SOT computation.

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
Vector containing the optimal transport potentials for the target points.

Definition at line 1242 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ run_target_multilevel()

template<int dim, int spacedim>
Vector< double > SemiDiscreteOT< dim, spacedim >::run_target_multilevel ( const Vector< double > &  initial_potential = Vector<double>())
private

Run target-only multilevel SOT computation.

Parameters
initial_potentialOptional initial potential values to start the optimization from.
Returns
Vector containing the optimal transport potentials for the target points.

Definition at line 883 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ setup_source_finite_elements()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_source_finite_elements ( bool  is_multilevel = false)
private

Sets up the finite elements for the source mesh.

Parameters
is_multilevelWhether the setup is for a multilevel computation.

Definition at line 369 of file SemiDiscreteOT.cc.

◆ setup_target_finite_elements()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_target_finite_elements ( )
private

Sets up the finite elements for the target mesh.

Definition at line 501 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ setup_finite_elements()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_finite_elements ( )
private

Sets up the finite elements for both the source and target meshes.

Definition at line 651 of file SemiDiscreteOT.cc.

◆ setup_target_points()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::setup_target_points ( )
private

Sets up the target points.

Definition at line 659 of file SemiDiscreteOT.cc.

◆ setup_multilevel_finite_elements()

template<int dim, int spacedim = dim>
void SemiDiscreteOT< dim, spacedim >::setup_multilevel_finite_elements ( )
private

Sets up the finite elements for a multilevel computation.

◆ run_exact_sot()

template<int dim, int spacedim>
template<int d, int s>
std::enable_if< d==3 &&s==3 >::type SemiDiscreteOT< dim, spacedim >::run_exact_sot ( )
private

Runs the exact semi-discrete optimal transport solver.

Definition at line 1795 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ load_hierarchy_data()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::load_hierarchy_data ( const std::string &  hierarchy_dir,
int  specific_level = -1 
)
private

Loads the hierarchy data from a directory.

Parameters
hierarchy_dirThe directory containing the hierarchy data.
specific_levelThe specific level to load.

Definition at line 332 of file SemiDiscreteOT.cc.

◆ assign_potentials_by_hierarchy()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::assign_potentials_by_hierarchy ( Vector< double > &  potentials,
int  coarse_level,
int  fine_level,
const Vector< double > &  prev_potentials 
)
private

Assigns potentials by hierarchy.

Parameters
potentialsThe potentials to assign.
coarse_levelThe coarse level.
fine_levelThe fine level.
prev_potentialsThe previous potentials.

Definition at line 666 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ get_target_hierarchy_files()

template<int dim, int spacedim>
std::vector< std::pair< std::string, std::string > > SemiDiscreteOT< dim, spacedim >::get_target_hierarchy_files ( ) const
private

Gets the target hierarchy files.

Returns
A vector of pairs of strings, where each pair contains the path to the points file and the density file.

Definition at line 256 of file SemiDiscreteOT.cc.

Here is the call graph for this function:

◆ get_mesh_hierarchy_files()

template<int dim, int spacedim = dim>
std::vector< std::string > SemiDiscreteOT< dim, spacedim >::get_mesh_hierarchy_files ( ) const
private

Gets the mesh hierarchy files.

Returns
A vector of strings, where each string is the path to a mesh file.

◆ load_target_points_at_level()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::load_target_points_at_level ( const std::string &  points_file,
const std::string &  density_file 
)
private

Loads the target points at a specific level.

Parameters
points_fileThe path to the points file.
density_fileThe path to the density file.

Definition at line 262 of file SemiDiscreteOT.cc.

◆ save_interpolated_fields()

template<int dim, int spacedim>
void SemiDiscreteOT< dim, spacedim >::save_interpolated_fields ( )
private

Save interpolated fields for source and target meshes. This is useful for debugging and visualization purposes. Uses the field names from the parameter files.

Definition at line 2475 of file SemiDiscreteOT.cc.

Member Data Documentation

◆ pcout

template<int dim, int spacedim = dim>
ConditionalOStream SemiDiscreteOT< dim, spacedim >::pcout

A conditional output stream for parallel printing.

Definition at line 183 of file SemiDiscreteOT.h.

◆ mpi_communicator

template<int dim, int spacedim = dim>
MPI_Comm SemiDiscreteOT< dim, spacedim >::mpi_communicator
protected

The MPI communicator.

Definition at line 186 of file SemiDiscreteOT.h.

◆ n_mpi_processes

template<int dim, int spacedim = dim>
const unsigned int SemiDiscreteOT< dim, spacedim >::n_mpi_processes
protected

The number of MPI processes.

Definition at line 187 of file SemiDiscreteOT.h.

◆ this_mpi_process

template<int dim, int spacedim = dim>
const unsigned int SemiDiscreteOT< dim, spacedim >::this_mpi_process
protected

The rank of the current MPI process.

Definition at line 188 of file SemiDiscreteOT.h.

◆ sot_solver

template<int dim, int spacedim = dim>
std::unique_ptr<SotSolver<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::sot_solver
protected

The semi-discrete optimal transport solver.

Definition at line 191 of file SemiDiscreteOT.h.

◆ param_manager

template<int dim, int spacedim = dim>
SotParameterManager SemiDiscreteOT< dim, spacedim >::param_manager
protected

The parameter manager.

Definition at line 194 of file SemiDiscreteOT.h.

◆ source_params

template<int dim, int spacedim = dim>
SotParameterManager::MeshParameters& SemiDiscreteOT< dim, spacedim >::source_params
protected

A reference to the source mesh parameters.

Definition at line 195 of file SemiDiscreteOT.h.

◆ target_params

template<int dim, int spacedim = dim>
SotParameterManager::MeshParameters& SemiDiscreteOT< dim, spacedim >::target_params
protected

A reference to the target mesh parameters.

Definition at line 196 of file SemiDiscreteOT.h.

◆ solver_params

template<int dim, int spacedim = dim>
SotParameterManager::SolverParameters& SemiDiscreteOT< dim, spacedim >::solver_params
protected

A reference to the solver parameters.

Definition at line 197 of file SemiDiscreteOT.h.

◆ multilevel_params

template<int dim, int spacedim = dim>
SotParameterManager::MultilevelParameters& SemiDiscreteOT< dim, spacedim >::multilevel_params
protected

A reference to the multilevel parameters.

Definition at line 198 of file SemiDiscreteOT.h.

◆ power_diagram_params

template<int dim, int spacedim = dim>
SotParameterManager::PowerDiagramParameters& SemiDiscreteOT< dim, spacedim >::power_diagram_params
protected

A reference to the power diagram parameters.

Definition at line 199 of file SemiDiscreteOT.h.

◆ transport_map_params

template<int dim, int spacedim = dim>
SotParameterManager::TransportMapParameters& SemiDiscreteOT< dim, spacedim >::transport_map_params
protected

A reference to the transport map parameters.

Definition at line 200 of file SemiDiscreteOT.h.

◆ selected_task

template<int dim, int spacedim = dim>
std::string& SemiDiscreteOT< dim, spacedim >::selected_task
protected

A reference to the selected task.

Definition at line 201 of file SemiDiscreteOT.h.

◆ io_coding

template<int dim, int spacedim = dim>
std::string& SemiDiscreteOT< dim, spacedim >::io_coding
protected

A reference to the I/O coding.

Definition at line 202 of file SemiDiscreteOT.h.

◆ initial_fine_dof_handler

template<int dim, int spacedim = dim>
std::unique_ptr<DoFHandler<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::initial_fine_dof_handler
protected

The initial fine DoF handler.

Definition at line 204 of file SemiDiscreteOT.h.

◆ initial_fine_density

template<int dim, int spacedim = dim>
std::unique_ptr<Vector<double> > SemiDiscreteOT< dim, spacedim >::initial_fine_density
protected

The initial fine density.

Definition at line 205 of file SemiDiscreteOT.h.

◆ is_setup_programmatically_

template<int dim, int spacedim = dim>
bool SemiDiscreteOT< dim, spacedim >::is_setup_programmatically_ = false
protected

A flag to indicate if the setup is done programmatically.

Definition at line 206 of file SemiDiscreteOT.h.

◆ source_mesh_name

template<int dim, int spacedim = dim>
std::string SemiDiscreteOT< dim, spacedim >::source_mesh_name = "source"
protected

The name of the source mesh.

Definition at line 209 of file SemiDiscreteOT.h.

◆ source_mesh

template<int dim, int spacedim = dim>
parallel::fullydistributed::Triangulation<dim, spacedim> SemiDiscreteOT< dim, spacedim >::source_mesh
protected

The source mesh.

Definition at line 212 of file SemiDiscreteOT.h.

◆ target_mesh

template<int dim, int spacedim = dim>
Triangulation<dim, spacedim> SemiDiscreteOT< dim, spacedim >::target_mesh
protected

The target mesh.

Definition at line 213 of file SemiDiscreteOT.h.

◆ dof_handler_source

template<int dim, int spacedim = dim>
DoFHandler<dim, spacedim> SemiDiscreteOT< dim, spacedim >::dof_handler_source
protected

The DoF handler for the source mesh.

Definition at line 214 of file SemiDiscreteOT.h.

◆ dof_handler_target

template<int dim, int spacedim = dim>
DoFHandler<dim, spacedim> SemiDiscreteOT< dim, spacedim >::dof_handler_target
protected

The DoF handler for the target mesh.

Definition at line 215 of file SemiDiscreteOT.h.

◆ source_vtk_handler

template<int dim, int spacedim = dim>
std::unique_ptr<VTKHandler<dim,spacedim> > SemiDiscreteOT< dim, spacedim >::source_vtk_handler
protected

The VTK handler for the source mesh.

Definition at line 217 of file SemiDiscreteOT.h.

◆ vtk_dof_handler_source

template<int dim, int spacedim = dim>
DoFHandler<dim,spacedim> SemiDiscreteOT< dim, spacedim >::vtk_dof_handler_source
protected

The DoF handler for the source VTK mesh.

Definition at line 218 of file SemiDiscreteOT.h.

◆ vtk_field_source

template<int dim, int spacedim = dim>
Vector<double> SemiDiscreteOT< dim, spacedim >::vtk_field_source
protected

The source field from the VTK file.

Definition at line 219 of file SemiDiscreteOT.h.

◆ vtk_tria_source

template<int dim, int spacedim = dim>
Triangulation<dim,spacedim> SemiDiscreteOT< dim, spacedim >::vtk_tria_source
protected

The triangulation from the source VTK file.

Definition at line 220 of file SemiDiscreteOT.h.

◆ fe_system

template<int dim, int spacedim = dim>
std::unique_ptr<FiniteElement<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::fe_system
protected

The finite element system.

Definition at line 222 of file SemiDiscreteOT.h.

◆ mapping

template<int dim, int spacedim = dim>
std::unique_ptr<Mapping<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::mapping
protected

The mapping.

Definition at line 223 of file SemiDiscreteOT.h.

◆ fe_system_target

template<int dim, int spacedim = dim>
std::unique_ptr<FiniteElement<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::fe_system_target
protected

The target finite element system.

Definition at line 224 of file SemiDiscreteOT.h.

◆ mapping_target

template<int dim, int spacedim = dim>
std::unique_ptr<Mapping<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::mapping_target
protected

The target mapping.

Definition at line 225 of file SemiDiscreteOT.h.

◆ source_density

template<int dim, int spacedim = dim>
LinearAlgebra::distributed::Vector<double> SemiDiscreteOT< dim, spacedim >::source_density
protected

The source density.

Definition at line 226 of file SemiDiscreteOT.h.

◆ target_density

template<int dim, int spacedim = dim>
Vector<double> SemiDiscreteOT< dim, spacedim >::target_density
protected

The target density.

Definition at line 227 of file SemiDiscreteOT.h.

◆ target_points

template<int dim, int spacedim = dim>
std::vector<Point<spacedim> > SemiDiscreteOT< dim, spacedim >::target_points
protected

The target points.

Definition at line 228 of file SemiDiscreteOT.h.

◆ source_points

template<int dim, int spacedim = dim>
std::vector<Point<spacedim> > SemiDiscreteOT< dim, spacedim >::source_points
protected

The source points.

Definition at line 229 of file SemiDiscreteOT.h.

◆ mesh_manager

template<int dim, int spacedim = dim>
std::unique_ptr<MeshManager<dim, spacedim> > SemiDiscreteOT< dim, spacedim >::mesh_manager
protected

The mesh manager.

Definition at line 232 of file SemiDiscreteOT.h.

◆ epsilon_scaling_handler

template<int dim, int spacedim = dim>
std::unique_ptr<EpsilonScalingHandler> SemiDiscreteOT< dim, spacedim >::epsilon_scaling_handler
protected

The epsilon scaling handler.

Definition at line 235 of file SemiDiscreteOT.h.

◆ child_indices_

template<int dim, int spacedim = dim>
std::vector<std::vector<std::vector<size_t> > > SemiDiscreteOT< dim, spacedim >::child_indices_
private

The child indices for the multilevel hierarchy.

Definition at line 343 of file SemiDiscreteOT.h.

◆ has_hierarchy_data_

template<int dim, int spacedim = dim>
bool SemiDiscreteOT< dim, spacedim >::has_hierarchy_data_ {false}
private

A flag to indicate if the hierarchy data is loaded.

Definition at line 344 of file SemiDiscreteOT.h.

◆ target_points_coarse

template<int dim, int spacedim = dim>
std::vector<Point<spacedim> > SemiDiscreteOT< dim, spacedim >::target_points_coarse
private

The coarse level target points.

Definition at line 353 of file SemiDiscreteOT.h.

◆ target_density_coarse

template<int dim, int spacedim = dim>
Vector<double> SemiDiscreteOT< dim, spacedim >::target_density_coarse
private

The coarse level target densities.

Definition at line 354 of file SemiDiscreteOT.h.

◆ current_distance_threshold

template<int dim, int spacedim = dim>
double SemiDiscreteOT< dim, spacedim >::current_distance_threshold {0.0}
mutableprivate

The current distance threshold for computations.

Definition at line 355 of file SemiDiscreteOT.h.

◆ coarsest_potential

template<int dim, int spacedim = dim>
Vector<double> SemiDiscreteOT< dim, spacedim >::coarsest_potential
private

The coarsest level potential for the multilevel solve.

Definition at line 356 of file SemiDiscreteOT.h.


The documentation for this class was generated from the following files: