ricktu288 / ray-optics

A web app for creating and simulating 2D geometric optical scenes, with a gallery of (interactive) demos.
https://phydemo.app/ray-optics/
Apache License 2.0
1.15k stars 201 forks source link

Material overlap problem #137

Open morenara opened 3 weeks ago

morenara commented 3 weeks ago

Currently, the refractive index of overlapped area become addition between two refractive index. n_total = n1 + n2 = 1.5+1.5 = 3 It somehow makes sense, but most of the case, our intention of optical simulation is not merging (or fusing) materials, (We are not a material scientist!) but immersing one into the other. For example the glass ball in the tank of water.

Could you add some options for how to treat overlapped area?

  1. addition b/w materials
  2. selection one refractive index based on priority (similar as layer orders in other apps)
ricktu288 commented 3 weeks ago

The refractive indices multiply, not add.

Related to #37, #51, #109.