Skip to content

Bug: Live detector view throws with BeamletOptics master #37

Closed

Description

@StackEnjoyer

Problem

using BeamletOptics
pd = Detector(0.01)
translate3d!(pd, [0, 0.1, 0])
solve_system!(System([pd]), GaussianBeamlet([0.0, 0, 0], [0.0, 1, 0], 1e-6, 1e-3))
intensity(pd; n = 100)   # the call of the live detector view
# ERROR: MethodError: no method matching intensity(::Detector{Float64, BeamletOptics.Mesh{Float64}}, ::RegularGrid{Centroid}; n::Int64)

Tasks

  • The live detector view shows the intensity with BeamletOptics master, with and without a zoomed window
  • The power shown in the view equals optical_power of the same sampling
  • Trapz is no longer needed as a dependency

Notes

  • The grid and window keywords now belong to RegularGrid(...), passed as the second argument: intensity(pd, RegularGrid(n = 100, x_min = …))
  • optical_power(pd, s) integrates with the weights of the sampling s; the view integrates with its own trapz today
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions