Name

BoxRegion — Class for representing an orthorhombic region, i.e. a rectangular box of metallic or dielectric material.

Synopsis

Namespace: NanoLanguage
BoxRegion(
value,
xmin,
xmax,
ymin,
ymax,
zmin,
zmax
)

Description

A box region object. The box is infinite in a direction if the direction is not specified.

BoxRegion Arguments

value

The value that should be assigned to the box.

Type: Either the voltage or the dielectric constant of the region.

xmin

The lower boundary of the box along the x-axis.

Type: A PhysicalQuantity with a length unit.

xmax

The upper boundary of the box along the x-axis.

Type: A PhysicalQuantity with a length unit.

ymin

The lower boundary of the box along the y-axis.

Type: A PhysicalQuantity with a length unit.

ymax

The upper boundary of the box along the y-axis.

Type: A PhysicalQuantity with a length unit.

zmin

The lower boundary of the box along the z-axis.

Type: A PhysicalQuantity with a length unit.

zmax

The upper boundary of the box along the z-axis.

Type: A PhysicalQuantity with a length unit.

BoxRegion Methods

A BoxRegion object provides the following methods:

  • This object supports cloning. See the section called “Cloning of ATK Python objects”.

  • nlprint(stream, name, header): Print a string containing an ASCII description of the BoxRegion.

    stream

    The stream the description should be written to.

    Type: A stream that supports strings being written to using 'write'.

    Default: sys.stdout
    name

    The name of the box region being printed.

    Type: String.

    Default: 'Metallic Region'|'Dielectric Region'
    header

    Option to emphasize the description as a header or not.

    Type: Boolean.

    Default: True
  • value(): Function for asking for the value of the box region.

  • xmax(): Function for asking for the maximum x-value of the box

  • xmin(): Function for asking for the minimum x-value of the box

  • ymax(): Function for asking for the maximum y-value of the boy

  • ymin(): Function for asking for the minimum y-value of the box

  • zmax(): Function for asking for the maximum z-value of the box

  • zmin(): Function for asking for the minimum z-value of the box

Usage Examples

Define a dielectric region with dielectric constant  4 \varepsilon_0

dielectric_region = BoxRegion(
        4.,
        xmin = 0*Angstrom, xmax = 41.439*Angstrom, 
        ymin = 0.5*Angstrom, ymax = 3.57914*Angstrom, 
        zmin = 5*Angstrom, zmax = 50.4135*Angstrom
        )

Define two metallic regions, where the second metallic region is constructed by cloning the first region.

metallic_region1 = BoxRegion(
        1*Volt,
        xmin = 0*Angstrom, xmax = 41.439*Angstrom, 
        ymin = 0*Angstrom, ymax = 0.5*Angstrom, 
        zmin = 5*Angstrom, zmax = 15.*Angstrom
        )

metallic_region2 = metallic_region1(
        value = -1*Volt,
        ymin = 10*Angstrom, ymax = 12*Angstrom
        )

Notes