|
PICurv 0.1.0
A Parallel Particle-In-Cell Solver for Curvilinear LES
|
Go to the source code of this file.
Macros | |
| #define | __FUNCT__ "CanRankServiceInletFace" |
| #define | __FUNCT__ "CanRankServiceFace" |
| #define | __FUNCT__ "GetDeterministicFaceGridLocation" |
| #define | __FUNCT__ "GetRandomFCellAndLogicOnInletFace" |
| #define | __FUNCT__ "EnforceRHSBoundaryConditions" |
| #define | __FUNCT__ "BoundaryCondition_Create" |
| #define | __FUNCT__ "BoundarySystem_Validate" |
| #define | __FUNCT__ "BoundarySystem_Initialize" |
| #define | __FUNCT__ "PropagateBoundaryConfigToCoarserLevels" |
| #define | __FUNCT__ "BoundarySystem_ExecuteStep" |
| #define | __FUNCT__ "BoundarySystem_RefreshUbcs" |
| #define | __FUNCT__ "BoundarySystem_Destroy" |
| #define | __FUNCT__ "TransferPeriodicFieldByDirection" |
| #define | __FUNCT__ "TransferPeriodicField" |
| #define | __FUNCT__ "TransferPeriodicFaceField" |
| #define | __FUNCT__ "ApplyMetricsPeriodicBCs" |
| #define | __FUNCT__ "ApplyPeriodicBCs" |
| #define | __FUNCT__ "ApplyUcontPeriodicBCs" |
| #define | __FUNCT__ "EnforceUcontPeriodicity" |
| #define | __FUNCT__ "UpdateDummyCells" |
| #define | __FUNCT__ "UpdateCornerNodes" |
| #define | __FUNCT__ "UpdatePeriodicCornerNodes" |
| #define | __FUNCT__ "ApplyWallFunction" |
| #define | __FUNCT__ "RefreshBoundaryGhostCells" |
| #define | __FUNCT__ "ApplyBoundaryConditions" |
Functions | |
| PetscErrorCode | CanRankServiceInletFace (UserCtx *user, const DMDALocalInfo *info, PetscInt IM_nodes_global, PetscInt JM_nodes_global, PetscInt KM_nodes_global, PetscBool *can_service_inlet_out) |
Internal helper implementation: CanRankServiceInletFace(). | |
| PetscErrorCode | CanRankServiceFace (const DMDALocalInfo *info, PetscInt IM_nodes_global, PetscInt JM_nodes_global, PetscInt KM_nodes_global, BCFace face_id, PetscBool *can_service_out) |
| Implementation of CanRankServiceFace(). | |
| PetscErrorCode | GetDeterministicFaceGridLocation (UserCtx *user, const DMDALocalInfo *info, PetscInt xs_gnode_rank, PetscInt ys_gnode_rank, PetscInt zs_gnode_rank, PetscInt IM_cells_global, PetscInt JM_cells_global, PetscInt KM_cells_global, PetscInt64 particle_global_id, PetscInt *ci_metric_lnode_out, PetscInt *cj_metric_lnode_out, PetscInt *ck_metric_lnode_out, PetscReal *xi_metric_logic_out, PetscReal *eta_metric_logic_out, PetscReal *zta_metric_logic_out, PetscBool *placement_successful_out) |
Internal helper implementation: GetDeterministicFaceGridLocation(). | |
| PetscErrorCode | GetRandomCellAndLogicalCoordsOnInletFace (UserCtx *user, const DMDALocalInfo *info, PetscInt xs_gnode_rank, PetscInt ys_gnode_rank, PetscInt zs_gnode_rank, PetscInt IM_nodes_global, PetscInt JM_nodes_global, PetscInt KM_nodes_global, PetscRandom *rand_logic_i_ptr, PetscRandom *rand_logic_j_ptr, PetscRandom *rand_logic_k_ptr, PetscInt *ci_metric_lnode_out, PetscInt *cj_metric_lnode_out, PetscInt *ck_metric_lnode_out, PetscReal *xi_metric_logic_out, PetscReal *eta_metric_logic_out, PetscReal *zta_metric_logic_out) |
Internal helper implementation: GetRandomCellAndLogicalCoordsOnInletFace(). | |
| PetscErrorCode | EnforceRHSBoundaryConditions (UserCtx *user) |
Internal helper implementation: EnforceRHSBoundaryConditions(). | |
| PetscErrorCode | BoundaryCondition_Create (BCHandlerType handler_type, BoundaryCondition **new_bc_ptr) |
Internal helper implementation: BoundaryCondition_Create(). | |
| PetscErrorCode | BoundarySystem_Validate (UserCtx *user) |
Internal helper implementation: BoundarySystem_Validate(). | |
| PetscErrorCode | BoundarySystem_Initialize (UserCtx *user, const char *bcs_filename) |
| Implementation of BoundarySystem_Initialize(). | |
| PetscErrorCode | PropagateBoundaryConfigToCoarserLevels (SimCtx *simCtx) |
Internal helper implementation: PropagateBoundaryConfigToCoarserLevels(). | |
| PetscErrorCode | BoundarySystem_ExecuteStep (UserCtx *user) |
| Implementation of BoundarySystem_ExecuteStep(). | |
| PetscErrorCode | BoundarySystem_RefreshUbcs (UserCtx *user) |
Internal helper implementation: BoundarySystem_RefreshUbcs(). | |
| PetscErrorCode | BoundarySystem_Destroy (UserCtx *user) |
| Implementation of BoundarySystem_Destroy(). | |
| PetscErrorCode | TransferPeriodicFieldByDirection (UserCtx *user, const char *field_name, char direction) |
Internal helper implementation: TransferPeriodicFieldByDirection(). | |
| PetscErrorCode | TransferPeriodicField (UserCtx *user, const char *field_name) |
Internal helper implementation: TransferPeriodicField(). | |
| PetscErrorCode | TransferPeriodicFaceField (UserCtx *user, const char *field_name) |
Internal helper implementation: TransferPeriodicFaceField(). | |
| PetscErrorCode | ApplyMetricsPeriodicBCs (UserCtx *user) |
Internal helper implementation: ApplyMetricsPeriodicBCs(). | |
| PetscErrorCode | ApplyPeriodicBCs (UserCtx *user) |
Internal helper implementation: ApplyPeriodicBCs(). | |
| PetscErrorCode | ApplyUcontPeriodicBCs (UserCtx *user) |
| Implementation of ApplyUcontPeriodicBCs(). | |
| PetscErrorCode | EnforceUcontPeriodicity (UserCtx *user) |
Internal helper implementation: EnforceUcontPeriodicity(). | |
| PetscErrorCode | UpdateDummyCells (UserCtx *user) |
Internal helper implementation: UpdateDummyCells(). | |
| PetscErrorCode | UpdateCornerNodes (UserCtx *user) |
Internal helper implementation: UpdateCornerNodes(). | |
| PetscErrorCode | UpdatePeriodicCornerNodes (UserCtx *user, PetscInt num_fields, const char *field_names[]) |
Internal helper implementation: UpdatePeriodicCornerNodes(). | |
| PetscErrorCode | ApplyWallFunction (UserCtx *user) |
Internal helper implementation: ApplyWallFunction(). | |
| PetscErrorCode | RefreshBoundaryGhostCells (UserCtx *user) |
Internal helper implementation: RefreshBoundaryGhostCells(). | |
| PetscErrorCode | ApplyBoundaryConditions (UserCtx *user) |
| Implementation of ApplyBoundaryConditions(). | |
| #define __FUNCT__ "CanRankServiceInletFace" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "CanRankServiceFace" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "GetDeterministicFaceGridLocation" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "GetRandomFCellAndLogicOnInletFace" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "EnforceRHSBoundaryConditions" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundaryCondition_Create" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundarySystem_Validate" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundarySystem_Initialize" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "PropagateBoundaryConfigToCoarserLevels" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundarySystem_ExecuteStep" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundarySystem_RefreshUbcs" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "BoundarySystem_Destroy" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "TransferPeriodicFieldByDirection" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "TransferPeriodicField" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "TransferPeriodicFaceField" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "ApplyMetricsPeriodicBCs" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "ApplyPeriodicBCs" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "ApplyUcontPeriodicBCs" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "EnforceUcontPeriodicity" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "UpdateDummyCells" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "UpdateCornerNodes" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "UpdatePeriodicCornerNodes" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "ApplyWallFunction" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "RefreshBoundaryGhostCells" |
Definition at line 6 of file Boundaries.c.
| #define __FUNCT__ "ApplyBoundaryConditions" |
Definition at line 6 of file Boundaries.c.
| PetscErrorCode CanRankServiceInletFace | ( | UserCtx * | user, |
| const DMDALocalInfo * | info, | ||
| PetscInt | IM_nodes_global, | ||
| PetscInt | JM_nodes_global, | ||
| PetscInt | KM_nodes_global, | ||
| PetscBool * | can_service_inlet_out | ||
| ) |
Internal helper implementation: CanRankServiceInletFace().
Determines if the current MPI rank owns any part of the globally defined inlet face, making it responsible for placing particles on that portion of the surface.
Local to this translation unit.
Definition at line 11 of file Boundaries.c.
| PetscErrorCode CanRankServiceFace | ( | const DMDALocalInfo * | info, |
| PetscInt | IM_nodes_global, | ||
| PetscInt | JM_nodes_global, | ||
| PetscInt | KM_nodes_global, | ||
| BCFace | face_id, | ||
| PetscBool * | can_service_out | ||
| ) |
Implementation of CanRankServiceFace().
Determines if the current MPI rank owns any part of a specified global face.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 126 of file Boundaries.c.
| PetscErrorCode GetDeterministicFaceGridLocation | ( | UserCtx * | user, |
| const DMDALocalInfo * | info, | ||
| PetscInt | xs_gnode_rank, | ||
| PetscInt | ys_gnode_rank, | ||
| PetscInt | zs_gnode_rank, | ||
| PetscInt | IM_cells_global, | ||
| PetscInt | JM_cells_global, | ||
| PetscInt | KM_cells_global, | ||
| PetscInt64 | particle_global_id, | ||
| PetscInt * | ci_metric_lnode_out, | ||
| PetscInt * | cj_metric_lnode_out, | ||
| PetscInt * | ck_metric_lnode_out, | ||
| PetscReal * | xi_metric_logic_out, | ||
| PetscReal * | eta_metric_logic_out, | ||
| PetscReal * | zta_metric_logic_out, | ||
| PetscBool * | placement_successful_out | ||
| ) |
Internal helper implementation: GetDeterministicFaceGridLocation().
Places particles in a deterministic grid/raster pattern on a specified domain face.
Local to this translation unit.
Definition at line 212 of file Boundaries.c.
| PetscErrorCode GetRandomCellAndLogicalCoordsOnInletFace | ( | UserCtx * | user, |
| const DMDALocalInfo * | info, | ||
| PetscInt | xs_gnode_rank, | ||
| PetscInt | ys_gnode_rank, | ||
| PetscInt | zs_gnode_rank, | ||
| PetscInt | IM_nodes_global, | ||
| PetscInt | JM_nodes_global, | ||
| PetscInt | KM_nodes_global, | ||
| PetscRandom * | rand_logic_i_ptr, | ||
| PetscRandom * | rand_logic_j_ptr, | ||
| PetscRandom * | rand_logic_k_ptr, | ||
| PetscInt * | ci_metric_lnode_out, | ||
| PetscInt * | cj_metric_lnode_out, | ||
| PetscInt * | ck_metric_lnode_out, | ||
| PetscReal * | xi_metric_logic_out, | ||
| PetscReal * | eta_metric_logic_out, | ||
| PetscReal * | zta_metric_logic_out | ||
| ) |
Internal helper implementation: GetRandomCellAndLogicalCoordsOnInletFace().
Assuming the current rank services the inlet face, this function selects a random cell (owned by this rank on that face) and random logical coordinates within that cell, suitable for placing a particle on the inlet surface.
Local to this translation unit.
Definition at line 399 of file Boundaries.c.
| PetscErrorCode EnforceRHSBoundaryConditions | ( | UserCtx * | user | ) |
Internal helper implementation: EnforceRHSBoundaryConditions().
Enforces boundary conditions on the momentum equation's Right-Hand-Side (RHS) vector.
Local to this translation unit.
Definition at line 591 of file Boundaries.c.
| PetscErrorCode BoundaryCondition_Create | ( | BCHandlerType | handler_type, |
| BoundaryCondition ** | new_bc_ptr | ||
| ) |
Internal helper implementation: BoundaryCondition_Create().
(Private) Creates and configures a specific BoundaryCondition handler object.
Local to this translation unit.
Definition at line 744 of file Boundaries.c.
| PetscErrorCode BoundarySystem_Validate | ( | UserCtx * | user | ) |
Internal helper implementation: BoundarySystem_Validate().
(Public) Validates the consistency and compatibility of the parsed boundary condition system.
Local to this translation unit.
Definition at line 825 of file Boundaries.c.
| PetscErrorCode BoundarySystem_Initialize | ( | UserCtx * | user, |
| const char * | bcs_filename | ||
| ) |
Implementation of BoundarySystem_Initialize().
Initializes the entire boundary system.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 857 of file Boundaries.c.
| PetscErrorCode PropagateBoundaryConfigToCoarserLevels | ( | SimCtx * | simCtx | ) |
Internal helper implementation: PropagateBoundaryConfigToCoarserLevels().
Propagates boundary condition configuration from finest to all coarser multigrid levels.
Local to this translation unit.
Definition at line 982 of file Boundaries.c.
| PetscErrorCode BoundarySystem_ExecuteStep | ( | UserCtx * | user | ) |
Implementation of BoundarySystem_ExecuteStep().
Executes one full boundary condition update cycle for a time step.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 1053 of file Boundaries.c.
| PetscErrorCode BoundarySystem_RefreshUbcs | ( | UserCtx * | user | ) |
Internal helper implementation: BoundarySystem_RefreshUbcs().
(Private) A lightweight execution engine that calls the UpdateUbcs() method on all relevant handlers.
Local to this translation unit.
Definition at line 1475 of file Boundaries.c.
| PetscErrorCode BoundarySystem_Destroy | ( | UserCtx * | user | ) |
Implementation of BoundarySystem_Destroy().
Cleans up and destroys all boundary system resources.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 1525 of file Boundaries.c.
| PetscErrorCode TransferPeriodicFieldByDirection | ( | UserCtx * | user, |
| const char * | field_name, | ||
| char | direction | ||
| ) |
Internal helper implementation: TransferPeriodicFieldByDirection().
(Private Worker) Copies periodic data for a SINGLE field in a SINGLE direction.
Local to this translation unit.
Definition at line 1572 of file Boundaries.c.
| PetscErrorCode TransferPeriodicField | ( | UserCtx * | user, |
| const char * | field_name | ||
| ) |
Internal helper implementation: TransferPeriodicField().
(Orchestrator) Applies periodic transfer for one field across all i/j/k directions.
Local to this translation unit.
Definition at line 1656 of file Boundaries.c.
| PetscErrorCode TransferPeriodicFaceField | ( | UserCtx * | user, |
| const char * | field_name | ||
| ) |
Internal helper implementation: TransferPeriodicFaceField().
(Primitive) Copies periodic data from the interior to the local ghost cell region for a single field.
Local to this translation unit.
Definition at line 1759 of file Boundaries.c.
| PetscErrorCode ApplyMetricsPeriodicBCs | ( | UserCtx * | user | ) |
Internal helper implementation: ApplyMetricsPeriodicBCs().
(Orchestrator) Updates all metric-related fields in the local ghost cell regions for periodic boundaries.
Local to this translation unit.
Definition at line 1895 of file Boundaries.c.
| PetscErrorCode ApplyPeriodicBCs | ( | UserCtx * | user | ) |
Internal helper implementation: ApplyPeriodicBCs().
Applies periodic boundary conditions by copying data across domain boundaries for all relevant fields.
Local to this translation unit.
Definition at line 1922 of file Boundaries.c.
| PetscErrorCode ApplyUcontPeriodicBCs | ( | UserCtx * | user | ) |
Implementation of ApplyUcontPeriodicBCs().
(Orchestrator) Updates the contravariant velocity field in the local ghost cell regions for periodic boundaries.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 1983 of file Boundaries.c.
| PetscErrorCode EnforceUcontPeriodicity | ( | UserCtx * | user | ) |
Internal helper implementation: EnforceUcontPeriodicity().
Enforces strict periodicity on the interior contravariant velocity field.
Local to this translation unit.
Definition at line 2007 of file Boundaries.c.
| PetscErrorCode UpdateDummyCells | ( | UserCtx * | user | ) |
Internal helper implementation: UpdateDummyCells().
Updates the dummy cells (ghost nodes) on the faces of the local domain for NON-PERIODIC boundaries.
Local to this translation unit.
Definition at line 2059 of file Boundaries.c.
| PetscErrorCode UpdateCornerNodes | ( | UserCtx * | user | ) |
Internal helper implementation: UpdateCornerNodes().
Updates the corner and edge ghost nodes of the local domain by averaging.
Local to this translation unit.
Definition at line 2151 of file Boundaries.c.
| PetscErrorCode UpdatePeriodicCornerNodes | ( | UserCtx * | user, |
| PetscInt | num_fields, | ||
| const char * | field_names[] | ||
| ) |
Internal helper implementation: UpdatePeriodicCornerNodes().
(Orchestrator) Performs a sequential, deterministic periodic update for a list of fields.
Local to this translation unit.
Definition at line 2295 of file Boundaries.c.
| PetscErrorCode ApplyWallFunction | ( | UserCtx * | user | ) |
Internal helper implementation: ApplyWallFunction().
Applies wall function modeling to near-wall velocities for all wall-type boundaries.
Local to this translation unit.
Definition at line 2338 of file Boundaries.c.
| PetscErrorCode RefreshBoundaryGhostCells | ( | UserCtx * | user | ) |
Internal helper implementation: RefreshBoundaryGhostCells().
(Public) Orchestrates the "light" refresh of all boundary ghost cells after the projection step.
Local to this translation unit.
Definition at line 2797 of file Boundaries.c.
| PetscErrorCode ApplyBoundaryConditions | ( | UserCtx * | user | ) |
Implementation of ApplyBoundaryConditions().
Main boundary-condition orchestrator executed during solver timestepping.
Full API contract (arguments, ownership, side effects) is documented with the header declaration in include/Boundaries.h.
Definition at line 2862 of file Boundaries.c.