Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DirectivityMonitor #1695

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion tidy3d/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
from .components.monitor import ModeMonitor, ModeSolverMonitor, PermittivityMonitor
from .components.monitor import FieldProjectionAngleMonitor, FieldProjectionCartesianMonitor
from .components.monitor import FieldProjectionKSpaceMonitor, FieldProjectionSurface
from .components.monitor import DiffractionMonitor
from .components.monitor import DiffractionMonitor, DirectivityMonitor

# lumped elements
from .components.lumped_element import LumpedResistor
Expand Down Expand Up @@ -245,6 +245,7 @@ def set_logging_level(level: str) -> None:
"FieldProjectionKSpaceMonitor",
"FieldProjectionSurface",
"DiffractionMonitor",
"DirectivityMonitor",
"RunTimeSpec",
"Simulation",
"FieldProjector",
Expand Down
7 changes: 7 additions & 0 deletions tidy3d/components/monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1074,6 +1074,12 @@ def storage_size(self, num_cells: int, tmesh: ArrayFloat1D) -> int:
return BYTES_COMPLEX * len(self.theta) * len(self.phi) * len(self.freqs) * 6


class DirectivityMonitor(FieldProjectionAngleMonitor, FluxMonitor):
""":class:`Monitor` that samples electromagnetic near fields in the frequency domain,
projects them at given observation angles, and computes directivity. [TODO]
"""


class FieldProjectionCartesianMonitor(AbstractFieldProjectionMonitor):
""":class:`Monitor` that samples electromagnetic near fields in the frequency domain
and projects them on a Cartesian observation plane.
Expand Down Expand Up @@ -1404,6 +1410,7 @@ def _storage_size_solver(self, num_cells: int, tmesh: ArrayFloat1D) -> int:
ModeMonitor,
ModeSolverMonitor,
FieldProjectionAngleMonitor,
DirectivityMonitor,
FieldProjectionCartesianMonitor,
FieldProjectionKSpaceMonitor,
DiffractionMonitor,
Expand Down
Loading