4.1.3 Objects

There are several objects which can be used in the PSlab. They are all subclasses of either _GeometryObject2D or _GeometryObject3D which consequently are derived from _GeometryObject. All the geometry objects don't have any useful methods other than constructors in which all the necessary informations concerning position, size and material should be given.

There are some common parameters which can be provided to the constructor of any object:

is the value of dielectric constant of the object. It can be either a single isotropic value or a sequence of three diagonal elements of anisotropic diagonal tensor (non-diagonal anisotropy is not supported by the PSlab).
the magnetic constant of the object. It is set in simmilar way as epsilon, but can be omitted in which case its default value is $1$.
the smoothing parameter of the object. The default value is the smooth parameter of the geometry. See the desctiption of smooth member in section 4.1.1 for more details.

In two-dimensional geometry (Geometry2D) there is only one possible object to be defined:

class Rectangle( self, left, right, epsilon[, mu[, smooth]])
Rectangle in $yz$ plane in Geometry2D. The left and right are the positions of the sides of the rectangle.

3D geometriy (Geometry3D) can contain the following objects:

class Cylinder( center, radius, epsilon[, mu[, smooth]])
Cylinder with axis perpendicular to the layers. The center must be a sequence of two numbers containg $x$ and $y$ coordinate of the cyulinder center. The meaning of radius is obvious ;).

class Cuboid( corner1, corner2, epsilon[, mu[, smooth]])
A cuboid with it's sides paraller to $x$ and $y$ axis. corner1 and corner2 should both be sequences of two numbers containg $x$ and $y$ coordinates of the oposite corners. If $corner1 = x_1,y_1$ and $corner2 = x_2,y_2$, then all the corners of the cuboid in $xy$ plane are $(x_1,y_1)$, $(x_1,y_2)$, $(x_2,y_1)$, and $(x_2,y_2)$.