kicad2ems.fdtd.solver

The FDTD solvers' common class: the board lowered to boundaries, a rectilinear
mesh and the CSX model, run on an engine with openEMS's interface (engines.py);
antenna mode and field dumps. A solver on an FDTD engine subclasses FDTD, names
its engine and adds what is its own (openEMS: the import check; gfdtd: the
backend). The mesh convergence check (--converge, converge.py) is the layer's:
it runs on either engine.

    prepare  boundaries (bc), the mesh with the edge walls snapped onto it, the
             closed-box resonance check, the field-dump specs, the excitation
             length; the mesh preview (the first FDTD solver of the run draws
             it)
    solve    one run per driven port (--jobs at a time); in antenna mode one run
             with the far field
    outputs  field-dump maps, the CSX file, per-run times, antenna results and
             plots

The settings below are shared: every FDTD solver lists these same Option
objects, so each is one setting.
class kicad2ems.fdtd.solver.FDTD[source]
An FDTD solver. A subclass sets name, label, options (MESH + RUN + its
own) and engine(s); tag names its files beside another FDTD solver's ('' for
the first: <name>_antenna.json; '_gfdtd': <name>_gfdtd_antenna.json).
antenna(run, p)[source]
<name><tag>_antenna.json (with the solver and its sphere file) and
the antenna plots.
coarse(run, p, jobs, run_kw)[source]
Runs before the result's: the coarser --converge levels, on this
engine (run_kw names it), with the ports the result has
(--port-kind).
copper(run)[source]
(sigma, rough um RMS) the model's conducting sheets get: (None, None)
for PEC copper; --rough as the conductivity at the band centre where the
engine has no roughness of its own.
copper_kw(run)[source]
What build_fdtd needs beyond (sigma, rough): faces (gfdtd: thick
copper's sheets marked as faces, so that their roughness takes the
copper's skin depth) and finish (the run's surface finish: its metal
layers, per outer layer the strip's share of the loss, wideband in the
sheets or at the band centre, the band). None when there is nothing to
add.
deviations(run, p)[source]
Vias and drawn posts moved onto mesh lines, parts split in two
elements, edge walls moved onto mesh lines.
dump_outputs(run, p)[source]
The field maps (PNG, and animations with --dump-animate) of the
frequency-domain plane dumps, named with the tag beside another FDTD
solver's.
engine(s)[source]
The engine string of engines.py ('openems', 'gfdtd:gpu').
estimate(run)[source]
Cells of the mesh x timesteps (the pulse and the ring-down, at most
--max-steps) x the runs, at CELLS_PER_CORE_S per core.
jobs(run, p)[source]
Runs at once: --jobs, warned when they need more memory than the
machine has.
levels(s)[source]
Mesh levels solved (--converge: several).
line_plan(run, p, mesh, quiet=False)[source]
The line probes of this run's ports on `mesh` (--port-kind;
lineport.plan_ports), {} for lumped ports and in antenna mode; why a
port stays lumped, logged. 'line' needs every port driven (an error),
'auto' then keeps them all lumped.
line_s(run, r, plan, quiet=False)[source]
S (single-ended) from the line probes and the lumped ports
(lineport.solve), else the runs' lumped S.
mesh(run, p, **kw)[source]
The mesh that gives the result; with --converge also the coarser
levels, in p.levels (the finest gives the result).
outputs(run, p, res)[source]
Its own outputs after the solve (plots, files, summary entries);
optional.
phased(run, p)[source]
The phased drive's antenna from its runs
(fdtd.antenna.combine_phased); --aim's phases at the pattern frequency
the drive gives, then combined again.
prepare(run)[source]
Its own form of the board (openEMS: the boundaries and the mesh),
handed to solve() and the later steps; None when it needs none. A
preview stops here.
readback(run, p)[source]
What its native model holds, read back in the board's terms
(parity.py: vias, copper area per layer, parts, ports), or None.
reusable(run)[source]
An earlier run's S may stand for this one's solve (kicad2ems 2.12)
unless this run asks for what only a solve leaves: field dumps, the far
field (antenna mode) or the mesh levels of --converge. (Its outputs then
are not written: the CSX file and the per-run times are the earlier
run's.)
solve(run, p)[source]
The Result: S-parameters over the board's ports as reported
(differential pairs as mixed-mode ports).
summary(run)[source]
Where its facts go in the run summary: its own table (the first FDTD
solver: the top level).
validate_converge(s)[source]
Why --converge cannot run as given, or None.
kicad2ems.fdtd.solver.mesh_zone(s)[source]
auto_mesh's zone from --mesh-zone: False (off), True (on) or a distance
in mm. Never in antenna mode: there the ground copper is often the radiator
(a slot, an inverted-F's ground).