Bicameral Engine
GPU-resident engine for a magic-research open-world game
Loading...
Searching...
No Matches
bicameral::sim::anonymous_namespace{implicit_conduction.cpp} Namespace Reference

Classes

struct  Containing
struct  RowEntry
struct  Bounds
struct  Rational
struct  Rkl2Stage

Typedefs

using CellKey = std::tuple<int32_t, int64_t, int64_t, int64_t>
using Rows = std::vector<std::vector<RowEntry>>

Functions

FxU128 Wide (uint64_t value)
bool IsZero (FxU128 value)
FxU128 WideAdd (FxU128 a, FxU128 b)
FxU128 WideShiftRight (FxU128 value, uint32_t shift)
FxU128 WideShiftLeft (FxU128 value, uint32_t shift)
FxU128 WideMul (FxU128 a, uint64_t b)
int64_t Weight (FxU128 numerator, FxU128 denominator)
int64_t ShiftRightSigned (int64_t value, uint32_t shift)
int64_t FaceFlow (FxU128 coefficient, int64_t difference)
std::map< CellKey, uint32_t > MakeCellIndex (const std::vector< ImplicitCell > &cells)
std::optional< Containing > FindContaining (const std::map< CellKey, uint32_t > &index, int32_t level, int64_t x, int64_t y, int64_t z)
FxU128 FaceCoefficient (const ImplicitCell &fine, const ImplicitCell &coarse)
void FindFaces (ImplicitGrid &grid)
void AddToRow (std::vector< RowEntry > &row, uint32_t neighbor, FxU128 coefficient)
void PushNode (ImplicitGridLevel &level, const CellKey &key, FxU128 capacity)
void FinishLevel (ImplicitGridLevel &level, const Rows &rows)
ImplicitGridLevel MakeCellLevel (const ImplicitGrid &grid)
bool NeedsCoarser (const ImplicitGridLevel &level)
ImplicitGridLevel Coarsen (ImplicitGridLevel &fine, bool galerkin)
int64_t Relax (const ImplicitGridLevel &level, const std::vector< int64_t > &rhs, const std::vector< int64_t > &values, size_t node)
void SweepColor (const ImplicitGridLevel &level, const std::vector< int64_t > &rhs, uint8_t color, std::vector< int64_t > &values, std::vector< int64_t > &next)
void Smooth (const ImplicitGridLevel &level, const std::vector< int64_t > &rhs, std::vector< int64_t > &values, uint32_t sweeps, ImplicitCost &cost)
void VCycle (const ImplicitGrid &grid, size_t depth, const std::vector< int64_t > &rhs, std::vector< int64_t > &values, const ImplicitOptions &options, ImplicitCost &cost)
bool Converged (const ImplicitGridLevel &cells, const std::vector< int64_t > &rhs, const std::vector< int64_t > &values, uint32_t toleranceMillikelvin, ImplicitCost &cost)
std::vector< int64_t > Temperatures (const ImplicitGrid &grid)
std::vector< int64_t > Flows (const ImplicitGrid &grid, const std::vector< int64_t > &temperatures)
void ApplyFlows (ImplicitGrid &grid, const std::vector< int64_t > &flows)
int64_t AddClamped (int64_t a, int64_t b)
std::vector< int64_t > ExplicitFlows (const ImplicitGrid &grid, const std::vector< int64_t > &start)
Bounds MakeBounds (const ImplicitGrid &grid, const std::vector< int64_t > &start, int64_t slackMillikelvin)
std::vector< int64_t > EnergiesAfter (const ImplicitGrid &grid, const std::vector< int64_t > &flows)
int64_t Overrun (int64_t energy, const Bounds &bounds, size_t i)
bool MarkOutside (const ImplicitGrid &grid, const Bounds &bounds, const std::vector< int64_t > &energies, std::vector< uint8_t > &limited, ImplicitCost &cost)
void LimitFlows (const ImplicitGrid &grid, const std::vector< int64_t > &start, int64_t slackMillikelvin, std::vector< int64_t > &flows, ImplicitCost &cost)
Rational Rkl2B (uint64_t j)
int64_t RationalWeight (FxU128 numerator, FxU128 denominator, bool negative)
std::vector< Rkl2Stage > Rkl2Stages (uint32_t stageCount)
uint32_t Rkl2StageCount (const ImplicitGridLevel &cells)
std::vector< int64_t > StageTemperatures (const ImplicitGrid &grid, const std::vector< int64_t > &start, const std::vector< int64_t > &accumulated)
int64_t MulWeight (int64_t weight, int64_t value)
std::vector< int64_t > Rkl2Flows (const ImplicitGrid &grid, const std::vector< int64_t > &start, ImplicitCost &cost)

Variables

constexpr uint32_t WEIGHT_SHIFT = IM_WEIGHT_SHIFT
constexpr uint32_t TEMPERATURE_SHIFT = IM_TEMPERATURE_SHIFT
constexpr int64_t HALF_WEIGHT = int64_t{1} << (WEIGHT_SHIFT - 1)
constexpr uint32_t ENERGY_BITS_PER_LEVEL = IM_ENERGY_BITS_PER_LEVEL
constexpr uint32_t STAGE_RATIO_SHIFT = 16
constexpr size_t MAX_GRID_LEVELS = 64
constexpr uint8_t COLOR_COUNT = 2
constexpr uint32_t CORRECTION_SCALE_SHIFT = IM_CORRECTION_SCALE_SHIFT
constexpr std::array< std::array< int64_t, 3 >, 6 > FACE_OFFSETS

Typedef Documentation

◆ CellKey

using bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::CellKey = std::tuple<int32_t, int64_t, int64_t, int64_t>

Definition at line 43 of file implicit_conduction.cpp.

◆ Rows

using bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Rows = std::vector<std::vector<RowEntry>>

Definition at line 170 of file implicit_conduction.cpp.

Function Documentation

◆ AddClamped()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::AddClamped ( int64_t a,
int64_t b )

Definition at line 432 of file implicit_conduction.cpp.

References AddClamped().

Referenced by AddClamped(), and EnergiesAfter().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ AddToRow()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::AddToRow ( std::vector< RowEntry > & row,
uint32_t neighbor,
FxU128 coefficient )

Definition at line 172 of file implicit_conduction.cpp.

References AddToRow(), and WideAdd().

Referenced by AddToRow(), and Coarsen().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ApplyFlows()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::ApplyFlows ( ImplicitGrid & grid,
const std::vector< int64_t > & flows )

Definition at line 404 of file implicit_conduction.cpp.

References ApplyFlows(), bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, bicameral::sim::ImplicitCell::coarseFraction, bicameral::sim::ImplicitCell::energy, bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, bicameral::sim::ImplicitCell::fraction, and bicameral::sim::ImplicitFace::gap.

Referenced by ApplyFlows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Coarsen()

ImplicitGridLevel bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Coarsen ( ImplicitGridLevel & fine,
bool galerkin )

◆ Converged()

bool bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Converged ( const ImplicitGridLevel & cells,
const std::vector< int64_t > & rhs,
const std::vector< int64_t > & values,
uint32_t toleranceMillikelvin,
ImplicitCost & cost )

Definition at line 367 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitCost::cellUpdates, Converged(), bicameral::sim::ImplicitCost::passes, Relax(), and bicameral::sim::ImplicitGridLevel::selfWeights.

Referenced by Converged().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ EnergiesAfter()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::EnergiesAfter ( const ImplicitGrid & grid,
const std::vector< int64_t > & flows )

Definition at line 475 of file implicit_conduction.cpp.

References AddClamped(), bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, EnergiesAfter(), ENERGY_BITS_PER_LEVEL, bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, bicameral::sim::ImplicitFace::gap, and ShiftRightSigned().

Referenced by EnergiesAfter(), and LimitFlows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ExplicitFlows()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::ExplicitFlows ( const ImplicitGrid & grid,
const std::vector< int64_t > & start )

Definition at line 437 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, bicameral::sim::ImplicitFace::coefficient, ExplicitFlows(), FaceFlow(), bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, and bicameral::sim::ImplicitFace::gap.

Referenced by ExplicitFlows(), and LimitFlows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FaceCoefficient()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FaceCoefficient ( const ImplicitCell & fine,
const ImplicitCell & coarse )

Definition at line 133 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitCell::conductance, FaceCoefficient(), bicameral::sim::ImplicitCell::level, Wide(), and WideShiftLeft().

Referenced by FaceCoefficient(), and FindFaces().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FaceFlow()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FaceFlow ( FxU128 coefficient,
int64_t difference )

Definition at line 98 of file implicit_conduction.cpp.

References FaceFlow().

Referenced by ExplicitFlows(), FaceFlow(), and Flows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FindContaining()

std::optional< Containing > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FindContaining ( const std::map< CellKey, uint32_t > & index,
int32_t level,
int64_t x,
int64_t y,
int64_t z )

Definition at line 122 of file implicit_conduction.cpp.

References FindContaining().

Referenced by FindContaining(), and FindFaces().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FindFaces()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FindFaces ( ImplicitGrid & grid)

Definition at line 139 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, FACE_OFFSETS, FaceCoefficient(), bicameral::sim::ImplicitGrid::faces, FindContaining(), FindFaces(), bicameral::sim::ImplicitCell::level, MakeCellIndex(), bicameral::sim::ImplicitCell::x, bicameral::sim::ImplicitCell::y, and bicameral::sim::ImplicitCell::z.

Referenced by FindFaces().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FinishLevel()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FinishLevel ( ImplicitGridLevel & level,
const Rows & rows )

Definition at line 195 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGridLevel::capacities, bicameral::sim::ImplicitGridLevel::coefficients, bicameral::sim::ImplicitGridLevel::diagonals, FinishLevel(), bicameral::sim::ImplicitGridLevel::neighbors, bicameral::sim::ImplicitGridLevel::rowStarts, bicameral::sim::ImplicitGridLevel::selfWeights, Weight(), bicameral::sim::ImplicitGridLevel::weights, and WideAdd().

Referenced by Coarsen(), FinishLevel(), and MakeCellLevel().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Flows()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Flows ( const ImplicitGrid & grid,
const std::vector< int64_t > & temperatures )

Definition at line 393 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitFace::coarse, bicameral::sim::ImplicitFace::coefficient, FaceFlow(), bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, and Flows().

Referenced by Flows(), and Rkl2Flows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsZero()

bool bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::IsZero ( FxU128 value)

Definition at line 51 of file implicit_conduction.cpp.

References IsZero().

Referenced by IsZero(), and WideShiftLeft().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LimitFlows()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::LimitFlows ( const ImplicitGrid & grid,
const std::vector< int64_t > & start,
int64_t slackMillikelvin,
std::vector< int64_t > & flows,
ImplicitCost & cost )

Definition at line 517 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, EnergiesAfter(), ExplicitFlows(), bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, LimitFlows(), bicameral::sim::ImplicitCost::limitRounds, MakeBounds(), MarkOutside(), and bicameral::sim::ImplicitCost::passes.

Referenced by LimitFlows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MakeBounds()

Bounds bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MakeBounds ( const ImplicitGrid & grid,
const std::vector< int64_t > & start,
int64_t slackMillikelvin )

Definition at line 456 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::highest, bicameral::sim::ImplicitEnergyFor(), bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::lowest, MakeBounds(), bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::slack, and TEMPERATURE_SHIFT.

Referenced by LimitFlows(), and MakeBounds().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MakeCellIndex()

std::map< CellKey, uint32_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MakeCellIndex ( const std::vector< ImplicitCell > & cells)

Definition at line 104 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitCell::heatCapacity, bicameral::sim::ImplicitCell::level, MakeCellIndex(), bicameral::sim::ImplicitCell::x, bicameral::sim::ImplicitCell::y, and bicameral::sim::ImplicitCell::z.

Referenced by FindFaces(), and MakeCellIndex().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MakeCellLevel()

ImplicitGridLevel bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MakeCellLevel ( const ImplicitGrid & grid)

Definition at line 218 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, bicameral::sim::ImplicitFace::coefficient, ENERGY_BITS_PER_LEVEL, bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, FinishLevel(), bicameral::sim::ImplicitFace::gap, bicameral::sim::ImplicitCell::heatCapacity, bicameral::sim::ImplicitCell::level, MakeCellLevel(), PushNode(), Wide(), WideShiftRight(), bicameral::sim::ImplicitCell::x, bicameral::sim::ImplicitCell::y, and bicameral::sim::ImplicitCell::z.

Referenced by MakeCellLevel().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MarkOutside()

bool bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MarkOutside ( const ImplicitGrid & grid,
const Bounds & bounds,
const std::vector< int64_t > & energies,
std::vector< uint8_t > & limited,
ImplicitCost & cost )

Definition at line 496 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitCost::limitedCells, bicameral::sim::ImplicitCost::limitRounds, MarkOutside(), Overrun(), bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::slack, and bicameral::sim::ImplicitCost::worstExcessMillikelvin.

Referenced by LimitFlows(), and MarkOutside().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MulWeight()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MulWeight ( int64_t weight,
int64_t value )

Definition at line 638 of file implicit_conduction.cpp.

References MulWeight(), and WEIGHT_SHIFT.

Referenced by MulWeight(), and Rkl2Flows().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ NeedsCoarser()

bool bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::NeedsCoarser ( const ImplicitGridLevel & level)

Definition at line 236 of file implicit_conduction.cpp.

References NeedsCoarser(), and bicameral::sim::ImplicitGridLevel::selfWeights.

Referenced by NeedsCoarser().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Overrun()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Overrun ( int64_t energy,
const Bounds & bounds,
size_t i )

Definition at line 491 of file implicit_conduction.cpp.

References bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::highest, bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Bounds::lowest, and Overrun().

Referenced by MarkOutside(), and Overrun().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PushNode()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::PushNode ( ImplicitGridLevel & level,
const CellKey & key,
FxU128 capacity )

Definition at line 184 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGridLevel::capacities, bicameral::sim::ImplicitGridLevel::colors, bicameral::sim::ImplicitGridLevel::levels, PushNode(), bicameral::sim::ImplicitGridLevel::x, bicameral::sim::ImplicitGridLevel::y, and bicameral::sim::ImplicitGridLevel::z.

Referenced by Coarsen(), MakeCellLevel(), and PushNode().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RationalWeight()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::RationalWeight ( FxU128 numerator,
FxU128 denominator,
bool negative )

Definition at line 566 of file implicit_conduction.cpp.

References RationalWeight(), and Weight().

Referenced by RationalWeight(), and Rkl2Stages().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Relax()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Relax ( const ImplicitGridLevel & level,
const std::vector< int64_t > & rhs,
const std::vector< int64_t > & values,
size_t node )

Definition at line 297 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGridLevel::neighbors, Relax(), bicameral::sim::ImplicitGridLevel::rowStarts, WEIGHT_SHIFT, and bicameral::sim::ImplicitGridLevel::weights.

Referenced by Converged(), Relax(), SweepColor(), and VCycle().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Rkl2B()

Rational bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Rkl2B ( uint64_t j)

Definition at line 552 of file implicit_conduction.cpp.

References Rkl2B().

Referenced by Rkl2B(), and Rkl2Stages().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Rkl2Flows()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Rkl2Flows ( const ImplicitGrid & grid,
const std::vector< int64_t > & start,
ImplicitCost & cost )

◆ Rkl2StageCount()

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Rkl2StageCount ( const ImplicitGridLevel & cells)

Definition at line 600 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGridLevel::capacities, bicameral::sim::ImplicitGridLevel::coefficients, Rkl2StageCount(), bicameral::sim::ImplicitGridLevel::rowStarts, STAGE_RATIO_SHIFT, Wide(), and WideAdd().

Referenced by Rkl2Flows(), and Rkl2StageCount().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Rkl2Stages()

std::vector< Rkl2Stage > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Rkl2Stages ( uint32_t stageCount)

◆ ShiftRightSigned()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::ShiftRightSigned ( int64_t value,
uint32_t shift )

Definition at line 94 of file implicit_conduction.cpp.

References ShiftRightSigned().

Referenced by EnergiesAfter(), ShiftRightSigned(), and StageTemperatures().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Smooth()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Smooth ( const ImplicitGridLevel & level,
const std::vector< int64_t > & rhs,
std::vector< int64_t > & values,
uint32_t sweeps,
ImplicitCost & cost )

Definition at line 321 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitCost::cellUpdates, COLOR_COUNT, bicameral::sim::ImplicitCost::passes, Smooth(), and SweepColor().

Referenced by Smooth(), and VCycle().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ StageTemperatures()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::StageTemperatures ( const ImplicitGrid & grid,
const std::vector< int64_t > & start,
const std::vector< int64_t > & accumulated )

Definition at line 618 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitFace::coarse, ENERGY_BITS_PER_LEVEL, bicameral::sim::ImplicitGrid::faces, bicameral::sim::ImplicitFace::fine, bicameral::sim::ImplicitFace::gap, ShiftRightSigned(), StageTemperatures(), and TEMPERATURE_SHIFT.

Referenced by Rkl2Flows(), and StageTemperatures().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SweepColor()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::SweepColor ( const ImplicitGridLevel & level,
const std::vector< int64_t > & rhs,
uint8_t color,
std::vector< int64_t > & values,
std::vector< int64_t > & next )

Definition at line 307 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGridLevel::colors, Relax(), and SweepColor().

Referenced by Smooth(), and SweepColor().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Temperatures()

std::vector< int64_t > bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Temperatures ( const ImplicitGrid & grid)

Definition at line 384 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitGrid::cells, bicameral::sim::ImplicitTemperature(), and Temperatures().

Referenced by Temperatures().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ VCycle()

void bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::VCycle ( const ImplicitGrid & grid,
size_t depth,
const std::vector< int64_t > & rhs,
std::vector< int64_t > & values,
const ImplicitOptions & options,
ImplicitCost & cost )

Definition at line 333 of file implicit_conduction.cpp.

References bicameral::sim::ImplicitCost::cellUpdates, bicameral::sim::ImplicitOptions::coarsestSweeps, CORRECTION_SCALE_SHIFT, bicameral::sim::ImplicitOptions::correctionScale, bicameral::sim::ImplicitGrid::levels, bicameral::sim::ImplicitGridLevel::levels, bicameral::sim::ImplicitGridLevel::parents, bicameral::sim::ImplicitCost::passes, bicameral::sim::ImplicitOptions::postSmooth, bicameral::sim::ImplicitOptions::preSmooth, Relax(), bicameral::sim::ImplicitGridLevel::restrictWeights, Smooth(), VCycle(), and WEIGHT_SHIFT.

Referenced by VCycle().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Weight()

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Weight ( FxU128 numerator,
FxU128 denominator )

Definition at line 90 of file implicit_conduction.cpp.

References Weight().

Referenced by Coarsen(), FinishLevel(), RationalWeight(), and Weight().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Wide()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::Wide ( uint64_t value)

Definition at line 47 of file implicit_conduction.cpp.

References Wide().

Referenced by Coarsen(), FaceCoefficient(), MakeCellLevel(), Rkl2StageCount(), Rkl2Stages(), and Wide().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WideAdd()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::WideAdd ( FxU128 a,
FxU128 b )

Definition at line 55 of file implicit_conduction.cpp.

References WideAdd().

Referenced by AddToRow(), Coarsen(), FinishLevel(), Rkl2StageCount(), and WideAdd().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WideMul()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::WideMul ( FxU128 a,
uint64_t b )

Definition at line 79 of file implicit_conduction.cpp.

References WideMul().

Referenced by Rkl2Stages(), and WideMul().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WideShiftLeft()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::WideShiftLeft ( FxU128 value,
uint32_t shift )

Definition at line 64 of file implicit_conduction.cpp.

References IsZero(), and WideShiftLeft().

Referenced by FaceCoefficient(), and WideShiftLeft().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WideShiftRight()

FxU128 bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::WideShiftRight ( FxU128 value,
uint32_t shift )

Definition at line 59 of file implicit_conduction.cpp.

References WideShiftRight().

Referenced by Coarsen(), MakeCellLevel(), and WideShiftRight().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ COLOR_COUNT

uint8_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::COLOR_COUNT = 2
constexpr

Definition at line 37 of file implicit_conduction.cpp.

Referenced by Smooth().

◆ CORRECTION_SCALE_SHIFT

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::CORRECTION_SCALE_SHIFT = IM_CORRECTION_SCALE_SHIFT
constexpr

Definition at line 38 of file implicit_conduction.cpp.

Referenced by VCycle().

◆ ENERGY_BITS_PER_LEVEL

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::ENERGY_BITS_PER_LEVEL = IM_ENERGY_BITS_PER_LEVEL
constexpr

Definition at line 34 of file implicit_conduction.cpp.

Referenced by Coarsen(), EnergiesAfter(), MakeCellLevel(), and StageTemperatures().

◆ FACE_OFFSETS

std::array<std::array<int64_t, 3>, 6> bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::FACE_OFFSETS
constexpr
Initial value:
= {
{{1, 0, 0}, {-1, 0, 0}, {0, 1, 0}, {0, -1, 0}, {0, 0, 1}, {0, 0, -1}}}

Definition at line 40 of file implicit_conduction.cpp.

Referenced by FindFaces().

◆ HALF_WEIGHT

int64_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::HALF_WEIGHT = int64_t{1} << (WEIGHT_SHIFT - 1)
constexpr

Definition at line 33 of file implicit_conduction.cpp.

◆ MAX_GRID_LEVELS

size_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::MAX_GRID_LEVELS = 64
constexpr

Definition at line 36 of file implicit_conduction.cpp.

◆ STAGE_RATIO_SHIFT

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::STAGE_RATIO_SHIFT = 16
constexpr

Definition at line 35 of file implicit_conduction.cpp.

Referenced by Rkl2StageCount().

◆ TEMPERATURE_SHIFT

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::TEMPERATURE_SHIFT = IM_TEMPERATURE_SHIFT
constexpr

Definition at line 32 of file implicit_conduction.cpp.

Referenced by MakeBounds(), and StageTemperatures().

◆ WEIGHT_SHIFT

uint32_t bicameral::sim::anonymous_namespace{implicit_conduction.cpp}::WEIGHT_SHIFT = IM_WEIGHT_SHIFT
constexpr

Definition at line 31 of file implicit_conduction.cpp.

Referenced by MulWeight(), Relax(), and VCycle().