﻿ Problem Descriptor Reference > The Sections of a Descriptor > Boundaries > Specifying Boundary Conditions > Boundary Conditions in 3D

# Boundary Conditions in 3D

In three-dimensional problems, an assignment of a segment boundary condition to a region boundary causes that boundary condition to be applied to the "side walls" of all layers of the layer stack above the region.  To selectively apply a boundary condition to the "side walls" of only one layer, use the LAYER qualifier, as in

LAYER number  VALUE(variable) = expression

LAYER "layer_name" VALUE(variable) = expression

The LAYER qualifier applies to all subsequent boundary condition specifications until a new LAYER qualifier is encountered, or the segment geometry (LINE or ARC) statements begin.

The boundary conditions on the extrusion surfaces themselves (the slicing surfaces) can be specified by the SURFACE qualifier preceding the boundary condition specification.

Consider a simple cube. The EXTRUSION and BOUNDARIES sections might look like this:

EXTRUSION  z = 0,1

BOUNDARIES

SURFACE 1 VALUE(U)=0                { 1 }

REGION 1

SURFACE 2 VALUE(U)=1        { 2 }

START(0,0)

NATURAL(U)=0                { 3 }

LINE TO (1,0)

LAYER 1 NATURAL(U)=1        { 4 }

LINE TO (1,1)

NATURAL(U)=0                { 5 }

LINE TO (0,1) TO CLOSE

Line { 1 } specifies a fixed value of 0 for the variable U over the entire surface 1 (ie. the Z=0 plane).
Line { 2 } specifies a value of 1 for the variable U on the top surface in REGION 1 only.
Line { 3 } specifies an insulating boundary on the Y=0 side wall of the cube.
Line { 4 } specifies a flux (whose meaning will depend on the PDE) on the X=1 side wall in LAYER 1 only.
Line { 5 } returns to an insulating boundary on the Y=1 and X=0 side walls.

[Of course, in this example the restriction to region 1 or layer 1 is meaningless, because there is only one of each.]