Chi-Tech
Diffusion Solver

Modules

 Basic Options
 

Functions

Handle chi_lua::chiFVDiffusionSolverCreate (string solver_name)
 
void chi_lua::chiFVDiffusionSetBCProperty (int SolverHandle, string PropertyName, varying Values)
 
Handle chi_lua::chiCFEMMGDiffusionSolverCreate ()
 
void chi_lua::chiCFEMMGDiffusionSetBCProperty (int SolverHandle, string PropertyName, varying Values)
 
Handle chi_lua::chiCFEMDiffusionSolverCreate ()
 
void chi_lua::chiCFEMDiffusionSetBCProperty (int SolverHandle, string PropertyName, varying Values)
 
Handle chi_lua::chiDiffusionCreateSolver ()
 
void chi_lua::chiDiffusionSetProperty (int SolverHandle, string PropertyName, varying Values)
 
Success chi_lua::chiDiffusionExecute (int SolverHandle)
 
Success chi_lua::chiDiffusionInitialize (int SolverHandle)
 
Handle chi_lua::chiDFEMDiffusionSolverCreate ()
 
void chi_lua::chiDFEMDiffusionSetBCProperty (int SolverHandle, string PropertyName, varying Values)
 

Detailed Description

Function Documentation

◆ chiCFEMDiffusionSetBCProperty()

void chi_lua::chiCFEMDiffusionSetBCProperty ( int  SolverHandle,
string  PropertyName,
varying  Values 
)

Sets a property of a Diffusion solver. Please also consult the whitepaper for the Diffusion solver (Diffusion Whitepaper)



Additional basic options can be set as indicated in Basic Options

Parameters
SolverHandleint Handle to an existing diffusion solver.
PropertyNamestring Name for a specific property.
Valuesvarying Number of inputs associated with the index.

_

PropertyName\n

"boundary_type"
Boundary type. Expects boundary index then BoundaryTypeName then type value.

chiDiffusionsetBCproperty(solver,"boundary_type",2,"dirichlet",1.0)

BoundaryTypeName

reflecting
Reflecting boundary conditions. Synonymous with Neumann with a derivative of 0.0.

\[ -D \hat{n}\cdot \nabla \phi = 0 \]



dirichlet
Constant value boundary condition. Expects to be followed by a value $ f $ associated with $ \phi $.

\[ \phi = f \]



neumann
Constant derivative boundary condition. Expects to be followed by a constant $ f $ representing

\[ -D \hat{n}\cdot \nabla \phi = f \]



vacuum
Vacuum boundary conditions. More appropriate to neutron diffusion.

\[ \frac{1}{4}\phi + \frac{1}{2} D \hat{n}\cdot \nabla \phi = 0 \]



robin
Robin boundary condition of the form

\[ a \phi + b D \hat{n}\cdot \nabla \phi = f \]



Usage Examples:

test/modules/CFEM_Diffusion/cDiffusion_2D_3a_analytical_coef.lua
test/modules/CFEM_Diffusion/cDiffusion_2D_2b_RobinBCs.lua
test/modules/CFEM_Diffusion/cDiffusion_2D_3b_analytical_coef2.lua
test/modules/CFEM_Diffusion/cDiffusion_2D_2a_DirBCs.lua
test/modules/CFEM_Diffusion/cDiffusion_2D_1a_linear.lua

Author
Jan

Definition at line 3078 of file lua_functions.c.

◆ chiCFEMDiffusionSolverCreate()

◆ chiCFEMMGDiffusionSetBCProperty()

void chi_lua::chiCFEMMGDiffusionSetBCProperty ( int  SolverHandle,
string  PropertyName,
varying  Values 
)

Sets a property of a Diffusion solver. Please also consult the whitepaper for the Diffusion solver (Diffusion Whitepaper)



Additional basic options can be set as indicated in Basic Options

Parameters
SolverHandleint Handle to an existing diffusion solver.
PropertyNamestring Name for a specific property.
Valuesvarying Number of inputs associated with the index.

_

PropertyName\n

"boundary_type"
Boundary type. Expects boundary index then BoundaryTypeName then type value.

chiCFEMMGDiffusionSetBCProperty(solver,"boundary_type",bdID,"vacuum")
void chiCFEMMGDiffusionSetBCProperty(int SolverHandle, string PropertyName, varying Values)

BoundaryTypeName

reflecting
Reflecting boundary conditions. Synonymous with Neumann with a derivative of 0.0.

\[ -D \hat{n}\cdot \nabla \phi = 0 \]



neumann
Constant derivative boundary condition. Expects to be followed by a constant $ f $ representing

\[ -D \hat{n}\cdot \nabla \phi = f \]



vacuum
Vacuum boundary conditions. More appropriate to neutron diffusion.

\[ \frac{1}{4}\phi + \frac{1}{2} D \hat{n}\cdot \nabla \phi = 0 \]



robin
Robin boundary condition of the form

\[ a \phi + b D \hat{n}\cdot \nabla \phi = f \]



Author
Jean

Definition at line 2993 of file lua_functions.c.

◆ chiCFEMMGDiffusionSolverCreate()

Handle chi_lua::chiCFEMMGDiffusionSolverCreate ( )

Creates a Multigroup CFEM Diffusion solver.

Returns
Handle int Handle to the created solver.

Definition at line 2948 of file lua_functions.c.

◆ chiDFEMDiffusionSetBCProperty()

void chi_lua::chiDFEMDiffusionSetBCProperty ( int  SolverHandle,
string  PropertyName,
varying  Values 
)

Sets a property of a Diffusion solver. Please also consult the whitepaper for the Diffusion solver (Diffusion Whitepaper)



Additional basic options can be set as indicated in Basic Options

Parameters
SolverHandleint Handle to an existing diffusion solver.
PropertyNamestring Name for a specific property.
Valuesvarying Number of inputs associated with the index.

_

PropertyName\n

"boundary_type"
Boundary type. Expects boundary index then BoundaryTypeName then type value.

chiDiffusionsetBCproperty(solver,"boundary_type",2,"dirichlet",1.0)

BoundaryTypeName

reflecting
Reflecting boundary conditions. Synonymous with Neumann with a derivative of 0.0.

\[ -D \hat{n}\cdot \nabla \phi = 0 \]



dirichlet
Constant value boundary condition. Expects to be followed by a value $ f $ associated with $ \phi $.

\[ \phi = f \]



neumann
Constant derivative boundary condition. Expects to be followed by a constant $ f $ representing

\[ -D \hat{n}\cdot \nabla \phi = f \]



vacuum
Vacuum boundary conditions. More appropriate to neutron diffusion.

\[ \frac{1}{4}\phi + \frac{1}{2} D \hat{n}\cdot \nabla \phi = 0 \]



robin
Robin boundary condition of the form

\[ a \phi + b D \hat{n}\cdot \nabla \phi = f \]



Usage Examples:

test/modules/DFEM_Diffusion/dDiffusion_2D_2a_DirBCs.lua
test/modules/DFEM_Diffusion/dDiffusion_2D_3a_analytical_coef.lua
test/modules/DFEM_Diffusion/dDiffusion_2D_3b_analytical_coef2.lua
test/modules/DFEM_Diffusion/dDiffusion_2D_2b_RobinBCs.lua
test/modules/DFEM_Diffusion/dDiffusion_2D_1a_linear.lua

Author
Jan

Definition at line 3281 of file lua_functions.c.

◆ chiDFEMDiffusionSolverCreate()

Handle chi_lua::chiDFEMDiffusionSolverCreate ( )

◆ chiDiffusionCreateSolver()

◆ chiDiffusionExecute()

◆ chiDiffusionInitialize()

◆ chiDiffusionSetProperty()

void chi_lua::chiDiffusionSetProperty ( int  SolverHandle,
string  PropertyName,
varying  Values 
)

Sets a property of a Diffusion solver. Please also consult the whitepaper for the Diffusion solver (Diffusion Whitepaper)



Additional basic options can be set as indicated in Basic Options

Parameters
SolverHandleint Handle to an existing diffusion solver.
PropertyNamestring Name for a specific property.
Valuesvarying Number of inputs associated with the index.

_

PropertyName\n

"boundary_type"
Boundary type. Expects boundary name (string) then BoundaryTypeName then type value.

chiDiffusionSetProperty(solver,"boundary_type",2,"dirichlet",1.0)
void chiDiffusionSetProperty(int SolverHandle, string PropertyName, varying Values)

BoundaryTypeName

reflecting
Reflecting boundary conditions. Synonymous with Neumann with a derivative of 0.0.

\[ -D \hat{n}\cdot \nabla \phi = 0 \]



dirichlet
Constant value boundary condition. Expects to be followed by a value $ f $ associated with $ \phi $.

\[ \phi = f \]



neumann
Constant derivative boundary condition. Expects to be followed by a constant $ f $ representing

\[ -D \hat{n}\cdot \nabla \phi = f \]



vacuum
Vacuum boundary conditions. More appropriate to neutron diffusion.

\[ \frac{1}{4}\phi + \frac{1}{2} D \hat{n}\cdot \nabla \phi = 0 \]



robin
Robin boundary condition of the form

\[ a \phi + b D \hat{n}\cdot \nabla \phi = f \]



Usage Examples:

test/modules/Diffusion/Diffusion1D_IP.lua
test/modules/Diffusion/Diffusion1D.lua
test/modules/Diffusion/Diffusion3D_1Poly_IP.lua
test/modules/Diffusion/Diffusion3D_2Ortho.lua
test/modules/Diffusion/Diffusion3D_3Unstructured_IP.lua
test/modules/Diffusion/Diffusion3D_1Poly.lua
test/modules/Diffusion/Diffusion2D_1Poly.lua
test/modules/Diffusion/Diffusion2D_1Poly_IP.lua
test/modules/Diffusion/Diffusion3D_4VTU.lua
test/modules/Diffusion/Diffusion2D_2Unstructured.lua
test/modules/Diffusion/Diffusion1D_KBA.lua
test/modules/Diffusion/Diffusion2D_2Unstructured_IP.lua
test/modules/Diffusion/Diffusion3D_3Unstructured.lua

Author
Jan

Definition at line 3163 of file lua_functions.c.

◆ chiFVDiffusionSetBCProperty()

void chi_lua::chiFVDiffusionSetBCProperty ( int  SolverHandle,
string  PropertyName,
varying  Values 
)

Sets a property of a Diffusion solver. Please also consult the whitepaper for the Diffusion solver (Diffusion Whitepaper)



Additional basic options can be set as indicated in Basic Options

Parameters
SolverHandleint Handle to an existing diffusion solver.
PropertyNamestring Name for a specific property.
Valuesvarying Number of inputs associated with the index.

_

PropertyName\n

"boundary_type"
Boundary type. Expects boundary index then BoundaryTypeName then type value.

chiDiffusionsetBCproperty(solver,"boundary_type",2,"dirichlet",1.0)

BoundaryTypeName

reflecting
Reflecting boundary conditions. Synonymous with Neumann with a derivative of 0.0.

\[ -D \hat{n}\cdot \nabla \phi = 0 \]



dirichlet
Constant value boundary condition. Expects to be followed by a value $ f $ associated with $ \phi $.

\[ \phi = f \]



neumann
Constant derivative boundary condition. Expects to be followed by a constant $ f $ representing

\[ -D \hat{n}\cdot \nabla \phi = f \]



vacuum
Vacuum boundary conditions. More appropriate to neutron diffusion.

\[ \frac{1}{4}\phi + \frac{1}{2} D \hat{n}\cdot \nabla \phi = 0 \]



robin
Robin boundary condition of the form

\[ a \phi + b D \hat{n}\cdot \nabla \phi = f \]



Author
Jan

Definition at line 2940 of file lua_functions.c.

◆ chiFVDiffusionSolverCreate()

Handle chi_lua::chiFVDiffusionSolverCreate ( string  solver_name)

Creates a Finite Volume Diffusion solver.

Parameters
solver_namestring Optional. Text name for the solver. [Default:"FVDiffusionSolver"]
Returns
Handle int Handle to the created solver.

Definition at line 2889 of file lua_functions.c.