Conducting objects

Conducting objects can be created that act as internal boundary conditions on the fieldsolver mesh as well as particle boundary conditions. Scripts for loading conducting objects in the mesh are described in the python module generateconductors.py. For example,

radius = 1.*cm

length = 1.

zz = ZCylinder(radius,length,voltage=10.*kV)

installconductor(zz)

will create a cylinder that is oriented along the z-axis with 1 cm radius,1 meter in axial length, at a 10 kV bias. The installconductor function installs the conductor so that it will be included in the field solution. A separate call is needed to have the conductor be a particle boundary condition as well. See Absorption of particles. Objects defined must have finite extents, but their boundaries can be coincident with the edge of the mesh.

There are numerous functions that can be employed to load objects on the mesh. Run doc(generateconductors) for more information. A brief summary includes:

Planes/Rectangles:

Plane(z0=0.,zsign=1,theta=0.,phi=0.,...)

XPlane(x0=0.,xsign=1,...)

YPlane(y0=0.,ysign=1,...)

ZPlane(z0=0.,zsign=1,...)

Box(xsize,ysize,zsize,...)

Cylinders:

Cylinder(radius,length,theta=0.,phi=0.,...)

ZCylinder(radius,length,...)

ZCylinderOut(radius,length,...)

ZCylinderElliptic(ellipticity,radius,length,...)

ZCylinderEllipticOut(ellipticity,radius,length,...)

ZRoundedCylinder(radius,length,radius2,...)

ZRoundedCylinderOut(radius,length,radius2,...)

XCylinder(radius,length,...)

XCylinderOut(radius,length,...)

XCylinderElliptic(ellipticity,radius,length,...)

XCylinderEllipticOut(ellipticity,radius,length,...)

YCylinder(radius,length,...)

YCylinderOut(radius,length,...)

YCylinderElliptic(ellipticity,radius,length,...)

YCylinderEllipticOut(ellipticity,radius,length,...)

Annulus(rmin,rmax,length,theta=0.,phi=0.,...)

ZAnnulus(rmin,rmax,length,...)

ZAnnulusElliptic(ellipticity,rmin,rmax,length,...)

Cones:

Cone(r_zmin,r_zmax,length,theta=0.,phi=0.,...)

Cone(r_zmin,r_zmax,length,...)

ZConeOut(r_zmin,r_zmax,length,...)

ConeSlope(slope,intercept,length,theta=0.,phi=0.,...)

ZConeSlope(slope,intercept,length,...)

ZConeOutSlope(slope,intercept,length,...)

Other:

Sphere(radius,...)

ZElliptoid(ellipticity,radius,...)

ZTorus(r1,r2,...)

ZGrid(xcellsize,ycellsize,length,thickness,...)

Beamletplate(za,zb,z0,thickness,...)

Surfaces of revolution:

ZSrfrvOut(rofzfunc,zmin,zmax,rmax,...)

ZSrfrvIn(rofzfunc,zmin,zmax,rmin,...)

ZSrfrvInOut(rminofz,rmaxofz,zmin,zmax,...)

ZSrfrvEllipticOut(ellipticity,rofzfunc,zmin,zmax,rmax,...)

ZSrfrvEllipticIn(ellipticity,rofzfunc,zmin,zmax,rmin,...)

ZSrfrvEllipticInOut(ellipticity,rminofz,rmaxofz,zmin,zmax,...)

XSrfrvOut(rofzfunc,zmin,zmax,rmax,...)

XSrfrvIn(rofzfunc,zmin,zmax,rmin,...)

XSrfrvInOut(rminofz,rmaxofz,zmin,zmax,...)

YSrfrvOut(rofzfunc,zmin,zmax,rmax,...)

YSrfrvIn(rofzfunc,zmin,zmax,rmin,...)

YSrfrvInOut(rminofz,rmaxofz,zmin,zmax,...)

CAD Interface:

CADconductor(filename,...)

All these scripts take the following additional arguments (default values given):

voltage=0.

xcent=0.

ycent=0.

zcent=0.

condid='next',

name=None

material='SS'

laccuimagecharge=0

neumann=0,

conductivity=None

permittivity=None

permeability=None

Intricate conducting structures can be built loaded on the mesh using these functions. New conductors can be created by taking the union, intersection or subtraction of multiple conductors. The '+' operator takes the union, '*' takes the intersection, and '-' does subtraction. For example:

z1 = ZCylinder(0.01,1.0,zcent=-0.5,voltage=-1.*keV)

z2 = ZCylinder(0.012,1.0,zcent=+0.5,voltage=+1.*keV)

zz = z1 + z2

installconductor(zz)

will join the two cylinders z1 and z2 together to create a 2 meter long pipe with a 1 cm radius and -1 kV bias in the first meter and a 1.2 cm radius and +1 kV bias in the second. Note that the conductors need not be charged to the same voltage, nor do they need to be touching. Another example:

zz = ZCylinder(0.01,1.0,voltage=10.*keV)

yy = YCylinder(0.01,1.0,voltage=zz.voltage,condid=zz.condid)

installconductor(zz*yy)

will install an object that is the intersection of two cylinders, one cylinder zz along the z-axis and the other cylinder yy along the y-axis. In this case, when an intersection is taken, the conductors not only must be at the same bias voltage, but they also must have the same conductor id defined by condid.

The following will define a hollowed out sphere.

souter = Sphere(radius=1.,voltage=1.)

sinner = Sphere(radius=0.8,voltage=source.voltage,condid=souter.condid)

shollow = souter - sinner

More complex conductors can be generated by combining compound conductors with others, as long as the above rules are followed.

A very useful conductor is the surface of revolution, where a curve is defined in r-z space and revolved about the axis to generate the volume. The simplest method to define the curve is via a list of r-z data points. The following will define a hollowed out cone. The wide part of the cone is at z=-1 and the narrow at z=0. The inner radius varies from 0.8 to 0.2 meters and the outer from 1.0 down to 0.4 meters.

rsrf = [0.8,0.2,0.4,1.0]

zsrf = [-1.0,0.,0.,-1.0]

hcone = ZSrfrv(rsrf=rsrf,zsrf=zsrf)

The line segments between the points are straight lines, unless the rad option is also specified, making them circular arcs with the given radii.