In the case where the group velocity is not constant, the phenomenon of wave packet spreading occurs.
Let us now look at a wave packet in a medium with a dispersion relation ω = α k2. The wave number spectrum A(k) was chosen to be rectangular for simplicity, centered around the wave number k0, with width Δk. The packet moves with group velocity vg = 2 α k0, which is twice the phase velocity vφ = α k0. The time evolution is given by the expression ψ(z,t) = ∫0∞ A(k) cos(αk2t–kz) dk, which we can express using the special functions of Fresnel integrals. Here is the resulting packet:

By performing a Galilean transformation we immobilize the packet:

And over a longer time horizon we observe its spreading:

And because the motion of the carrier wave is straining our eyes, we choose to render individual animation frames so that in one frame the carrier wave moves by exactly a multiple of its wavelength, i.e., time must be shifted by exactly Δt = λ0 / vφ = 2 π / (α k02) (and integer multiples of this time). The result:

Again over a longer time horizon:

And the packet has dispersed...
Source code: nb