@NilsBerglund
  @NilsBerglund
Nils Berglund | A gradient index lens with quadratic refractive index exposed to two light sources @NilsBerglund | Uploaded April 2024 | Updated October 2024, 4 hours ago.
This is a remake of the video youtu.be/KB_Roqs38F8 of a gradient index lens exposed to two sources. The difference is that here, the refractive index n(r) depends on the distance r to the horizontal symmetry axis of the lens in a quadratic way, like n(r) = n0 - a*r². In the previous simulation, it was taken by mistake to be of the form n(r) = sqrt(n0² - a*r²), that is, with a slower decrease that would become linear with large distance r.
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. Owing to the faster decrease of the refractive index, its value n0 in the center can be taken smaller: here it has value 1.25, as opposed to 1.82 in the previous video. The coefficient a is equal to 0.4375, making the refractive index smaller than 1 at the outer boundary of the lens, where r = 1. In order to visualize the refractive index as well, the luminosity of the background depends on the refractive index.
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 the square of the distance to the center (that is, it is of the form n0 - a*r², where r is the distance to the axis of symmetry, with n0 = 1.25 and a = 0.4375). 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:12
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 over a sliding time window.
There are absorbing boundary conditions on the borders of the simulated rectangle. The display at the right shows the signal along the focal plane, which is indicated by a vertical line.

Render time: 47 minutes 37 seconds
Compression: crf 25
Color scheme: Part 1 - Twilight by Bastian Bechtold
github.com/bastibe/twilight
Part 2 - Magma by Nathaniel J. Smith and Stefan van der Walt
github.com/BIDS/colormap

Music: "I Miss You" by Text Me Records / Leviathe@leviathe_

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
A gradient index lens with quadratic refractive index exposed to two light sourcesWinnowing: Separating particles by size using wind3D representation of a gradient index lens with quadratic refractive indexWaves of two different frequencies crossing a diffraction gratingA shallower laminar flow over an immersed dodecahedronHow does the particle size sorter work at very low friction?A hexagonal parabolic resonatorA more symmetric version of resonances in a circle excited by five out of phase sourcesDNA-like molecules in a boxAlmost a branched flow: Waves crossing a finer percolation-style arrangementMore stable vortices in Eulers equations on a rotating sphereVortices on a sphere like octahedral symmetry

A gradient index lens with quadratic refractive index exposed to two light sources @NilsBerglund

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER