flow 1.4.0
Kokkos cut-cell IBM incompressible Navier-Stokes solver + pnm pore extraction
Loading...
Searching...
No Matches
test_ca_odd_periodic_mpi.cpp File Reference
#include <mpi.h>
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <Kokkos_Core.hpp>
#include <string>
#include <type_traits>
#include <vector>
#include "flow_ibm.hpp"
#include "mac_cutcell_mg.hpp"
#include "peclet/core/common/types.hpp"
#include "peclet/core/decomp/block_decomposer.hpp"

Go to the source code of this file.

Classes

struct  Diff
struct  Fields

Typedefs

using CCConst
using CCField
using IbmSolver

Functions

static void check (bool ok, const std::string &what)
static Diff compareBlock (const std::vector< double > &a, const std::vector< double > &ref, int ox, int oy, int oz, int lnx, int lny, int lnz)
static bool sameBits (const std::vector< double > &a, const std::vector< double > &b)
static std::string fmt (const char *f, double a, long b=0)
static double source (int gx, int gy, int gz)
static std::vector< double > mgSolve (CutcellMG &mg)
static void mgChecks ()
static std::vector< double > sphereSdf ()
static void configure (IbmSolver &s)
static Fields fieldsOf (IbmSolver &s)
static void solverChecks ()
int main (int argc, char **argv)

Variables

static constexpr int NX = 32
static constexpr int NY = 32
static constexpr int NZ = 25
static int gRank = 0
static int gSize = 1
static int gFail = 0

Typedef Documentation

◆ CCConst

Definition at line 27 of file mac_cutcell.hpp.

◆ CCField

Definition at line 26 of file mac_cutcell.hpp.

◆ IbmSolver

Definition at line 5663 of file flow_ibm.hpp.

Function Documentation

◆ check()

void check ( bool ok,
const std::string & what )
static

◆ compareBlock()

Diff compareBlock ( const std::vector< double > & a,
const std::vector< double > & ref,
int ox,
int oy,
int oz,
int lnx,
int lny,
int lnz )
static

Definition at line 56 of file test_ca_odd_periodic_mpi.cpp.

References NX, and NY.

Referenced by mgChecks(), and solverChecks().

◆ sameBits()

bool sameBits ( const std::vector< double > & a,
const std::vector< double > & b )
static

Definition at line 76 of file test_ca_odd_periodic_mpi.cpp.

Referenced by main(), mgChecks(), and solverChecks().

◆ fmt()

std::string fmt ( const char * f,
double a,
long b = 0 )
static

Definition at line 82 of file test_ca_odd_periodic_mpi.cpp.

Referenced by main(), mgChecks(), and solverChecks().

◆ source()

double source ( int gx,
int gy,
int gz )
static

Definition at line 90 of file test_ca_odd_periodic_mpi.cpp.

References NX, NY, and NZ.

Referenced by peclet::flow::bindings::bindSolverScalar(), and mgSolve().

◆ mgSolve()

◆ mgChecks()

◆ sphereSdf()

std::vector< double > sphereSdf ( )
static

Definition at line 168 of file test_ca_odd_periodic_mpi.cpp.

References NX, NY, NZ, and R.

Referenced by solverChecks().

◆ configure()

void configure ( IbmSolver & s)
static

Definition at line 187 of file test_ca_odd_periodic_mpi.cpp.

Referenced by solverChecks().

◆ fieldsOf()

Fields fieldsOf ( IbmSolver & s)
static

Definition at line 201 of file test_ca_odd_periodic_mpi.cpp.

Referenced by solverChecks().

◆ solverChecks()

◆ main()

int main ( int argc,
char ** argv )

Definition at line 281 of file test_ca_odd_periodic_mpi.cpp.

References gFail, gRank, gSize, mgChecks(), NX, NY, NZ, and solverChecks().

Variable Documentation

◆ NX

int NX = 32
staticconstexpr

Definition at line 38 of file test_ca_odd_periodic_mpi.cpp.

◆ NY

int NY = 32
static

Definition at line 38 of file test_ca_odd_periodic_mpi.cpp.

◆ NZ

int NZ = 25
static

Definition at line 38 of file test_ca_odd_periodic_mpi.cpp.

◆ gRank

int gRank = 0
static

Definition at line 39 of file test_ca_odd_periodic_mpi.cpp.

Referenced by check(), main(), and solverChecks().

◆ gSize

int gSize = 1
static

Definition at line 39 of file test_ca_odd_periodic_mpi.cpp.

Referenced by main(), mgChecks(), and solverChecks().

◆ gFail

int gFail = 0
static

Definition at line 39 of file test_ca_odd_periodic_mpi.cpp.

Referenced by check(), and main().