LASY-org / lasy

https://lasydoc.readthedocs.io
Other
33 stars 24 forks source link

Analyzing lasy generated file #291

Open koesterf opened 3 months ago

koesterf commented 3 months ago

Hi,

I want to analyze the complicated laser envelope I am trying to prepare with the help of Lasy. It might be helpful to make sure that all is well.

To do so, I am trying to visualize the hdf5 file generated with lasy ('lasy_laser_00000.h5') as follows:

from openpmd_viewer import OpenPMDTimeSeries
from openpmd_viewer.addons import LpaDiagnostics
import numpy as np
import matplotlib.pyplot as plt

TS = OpenPMDTimeSeries('lasy_laser_00000.h5')
TS_2d = LpaDiagnostics('lasy_laser_00000.h5')

Env = TS.get_field(field='laserEnvelope', iteration=0, plot=True, cmap='Blues_r')

Could you let me know what other variables I can plot and check. I am particularly interested to see how the spectrum of the laser pulse looks like (as done in FBPIC)

Thanks. Frank

koesterf commented 2 months ago

It would be extremely helpful for the user if laser pulse parameters can be checked after constructing it with lasy.

For instance,

1). Laser strength parameter (a0), 
2). pulse duration, 
3). waist or FWHM of transverse size, 
4). 1-D electric field and time or spatial coordinate, so that further analysis can be made.