Conducting Sphere Potential - epicf/ef GitHub Wiki
Currently ef is not capable to load any external electic fields or use any analytic expressions for them. However, it is possible to specify geometric primitives ( such as sphere, cube, etc. ) inside computation domain, that will act like conductors with fixed potential. To some extent, this allows to produce desired field destribution.
In this example, numerically calculated potential of charged conducting sphere is compared with analytical expression.
Potential of a charged conducting sphere with radius R is constant inside the sphere and equals to point charge potential outside the sphere:
In config file, definition of such sphere is done inside [Inner_region_sphere]
section.
[Inner_region_sphere.sphere]
potential = 3.0
sphere_origin_x = 5.0
sphere_origin_y = 5.0
sphere_origin_z = 5.0
sphere_radius = 0.5
Since we don't want any particles, there is no need to specify sources.
Currently, there is no option in Ef to calculate fields only - the program will attempt to evaluate several dynamics time steps. To mitigate such effect, it is possible to set saving time step greter than total simulation time:
[code]
When analysing results, it is possible to plot 2d potential distribution similar to previous example (todo: fix aspect ratio or plot 2 separate figures)
More illustrative is plot along axis passing though a center of the sphere:
It can be seen, that agreement is not very good. This can be related to the fact, that in the simulation potentials on boundaries of computation domain are set to zero. In reality potential potential slowly approaches zero as distance from the sphere increases.