Structure
Radiant.Geometry
— TypeGeometry
Structure used to define the geometry properties of the medium for transport calculations.
Mandatory field(s)
name::String
: name (or identifier) of the Geometry structure.dimension::Int64
: dimension of the geometry.material_per_region::Array{Material}
: multidimensional array of the material per regions.boundary_conditions::Dict{String,Int64}
: boundary conditions along each axis.number_of_regions::Dict{String,Int64}
: number of regions along each axis.voxels_per_region::Dict{String,Vector{Int64}}
: number of voxels inside each regions along each axis.region_boundaries::Dict{String,Vector{Float64}}
: boundaries of each regions along each axis.
Optional field(s) - with default values
type::String="cartesian"
: type of geometry.
Methods
Radiant.set_type
— Methodset_type(this::Geometry,type::String)
To set the type of geometry.
Input Argument(s)
this::Geometry
: geometry.type::String
: type of geometry, which can takes the following value: -type = "cartesian"
: Cartesian geometry.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_type("cartesian")
Radiant.set_dimension
— Methodset_dimension(this::Geometry,dimension::Int64)
To set the dimension of geometry.
Input Argument(s)
this::Geometry
: geometry.dimension::Int64
: dimension of the geometry, which can be either 1, 2 or 3.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_dimension(2) # For 2D geometry
Radiant.set_boundary_conditions
— Methodset_boundary_conditions(this::Geometry,boundary::String,boundary_condition::String)
To set the boundary conditions at the specified boundary.
Input Argument(s)
this::Geometry
: geometry.boundary::String
: boundary for which the boundary condition is applied, which can takes the following value:boundary = "x-"
: the lower bound along x-axisboundary = "x+"
: the upper bound along x-axisboundary = "y-"
: the lower bound along y-axisboundary = "y+"
: the upper bound along y-axisboundary = "z-"
: the lower bound along z-axisboundary = "z+"
: the upper bound along z-axis
boundary_condition::String
: boundary conditions, which can takes the following value: -boundary = "void"
: void boundary conditions.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_boundary_conditions("x-","void")
Radiant.set_number_of_regions
— Methodset_number_of_regions(this::Geometry,axis::String,number_of_regions::Int64)
To set the number of regions along a specified axis.
Input Argument(s)
this::Geometry
: geometry.axis::String
: axis along which the number of regions is specified, which can takes the following values:boundary = "x"
: along x-axisboundary = "y"
: along y-axisboundary = "z"
: along z-axis
number_of_regions::Int64
: number of regions.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_number_of_regions("x",3)
Radiant.set_voxels_per_region
— Methodset_voxels_per_region(this::Geometry,axis::String,voxels_per_region::Vector{Int64})
To set the number of voxels for each regions along a specified axis.
Input Argument(s)
this::Geometry
: geometry.axis::String
: axis along which the number of regions is specified, which can takes the following values:boundary = "x"
: along x-axisboundary = "y"
: along y-axisboundary = "z"
: along z-axis
voxels_per_region::Vector{Int64}
: vector with the number of voxels for each regions along the specified axis.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_number_of_regions("x",3)
julia> geo.set_voxels_per_region("x",[10,5,2])
Radiant.set_region_boundaries
— Methodset_region_boundaries(this::Geometry,axis::String,region_boundaries::Vector{Float64})
To set the boundaries of each regions along a specified axis.
Input Argument(s)
this::Geometry
: geometry.axis::String
: axis along which the number of regions is specified, which can takes the following values:boundary = "x"
: along x-axisboundary = "y"
: along y-axisboundary = "z"
: along z-axis
region_boundaries::Vector{Float64}
: vector with the regions boundaries along the specified axis in ascending order.
Output Argument(s)
N/A
Examples
julia> geo = Geometry()
julia> geo.set_number_of_regions("x",3)
julia> geo.set_voxels_per_region("x",[10,5,2])
julia> geo.set_voxels_per_region("x",[0.0 0.3 0.5 1.0])
Radiant.set_material_per_region
— Methodset_material_per_region(this::Geometry,material_per_region::Array{Material})
To set the material in each regions of the geometry.
Input Argument(s)
this::Geometry
: geometry.material_per_region::Array{Material}
: array containing the material for each regions. Its size should fit the number of regions per axis.
Output Argument(s)
N/A
Examples
# Define material
julia> mat1 = Material(); mat2 = Material()
julia> ... # Define the material properties
# 1D geometry case
julia> geo1D = Geometry()
julia> geo1D.set_type("cartesian")
julia> geo1D.set_dimension(1)
julia> geo1D.set_number_of_regions("x",3)
julia> geo1D.set_material_per_region([mat1 mat2 mat1])
# 2D geometry case
julia> geo1D = Geometry()
julia> geo1D.set_type("cartesian")
julia> geo1D.set_dimension(2)
julia> geo1D.set_number_of_regions("x",2)
julia> geo1D.set_number_of_regions("y",3)
julia> geo1D.set_material_per_region([mat1 mat2 mat1 ; mat2 mat1 mat2])
Radiant.build
— Methodbuild(this::Geometry,cs::Cross_Sections)
To build the geometry structure.
Input Argument(s)
this::Geometry
: geometry.cs::Cross_Sections
: cross-sections library.
Output Argument(s)
N/A
Examples
julia> cs = Cross_Sections()
julia> ... # Defining the cross-sections library properties
julia> cs.build()
julia> geo = Geometry()
julia> ... # Defining the geometry properties
julia> geo.build(cs)