@NilsBerglund
  @NilsBerglund
Nils Berglund | 3D representation of a gradient index lens @NilsBerglund | Uploaded April 2024 | Updated October 2024, 1 hour ago.
This is a 3D representation of the simulation youtu.be/KB_Roqs38F8 showing the light of two point sources crossing a gradient index lens. The simulation is still two-dimensional, but the z-coordinate is used to represent a combination of the wave height or energy, and of the refractive index.
Several recent videos on this channel, such as youtu.be/CdpTq3dSrXA and youtu.be/aYvsBgyJgIE , showed planar waves crossing a gradient index lens. In this video, we look instead at two light sources that are located quite close to the lens. The lens is indeed able to focus the light on two spots located in the focal plane. In practice, one seldom has light sources located so close to the lens (except perhaps in macro photography), but this set-up was better suited to the simulation method used here. To be able to get such a small focal length, the refractive index has been chosen rather large in the center of the lens, with a value of 1.82.
The videos are inspired by Huygens Optics' recent short youtube.com/shorts/VGd3Ajnp6e0 showing the principle of a gradient index lens.
Lenses focus incoming rays of light by delaying them more near the center of the lens than at its periphery. This is often done with a material of constant index of refraction, by making the lens thicker near the center, as shown for instance in the simulation youtu.be/rrJJBh9ubUE . However, one can also build lenses of constant thickness, by making the index of refraction of their material depend on the location in the lens. In this simulation, the index decreases like sqrt(n0² - a*r²), where r is the distance to the axis of symmetry. This results in the incoming waves being focused at two points in the (estimated) focal plane, marked by a vertical line. The plot to the right shows a time-averaged value of the field along that plane.
This video has two parts, showing the same evolution with two different color gradients:
Wave height: 0:00
Averaged wave energy: 1:23
In the first part, the color hue depends on the height of the wave. In the second part, it depends on the energy of the wave, averaged from the beginning of the simulation. The z-coordinate shows the sum of the wave height or energy and of the local refractive index. There are absorbing boundary conditions on the exterior borders of the simulation.

Render time: 1 hour 35 minutes
Compression: crf 23
Color scheme: Part 1 - Viridis by Nathaniel J. Smith, Stefan van der Walt and Eric Firing
Part 2 - Plasma by Nathaniel J. Smith and Stefan van der Walt
github.com/BIDS/colormap

Music: "Cloud Patterns" by Silent Partner

See also https://images.math.cnrs.fr/Des-ondes-dans-mon-billard-partie-I.html for more explanations (in French) on a few previous simulations of wave equations.

The simulation solves the wave equation by discretization. The algorithm is adapted from the paper hplgit.github.io/fdm-book/doc/pub/wave/pdf/wave-4print.pdf
C code: github.com/nilsberglund-orleans/YouTube-simulations
https://www.idpoisson.fr/berglund/software.html
Many thanks to Marco Mancini and Julian Kauth for helping me to accelerate my code!

#wave #lens #gradient_index
3D representation of a gradient index lensClassics revisited: A hexagonal parabolic resonatorWaves of two different frequencies crossing a randomized square latticeSpeed and vorticity of a fluid on a rotating sphereSorting heptagons with a linear sieveAn asteroid impact in the Indian Ocean, with tsunami-induced floodingCoagulating falling squaresShallow water flowing over an immersed dodecahedronExciting spirals in a circle with sixteen out of phase sourcesTriangles on two conveyor beltsFalling pentagons pretending to be bestagonsMartian weather #mars #terraformingmars

3D representation of a gradient index lens @NilsBerglund

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER