/*---------------------------------------------------------------------------*\
Constant property directory. Update as needed.
\*---------------------------------------------------------------------------*/

FoamFile {
  version     2.0;
  format      ascii;
  class       dictionary;
  location    "constant/porousMat/materialProperties";
  object      constantProperties;
}
// * * * * * *  Units * * * * * [kg m s K mol A cd] * * * * * * * * * * * * * //
// e.g. W: kg m^2 s^{-3} 	[1 2 -3 0 0 0 0]

/****		Universal constants						****/
R               R		[1 2 -2 -1 -1 0 0]	8.314471469;
sigmaPlanck     sigmaPlanck	[1 0 -3 -1 0 0 0]	5.6697e-8;

/*** 		MATERIAL PROPERTIES - GENERIC WOOD PROPERTIES LOOSELY BASED ON PINUS MASTER	***/
/***            Initial densities and volume fractions				***/
nSolidPhases	4;						// number of phases (index starts at 1)
rhoI[1]		rhoI[1]		[1 -3 0 0 0 0 0]	1500;	// intrinsic density of hemicellulose
epsI[1]		epsI[1]		[0 0 0 0 0 0 0]		0.090;	// volume fraction of hemicellulose
rhoI[2]		rhoI[2]		[1 -3 0 0 0 0 0]	1500;	// intrinsic density of cellulose
epsI[2]		epsI[2]		[0 0 0 0 0 0 0]		0.167;	// volume fraction of cellulose
rhoI[3]		rhoI[3]		[1 -3 0 0 0 0 0]	1500;	// intrinsic density of lignin
epsI[3]		epsI[3]		[0 0 0 0 0 0 0]		0.0767;	// volume fraction of lignin
rhoI[4]		rhoI[4]		[1 -3 0 0 0 0 0]	1000;	// intrinsic density of water
epsI[4]		epsI[4]		[0 0 0 0 0 0 0]		0.05;	// volume fraction of water

/***		Geometrical properties (for volAblation)  ***/
rf0		rf0		[0 1 0 0 0 0 0]		5e-6;	// initial fiber radius
rff		rff		[0 1 0 0 0 0 0]		1e-6;	// final fiber radius (only minerals left)
rfFail		rfFail		[0 1 0 0 0 0 0]		1e-6;	// failure fiber radius (erosion model)
fiberPhase	1;						// identify phase index to treat as fiber
matrixPhase	2;						// identify phase index to treat as matrix surrounding the fibers

/***		Averaged momentum-conservation related data (Darcy's law)	***/
K_v		K_v		[0 2 0 0 0 0 0]		(1e-12 0 0 0 1e-12 0 0 0 1e-12); // wood permeability (second order tensor)
K_c		K_c		[0 2 0 0 0 0 0]		(1e-11 0 0 0 1e-11 0 0 0 1e-11);       // char permeability (second order tensor)
Beta_v          Beta_v          [0 -1 0 0 0 0 0]        (5.5e5 0 0 0 5.5e5 0 0 0 5.5e5);       // wood Forchheimer coefficient (second order tensor)
Beta_c          Beta_c          [0 -1 0 0 0 0 0]        (1.7e5 0 0 0 1.7e5 0 0 0 1.7e5);       // char Forchheimer coefficient (second order tensor)
eps_g_v		eps_g_v		[0 0 0 0 0 0 0]		0.51;	// wood porosity
eps_g_c		eps_g_c		[0 0 0 0 0 0 0]		0.85;	// char porosity

/***		Convective heat exchange between solid and gas phases for 2 T model	***/
Hv0		Hv0		[1 -1 -3 -1 0 0 0]		3e5;	// heat transfer coefficient

/***		Mass transfer in porous media					***/
eta0		eta0		[0 0 0 0 0 0 0]		1.1;	// default tortuosity

/***		Anisotropic conductivity parameters: main directions and linear factors		***/
//   		kxyz = tP & kijk' & P
//   		where, kijk'		= 	(ki' 0  0
//						 0  kj' 0
//	 			 		 0  0  kk') (in direct orthonormal basis, i, j, k)
//
// 1- Express the main directions (ijk) of the diagonal conductivity matrix in the basis of the mesh (xyz)
//	     	The transposed conductivity passage matrix (tP) expresses (i,j,k) coordinates in the basis (x,y,z)
//		where (i,j,k) is a direct orthonormal basis of the diagonal conductivity matrix
//		and (x,y,z) is the direct orthonormal basis of the mesh (in case of doubt, mesh directions can be seen in paraview)
//							(i j k)			ex. rotation a (in radians) around axis z
tP		tP 		[0 0 0 0 0 0 0] 	(1 0 0 	 // x		(cosa -sina 0
                               0 1 0 	 // y		 sina  cosa 0
                               0 0 1); // z		 0     	 0  1)
// 2 - Linear factors
kiCoef		kiCoef 		[0 0 0 0 0 0 0] 	1;	 // to multiply column ki of the input files 'char' and 'virgin' by a linear factor: ki' = kiCoef*ki
kjCoef		kjCoef 		[0 0 0 0 0 0 0] 	1;	 // idem for kj
kkCoef		kkCoef 		[0 0 0 0 0 0 0] 	1;	 // idem for kk

// 3 - Polynomial coefficients
kCondVirgin 	0.2; //kCondVirgin 	[1 1 -3 -1 0 0 0]	0.2;
kCondChar 	0.4;
kRadVirgin      1.76e-10;
kRadChar        1.5e-10;


/***		Diffusion coefficient in binary diffusion mode - set it to 0 for no diffusion	  ***/
D0		D0		[0 2 -1 0 0 0 0]	0;

/***		Initial elemental composition of the gas phase inside the material and for B' balance (mole fractions) ***/
//		Usual practice is:
//		1- if 'elementConservation' is turned off, input the pyrolysis gas composition
//		2- if 'elementConservation' is turned on, input the same initial compostion as boundary layer edge
//		3- in 'finite-rate' mode:
//			 (3.1) we need to input species (not elements)
//			-> the initial concentrations need to be updated in the directory 0 - update O2, N2, and add species as needed
//			 (3.2) the values entered below are used for B' only.
//		Note: the list of elements comes from the mixture files that you have chosen
//		in thermophysicalProperties 'mixtureMutationBprime' and  'mixtureMutationEquilibrium'
//		Only the elements present in the mixture file are read here. Values not provided here default to 0.
//		All zero will make the code crash because it's not set up to run without gas.

// Average pyrolysis gas composition for wood
/*Zx[C] 	0.236;
Zx[H] 		0.413;
Zx[O]		0.301;
Zx[N]		0.05;*/

// Air
/*Zx[C] 	0.0;
Zx[H] 		0.0;
Zx[O]		0.21;
Zx[N]		0.79;*/

// Nitrogen
Zx[C] 		0.0;
Zx[H] 		0.0;
Zx[O]		0.0;
Zx[N]		1.0;


/****		Pyrolysis model			****/
// NB: zeta and gamma are expressed in mass fractions.
// Only the elements present in the mixture file are read here. Values not provided here default to 0.
// - zeta is used in equilibrium mode only, and when 'elementConservation' is selected.
//   If 'elementConservation' is not selected zeta[i][j] defaults to the initial elemental composition selected above.
// - gamma is used in finite-rate chemistry mode only
// NB:	- the stoechiometric factors (gamma) of the species present in the finite-rate chemistry mechanism are looked-up,
//		they default to gamma = 0 if the values are not found here.
//	- use correct notations/spelling or species won't be found (eg. A1 might be used instead of C6H6, check in chemistry file).

// Pyrolysis of phase 1 - Hemicellulose
nPyroReac[1] 	2; // number of pyrolysis reactions for phase[1]

// 		1 - Pyrolysis reaction 1
F[1][1]		F[1][1]		[0 0 0 0 0 0 0]		0.40;
A[1][1]		A[1][1]		[0 0 -1 0 0 0 0]	7.94e16;
E[1][1]		E[1][1]		[1 2 -2 0 -1 0 0]	195000;
m[1][1]		m[1][1]		[0 0 0 0 0 0 0]		1;
n[1][1]		n[1][1]		[0 0 0 0 0 0 0]		0;
T[1][1]		T[1][1]		[0 0 0 1 0 0 0]		2.0E+02;
h[1][1]		h[1][1]		[0 2 -2 0 0 0 0]	-1e5;

zeta[1][1][C]		0.236;  // zeta[solidPhase][pyroReac][element]
zeta[1][1][H]		0.413;
zeta[1][1][O]		0.301;
zeta[1][1][N]		0.05;


gamma[1][1][H2]		0.40;   // gamma[solidPhase][pyroReac][species]
gamma[1][1][CO]		0.40;
gamma[1][1][CO2]	0.10;
gamma[1][1][CH4]	0.05;
gamma[1][1][N2]		0.05;

// 		2 - Pyrolysis reaction 2
F[1][2]		F[1][2]		[0 0 0 0 0 0 0]		0.30;
A[1][2]		A[1][2]		[0 0 -1 0 0 0 0]	1.26e7;
E[1][2]		E[1][2]		[1 2 -2 0 -1 0 0]	96000;
m[1][2]		m[1][2]		[0 0 0 0 0 0 0]		1;
n[1][2]		n[1][2]		[0 0 0 0 0 0 0]		0;
T[1][2]		T[1][2]		[0 0 0 1 0 0 0]		2.0E+02;
h[1][2]		h[1][2]		[0 2 -2 0 0 0 0]	-1e5;

zeta[1][2][C]		0.236;
zeta[1][2][H]		0.413;
zeta[1][2][O]		0.301;
zeta[1][2][N]		0.05;

gamma[1][2][H2]		0.40;
gamma[1][2][CO]		0.40;
gamma[1][2][CO2]	0.10;
gamma[1][2][CH4]	0.05;
gamma[1][2][N2]		0.05;


// Pyrolysis of phase 2 - Cellulose
nPyroReac[2]	2; // number of pyrolysis reactions for phase[2]

// 		1 - Pyrolysis reaction 1
F[2][1]		F[2][1]		[0 0 0 0 0 0 0]		0.75;
A[2][1]		A[2][1]		[0 0 -1 0 0 0 0]	7.94e16;
E[2][1]		E[2][1]		[1 2 -2 0 -1 0 0]	202650;
m[2][1]		m[2][1]		[0 0 0 0 0 0 0]		1;
n[2][1]		n[2][1]		[0 0 0 0 0 0 0]		0;
T[2][1]		T[2][1]		[0 0 0 1 0 0 0]		2.0E+02;
h[2][1]		h[2][1]		[0 2 -2 0 0 0 0]	-2.8e5;

zeta[2][1][C]		0.236;  // zeta[solidPhase][pyroReac][species]
zeta[2][1][H]		0.413;
zeta[2][1][O]		0.301;
zeta[2][1][N]		0.05;

gamma[2][1][H2]		0.40;
gamma[2][1][CO]		0.40;
gamma[2][1][CO2]	0.10;
gamma[2][1][CH4]	0.05;
gamma[2][1][N2]		0.05;


// 		2 - Pyrolysis reaction 2
F[2][2]		F[2][2]		[0 0 0 0 0 0 0]		0.16;
A[2][2]		A[2][2]		[0 0 -1 0 0 0 0]	1.26e7;
E[2][2]		E[2][2]		[1 2 -2 0 -1 0 0]	255000;
m[2][2]		m[2][2]		[0 0 0 0 0 0 0]		1;
n[2][2]		n[2][2]		[0 0 0 0 0 0 0]		0;
T[2][2]		T[2][2]		[0 0 0 1 0 0 0]		2.0E+02;
h[2][2]		h[2][2]		[0 2 -2 0 0 0 0]	-2.8e5;

zeta[2][2][C]		0.236;
zeta[2][2][H]		0.413;
zeta[2][2][O]		0.301;
zeta[2][2][N]		0.05;

gamma[2][2][H2]		0.40;
gamma[2][2][CO]		0.40;
gamma[2][2][CO2]	0.10;
gamma[2][2][CH4]	0.05;
gamma[2][2][N2]		0.05;



// Pyrolysis of phase 3 - Lignin
nPyroReac[3]	1; // number of pyrolysis reactions for phase[3]

// 		1 - Pyrolysis reaction 1
F[3][1]		F[3][1]		[0 0 0 0 0 0 0]		0.66;
A[3][1]		A[3][1]		[0 0 -1 0 0 0 0]	5.09e5;
E[3][1]		E[3][1]		[1 2 -2 0 -1 0 0]	95000;
m[3][1]		m[3][1]		[0 0 0 0 0 0 0]		1;
n[3][1]		n[3][1]		[0 0 0 0 0 0 0]		0;
T[3][1]		T[3][1]		[0 0 0 1 0 0 0]		2.0E+02;
h[3][1]		h[3][1]		[0 2 -2 0 0 0 0]	-1.5e5;

zeta[3][1][C]		0.236;
zeta[3][1][H]		0.413;
zeta[3][1][O]		0.301;
zeta[3][1][N]		0.05;

gamma[3][1][H2]		0.40;
gamma[3][1][CO]		0.40;
gamma[3][1][CO2]	0.10;
gamma[3][1][CH4]	0.05;
gamma[3][1][N2]		0.05;


// Phase 4 - Water
nPyroReac[4]	1; // number of pyrolysis reactions for phase[4]

// 		1 - Pyrolysis reaction 1
F[4][1]		F[4][1]		[0 0 0 0 0 0 0]		1.0;
A[4][1]		A[4][1]		[0 0 -1 0 0 0 0]	5.13e6;
E[4][1]		E[4][1]		[1 2 -2 0 -1 0 0]	86000;
m[4][1]		m[4][1]		[0 0 0 0 0 0 0]		1;
n[4][1]		n[4][1]		[0 0 0 0 0 0 0]		0;
T[4][1]		T[4][1]		[0 0 0 1 0 0 0]		3.0E+02;
h[4][1]		h[4][1]		[0 2 -2 0 0 0 0]	-2.44e6;

zeta[4][1][H]		0.11;
zeta[4][1][O]		0.89;

gamma[4][1][H2O]	1.0;


/*** CHEMISTRY IN THE BOUNDARY LAYER ***/

/*** 		Equilibrium chemistry: Boundary layer edge elemental composition (in MOLE fraction) used for option: mutationBprime	***/
//		Note: the list of elements comes from the mixture files that you have chosen
//		in thermophysicalProperties (mixtureMutationBprime).
//		Only the elements present in the mixture file are read here. Values not provided here default to 0.
//		All zero will make the code crash because it's not set up to run without gas.

// Air
Yke[C] 		0;
Yke[H] 		0;
Yke[O]		0.21;
Yke[N]		0.79;

/***		Finite-rate chemistry: Boundary layer edge species composition (in MASS fractions)  ***/
Yie[O2]		0.233;
Yie[N2]		0.767;

/***            Solid mechanics model         ***/
nu_v    nu_v    [0 0 0 0 0 0 0]      0.3;     // virgin material Poisson's ratio
nu_c    nu_c    [0 0 0 0 0 0 0]      0.3;     // char Poisson's ration
E_v     E_v     [1 -1 -2 0 0 0 0]    12e9;    // virgin material Young modulus
E_c     E_c     [1 -1 -2 0 0 0 0]    12e9;    // char Young modulus
alpha_v alpha_v [0 0 0 -1 0 0 0]     5.4e-5;  // virgin thermal expansion coefficient
alpha_c alpha_c [0 0 0 -1 0 0 0]     5.4e-5;  // char thermal expansion coefficient
xi      xi      [0 0 0 0 0 0 0]      0.5;     // Jomaa Function (pyrolysis shrinkage)

// ************************************************************************* //
