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

improving beam_waist documentation #1936

Merged
merged 1 commit into from
Aug 31, 2024
Merged
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
Binary file added docs/_static/img/beam_waist.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 13 additions & 4 deletions tidy3d/components/source.py
Original file line number Diff line number Diff line change
Expand Up @@ -1119,6 +1119,14 @@ class GaussianBeam(AngledFieldSource, PlanarSource, BroadbandSource):
... direction='+',
... waist_radius=1.0)
Notes
--------
If one wants the focus 'in front' of the source, a negative value of ``beam_distance`` is needed.
.. image:: ../../_static/img/beam_waist.png
:width: 30%
:align: center
See Also
--------
Expand All @@ -1137,10 +1145,11 @@ class GaussianBeam(AngledFieldSource, PlanarSource, BroadbandSource):
0.0,
title="Waist Distance",
description="Distance from the beam waist along the propagation direction. "
"When ``direction`` is ``+`` and ``waist_distance`` is positive, the waist "
"is on the ``-`` side (behind) the source plane. When ``direction`` is ``+`` and "
" ``waist_distance``is negative, the waist is on the ``+`` side (in front) of "
"the source plane.",
"A positive value means the waist is positioned behind the source, considering the propagation direction. "
"For example, for a beam propagating in the ``+`` direction, a positive value of ``beam_distance`` "
"means the beam waist is positioned in the ``-`` direction (behind the source). "
"A negative value means the beam waist is in the ``+`` direction (in front of the source). "
"For an angled source, the distance is defined along the rotated propagation direction.",
units=MICROMETER,
)

Expand Down
Loading