TubeRegion¶
- class TubeRegion(value, start_point, end_point, inner_radius, thickness)¶
Class for representing a hollow cylinder region of metallic or dielectric material.
- Parameters:
value (float | PhysicalQuantity compatible with Volt) – The value that should be assigned to the tube. Either the voltage or the dielectric constant of the region.
start_point (PhysicalQuantity of type length) – Vector to the first point defining the central axis of the tube.
end_point (PhysicalQuantity of type length) – Vector to the second point defining the central axis of the tube.
inner_radius (PhysicalQuantity of type length) – Inner radius of the tube.
thickness (PhysicalQuantity of type length) – Thickness of the tube wall.
- endPoint()¶
- Returns:
The end point of the tube.
- Return type:
PhysicalQuantity of type length
- innerRadius()¶
- Returns:
The inner radius of the tube.
- Return type:
PhysicalQuantity of type length
- nlprint(stream=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='utf-8'>, header=True)¶
Print a string containing an ASCII description of the SpatialRegion.
- Parameters:
stream (Stream based object) – The io to write to.
header (bool) – Option to emphasize the description as a header or not.
- startPoint()¶
- Returns:
The start point of the tube.
- Return type:
PhysicalQuantity of type length
- thickness()¶
- Returns:
The wall thickness of the tube.
- Return type:
PhysicalQuantity of type length
- uniqueString()¶
Return a unique string representing the state of the object.
- value()¶
Function for asking for the value of the box region.
- Returns:
The value of the box region.
- Return type:
float | PhysicalQuantity compatible with Volt
Usage Examples¶
Define a dielectric region with dielectric constant \(4 \varepsilon_0\):
dielectric_region = TubeRegion(
value=4.0,
start_point=[1.0, 2.0, 3.0]*Angstrom, end_point=[4.0, 5.0, 6.0]*Angstrom,
inner_radius=3.5*Angstrom,
thickness=1.2*Angstrom
)
Define two metallic regions where the second metallic region is constructed by cloning the first:
metallic_region1 = TubeRegion(
value=1*Volt,
start_point=[1.0, 2.0, 3.0]*Angstrom, end_point=[4.0, 5.0, 6.0]*Angstrom,
inner_radius=3.5*Angstrom,
thickness=1.2*Angstrom
)
metallic_region2 = metallic_region1(
value=-1*Volt,
inner_radius=1.1*Angstrom,
thickness=0.5*Angstrom
)
Notes¶
The following spatial regions are available: