Skip to content

Commit cd2c917

Browse files
committed
fix integrationCorrectionFactor
1 parent 83c5ada commit cd2c917

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/picongpu/include/fields/laserProfiles/laserPlaneWave.hpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ namespace picongpu
4242
* t = x/c and (x-x_0)/sigma = (t-t_0)/tau and k*(x-x_0) = omega*(t-t_0) with omega/k = c and tau * c = sigma
4343
* and get:
4444
* E = Phi_0*omega/c * exp(0.5 * (t-t_0)^2 / tau^2) * [sin(omega*(t - t_0) - phi) + t/(omega*tau^2) * cos(omega*(t - t_0) - phi)]
45-
* and define Phi_0*omega/c = E_0
45+
* and define:
46+
* E_0 = Phi_0*omega/c
47+
* integrationCorrectionFactor = t/(omega*tau^2)
4648
*
4749
* Please consider:
4850
* The above formulae does only apply to a Gaussian envelope. If the plateau length is
@@ -81,14 +83,14 @@ namespace picongpu
8183
( ( runTime - startDownramp )
8284
/ PULSE_LENGTH / sqrt( 2.0 ) );
8385
envelope *= exp( -0.5 * exponent * exponent );
84-
integrationCorrectionFactor = ( runTime - startDownramp )/ (2.0*PULSE_LENGTH*PULSE_LENGTH);
86+
integrationCorrectionFactor = ( runTime - startDownramp )/ (w*2.0*PULSE_LENGTH*PULSE_LENGTH);
8587
}
8688
else if ( runTime < endUpramp )
8789
{
8890
// upramp = start
8991
const double exponent = ( ( runTime - endUpramp ) / PULSE_LENGTH / sqrt( 2.0 ) );
9092
envelope *= exp( -0.5 * exponent * exponent );
91-
integrationCorrectionFactor = ( runTime - endUpramp )/ (2.0*PULSE_LENGTH*PULSE_LENGTH);
93+
integrationCorrectionFactor = ( runTime - endUpramp )/ (w*2.0*PULSE_LENGTH*PULSE_LENGTH);
9294
}
9395

9496
const double timeOszi = runTime - endUpramp;

0 commit comments

Comments
 (0)