1
1
/* *
2
- * Copyright 2013-2015 Axel Huebl, Heiko Burau, Rene Widera, Richard Pausch
2
+ * Copyright 2013-2015 Axel Huebl, Heiko Burau, Rene Widera, Richard Pausch, Stefan Tietze
3
3
*
4
4
* This file is part of PIConGPU.
5
5
*
@@ -30,6 +30,9 @@ namespace picongpu
30
30
/* * not focusing wavepaket with spacial gaussian envelope
31
31
*
32
32
* no phase shifts, just spacial envelope
33
+ * including correction to laser formular derived from vector potential, so the integration
34
+ * along propagation direction gives 0
35
+ * this is important for few-cycle laser pulses
33
36
*/
34
37
namespace laserWavepacket
35
38
{
@@ -56,6 +59,9 @@ HINLINE float3_X laserLongitudinal(uint32_t currentStep, float_X& phase)
56
59
const double endUpramp = -0.5 * LASER_NOFOCUS_CONSTANT;
57
60
const double startDownramp = 0.5 * LASER_NOFOCUS_CONSTANT;
58
61
62
+ const double tau = PULSE_LENGTH / sqrt (2.0 );
63
+
64
+ double correctionFactor = 0.0 ;
59
65
60
66
if (runTime > startDownramp)
61
67
{
@@ -64,28 +70,30 @@ HINLINE float3_X laserLongitudinal(uint32_t currentStep, float_X& phase)
64
70
((runTime - startDownramp)
65
71
/ PULSE_LENGTH / sqrt (2.0 ));
66
72
envelope *= math::exp (-0.5 * exponent * exponent);
73
+ correctionFactor = (runTime - startDownramp)/(tau*tau*w);
67
74
}
68
75
else if (runTime < endUpramp)
69
76
{
70
77
// upramp = start
71
78
const double exponent = ((runTime - endUpramp) / PULSE_LENGTH / sqrt (2.0 ));
72
79
envelope *= math::exp (-0.5 * exponent * exponent);
80
+ correctionFactor = (runTime - endUpramp)/(tau*tau*w);
73
81
}
74
82
75
83
phase += float_X (w * runTime) + LASER_PHASE;
76
84
77
85
if ( Polarisation == LINEAR_X )
78
86
{
79
- elong.x () = envelope * math::sin (phase);
87
+ elong.x () = float_X ( envelope * ( math::sin (phase) + correctionFactor * math::cos (phase)) );
80
88
}
81
89
else if ( Polarisation == LINEAR_Z )
82
90
{
83
- elong.z () = envelope * math::sin (phase);
91
+ elong.z () = float_X ( envelope * ( math::sin (phase) + correctionFactor * math::cos (phase)) );
84
92
}
85
93
else if ( Polarisation == CIRCULAR )
86
94
{
87
- elong.x () = envelope / sqrt (2.0 ) * math::sin (phase);
88
- elong.z () = envelope / sqrt (2.0 ) * math::cos (phase);
95
+ elong.x () = float_X ( envelope / sqrt (2.0 ) * ( math::sin (phase) + correctionFactor * math::cos (phase)) );
96
+ elong.z () = float_X ( envelope / sqrt (2.0 ) * ( math::cos (phase) + correctionFactor * math::sin (phase)) );
89
97
}
90
98
91
99
return elong;
0 commit comments