tidy3d.rf.AxisAlignedCurrentIntegralSpec#
- class AxisAlignedCurrentIntegralSpec[source]#
Bases:
AbstractAxesRH,BoxClass for specifying the computation of conduction current via Ampère’s circuital law on an axis-aligned loop.
- Parameters:
center (Optional[tuple[Union[float, autograd.tracer.Box], Union[float, autograd.tracer.Box], Union[float, autograd.tracer.Box]]] = None) – [units = um]. Center of object in x, y, and z.
size (tuple[Union[NonNegativeFloat, autograd.tracer.Box], Union[NonNegativeFloat, autograd.tracer.Box], Union[NonNegativeFloat, autograd.tracer.Box]]) – [units = um]. Size in x, y, and z directions.
sign (Literal['+', '-']) – Positive indicates current flowing in the positive normal axis direction.
extrapolate_to_endpoints (bool = False) – This parameter is passed to
AxisAlignedPathIntegralobjects when computing the contour integral.snap_contour_to_grid (bool = False) – This parameter is passed to
AxisAlignedPathIntegralobjects when computing the contour integral.
Example
>>> current_spec = AxisAlignedCurrentIntegralSpec( ... center=(0, 0, 0), ... size=(1, 1, 0), ... sign="+", ... snap_contour_to_grid=True ... )
Attributes
Axis normal to loop
sizecenterMethods
plot([x, y, z, ax, plot_arrow])Plot path integral at single (x,y,z) coordinate.
- sign#
- extrapolate_to_endpoints#
- snap_contour_to_grid#
- property main_axis#
Axis normal to loop
- plot(x=None, y=None, z=None, ax=None, plot_arrow=True, **path_kwargs)[source]#
Plot path integral at single (x,y,z) coordinate.
- Parameters:
x (float = None) – Position of plane in x direction, only one of x,y,z can be specified to define plane.
y (float = None) – Position of plane in y direction, only one of x,y,z can be specified to define plane.
z (float = None) – Position of plane in z direction, only one of x,y,z can be specified to define plane.
ax (matplotlib.axes._subplots.Axes = None) – Matplotlib axes to plot on, if not specified, one is created.
plot_arrow (bool = True) – Whether to plot the arrow indicating current direction. Default is
True.**path_kwargs – Optional keyword arguments passed to the matplotlib plotting of the line. For details on accepted values, refer to Matplotlib’s documentation.
- Returns:
The supplied or created matplotlib axes.
- Return type:
matplotlib.axes._subplots.Axes