Skip to content

Conversation

@mjvstreeter
Copy link
Contributor

This code adds the go_to_farfield method to the laser class to allow cheap calculation of the far field from beam defined in the near field. A focal length is supplied to the code which is used to definte the steps size in angle for the wave components and changes the axis size after the fourier transform.

In order to make this work i also modified the apply_optics method which can now build a list of the applied optics. This is used to rebuild the near-field pulse on a warped grid so that regular axes can be used for the farfield.

Note - the parabolic phase term for the focusing is implicit in the method and so should not be added to the near field pulse.

The fraunhofer.py file was added to laser.utils to contain the required functions.

A test file was also added to compare the calculations for gaussian beam to the analytical predictions.

I've used this for calculating the focus of more realistic near field profiles (high order supergaussians). And initialised the pulses in fbpic to run simulations. It is likely that development of lasy propagators will be able to perform similar calculations in future in a less hacky way.

Happy for anyone to suggest changes or fixes if anything is not working as expected!

Added file to utils folder which uses np.fft to propagate field to farfield.

Currently in testing only - not fully implemented

Added method to Laser class to propagate to focus for a given focal length.
Added ability for apply_optics method to remember optics. Include application of optics in far field calculation. The focusing phase terms should be relative to the nominal focus - i.e. for the inclusion of small focal shifts or for chromatic focusing.
Added delay term to polynomial spectral phase term
Added hack of axiprop stepper and propagatorFF2 classes to allow for building of x,z,omega or y,z,omega slices. This is like export_to_z but without summing over frequencies. This allows for subsequent changes to spectral phase when summing.
Re-ordered functions so that main functions are first
Fixed use of laser profile for building pulse in warped coordinates
Created test of farfield calculation comparing gaussian beam to analytical predication.
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.

1 participant