Color Model

class ScaLBL_ColorModel
#include <ColorModel.h>

The ScaLBL_ColorModel class contains routines to initialize and run a two-component color lattice Boltzmann model Momentum transport equations are described by a D3Q19 scheme Mass transport equations are described by D3Q7 scheme

Public Functions

void AssignComponentLabels(double *phase)

Assign wetting affinity values.

void Create()

Create color model data structures.

void getPhaseField(DoubleArray &f)

Copy the phase field for use by external methods.

Parameters

f – - DoubleArray to hold the phase field

void Initialize()

Initialize the simulation.

void ReadInput()

Read image data.

void ReadParams(string filename)

Read simulation parameters.

Parameters

filename – input database file that includes “Color” section

void ReadParams(std::shared_ptr<Database> db0)

Read simulation parameters.

Parameters

db0 – input database that includes “Color” section

void Run()

Run the simulation.

double Run(int returntime)

Run the simulation.

Parameters

returntime – - timestep at which the routine will return

ScaLBL_ColorModel(int RANK, int NP, const Utilities::MPI &COMM)

Constructor.

Parameters
  • RANK – processor rank

  • NP – number of processors

  • COMM – MPI communicator

void SetDomain()

Create domain data structures.

void WriteDebug()

Debugging function to dump simulation state to disk.

~ScaLBL_ColorModel()

Public Members

double alpha
std::shared_ptr<Database> analysis_db
double *Aq
std::shared_ptr<SubPhase> Averages
double beta
int BoundaryCondition
double *Bq
std::shared_ptr<Database> color_db
double *ColorGrad
std::shared_ptr<Database> db
double *Den
double din
std::shared_ptr<Domain> Dm
std::shared_ptr<Database> domain_db
double dout
int *dvcMap
double flux
double *fq
double Fx
double Fy
double Fz
signed char *id
double inletA
double inletB
double Lx
double Ly
double Lz
IntArray Map
std::shared_ptr<Domain> Mask
const double mDarcy_converter = 1013.0
int N
int *NeighborList
int Np
int nprocs
int nprocx
int nprocy
int nprocz
int Nx
int Ny
int Nz
double outletA
double outletB
bool pBC
double *Phi
double *Pressure
int rank
bool Restart
bool REVERSE_FLOW_DIRECTION
double rhoA
double rhoB
std::shared_ptr<ScaLBL_Communicator> ScaLBL_Comm
std::shared_ptr<ScaLBL_Communicator> ScaLBL_Comm_Regular
double tauA
double tauB
int timestep
int timestepMax
double *Velocity
std::shared_ptr<Database> vis_db

Private Functions

void LoadParams(std::shared_ptr<Database> db0)

Private Members

Utilities::MPI comm
int dist_mem_size
char LocalRankFilename[40]
char LocalRankString[8]
char LocalRestartFile[40]
int neighborSize