Skip to content

Grating compression#364

Open
jtravs wants to merge 13 commits into
LupoLab:masterfrom
jtravs:gratings
Open

Grating compression#364
jtravs wants to merge 13 commits into
LupoLab:masterfrom
jtravs:gratings

Conversation

@jtravs
Copy link
Copy Markdown
Contributor

@jtravs jtravs commented Oct 13, 2024

Adds prop_gratings to simply model a grating compressor.

  • Add tests
  • Add example

@chrisbrahms
Copy link
Copy Markdown
Collaborator

LGTM, just a minor docstring error. is this still WIP really?

@jtravs
Copy link
Copy Markdown
Contributor Author

jtravs commented Oct 21, 2024

Yes, in that I haven't tested much, or added tests!

@chrisbrahms
Copy link
Copy Markdown
Collaborator

sorry, to clarify--is that still actually in progress, ie are you likely to have time to do it?

@jtravs
Copy link
Copy Markdown
Contributor Author

jtravs commented Oct 21, 2024

Oh, I see! Yes, I plan to do it, when I get time... Tests are not totally trivial, because this includes the full phase, so cannot be directly compared to analytic formulas. So my plan was to manually build an example that I have manually checked and use that as a test basis.

Copilot AI review requested due to automatic review settings March 2, 2026 22:53
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds initial support for modeling and optimizing a 4-grating compressor in the Fields module, enabling grating-based spectral-phase propagation and an optimizer for peak-power compression.

Changes:

  • Introduces prop_gratings! / prop_gratings to apply a grating-compressor spectral phase in the frequency domain.
  • Adds optcomp_gratings to search grating separation L that maximizes peak power (via Optim.optimize), returning the optimal separation and compressed field.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Fields.jl Outdated
Comment thread src/Fields.jl Outdated
Comment thread src/Fields.jl Outdated
Comment thread src/Fields.jl Outdated
Comment thread src/Fields.jl
@jtravs jtravs changed the title WIP: grating compression Grating compression Mar 3, 2026
@jtravs jtravs requested review from chrisbrahms and Copilot March 3, 2026 00:54
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Fields.jl
Comment thread examples/simple_interface/SPM_grating_compression.jl Outdated
Comment thread examples/simple_interface/SPM_grating_compression.jl Outdated
Comment thread src/Fields.jl Outdated
@chrisbrahms
Copy link
Copy Markdown
Collaborator

I'm happy if you're happy. Please could you add this to #415 when you've merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants