Skip to content

Commit

Permalink
Renamed `esis.flights.f1.optics.primaries.materials.multilayer_witnes…
Browse files Browse the repository at this point in the history
…s()` to `multilayer_witness_fit()`.
  • Loading branch information
byrdie committed Mar 14, 2024
1 parent f3c81fb commit 3038ccb
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions esis/flights/f1/optics/primaries/materials/_materials.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
__all__ = [
"multilayer_design",
"multilayer_witness_measured",
"multilayer_witness",
"multilayer_witness_fit",
"multilayer_fit",
]

Expand Down Expand Up @@ -151,7 +151,7 @@ def multilayer_witness_measured() -> optika.materials.MeasuredMirror:
return result


def multilayer_witness() -> optika.materials.MultilayerMirror:
def multilayer_witness_fit() -> optika.materials.MultilayerMirror:
"""
A multilayer stack fitted to the :func:`multilayer_witness_measured` measurement.
Expand All @@ -175,7 +175,7 @@ def multilayer_witness() -> optika.materials.MultilayerMirror:
angle_incidence = measurement.inputs.direction
# Fit a multilayer stack to the measured reflectivity
multilayer = primaries.materials.multilayer_witness()
multilayer = primaries.materials.multilayer_witness_fit()
# Define the rays incident on the multilayer stack that will be used to
# compute the reflectivity
Expand Down Expand Up @@ -287,14 +287,14 @@ def _func(x: np.ndarray):

def multilayer_fit() -> optika.materials.MultilayerMirror:
"""
A multilayer coating determined by modifying :func:`multilayer_witness`
A multilayer coating determined by modifying :func:`multilayer_witness_fit`
to have a glass substrate with the appropriate roughness.
Examples
--------
Plot the theoretical reflectivity of this multilayer stack vs. the
theoretical reflectivity of :func:`multilayer_witness`.
theoretical reflectivity of :func:`multilayer_witness_fit`.
.. jupyter-execute::
Expand Down Expand Up @@ -322,14 +322,14 @@ def multilayer_fit() -> optika.materials.MultilayerMirror:
)
# Initialize the multilayer stacks
multilayer_witness = primaries.materials.multilayer_witness()
multilayer_witness_fit = primaries.materials.multilayer_witness_fit()
multilayer_fit = primaries.materials.multilayer_fit()
# Define the vector normal to the multilayer stack
normal = na.Cartesian3dVectorArray(0, 0, -1)
# Compute the reflectivity of the multilayer for the given incident rays
reflectivity_witness = multilayer_witness.efficiency(rays, normal)
reflectivity_witness = multilayer_witness_fit.efficiency(rays, normal)
reflectivity_fit = multilayer_fit.efficiency(rays, normal)
# Plot the reflectivities as a function of wavelength
Expand Down Expand Up @@ -404,7 +404,7 @@ def multilayer_fit() -> optika.materials.MultilayerMirror:
ax.legend();
"""
design = multilayer_design()
result = multilayer_witness()
result = multilayer_witness_fit()
result.substrate.chemical = design.substrate.chemical
result.substrate.interface = design.substrate.interface
return result

0 comments on commit 3038ccb

Please sign in to comment.