Giter Site home page Giter Site logo

Comments (8)

ricktu288 avatar ricktu288 commented on June 19, 2024

Imagine you put a glass into water. You are not overlap the glass with the water, but are changing the shape of the water. If you submerge it into the water, the shape of the water becomes "a rectangle minus the shape of the glass". Therefore, the proper way to draw in this simulator is to first draw the "water" like this:
圖片
And then put a glass in the hole of the water.

Overlapping two glass objects should be considered as an undefined behavior of the simulator (we do not really overlap objects in real life). Currently, the actual behavior is that the refractive indices multiply in the overlapping region.

from ray-optics.

ricktu288 avatar ricktu288 commented on June 19, 2024

I think a more intuitive overlapping behavior is that the glass created later always replace the glass created first. But implementing that would be quite difficult. I think I will just add a notice to clarify the current behavior.

from ray-optics.

carlabarato avatar carlabarato commented on June 19, 2024

I get it. Maybe you can help me on this case?
I was trying to simulate this problem from my text book:
EVAU 4B julio 2009_2010_coincidentes

from ray-optics.

carlabarato avatar carlabarato commented on June 19, 2024

simulation for a)
Picture1

simulation for b)
Picture2

I made it using a half-plane. I see you are proposing a free-shape with a hole but I don't know how to do that?

Find attached json files:
a)
https://drive.google.com/file/d/13k9VBICYcUOVQ0tl1jlGPrYIzhW6ewEM

b)
https://drive.google.com/file/d/1m5zUL6EnIqZmDgFX3ICD-CGfBFw0DVkj

from ray-optics.

ricktu288 avatar ricktu288 commented on June 19, 2024

圖片

from ray-optics.

carlabarato avatar carlabarato commented on June 19, 2024

understood, thank you!

from ray-optics.

ricktu288 avatar ricktu288 commented on June 19, 2024

You can now use the slider to set the (relative) refractive index to less than one to simulate the inner material being less refractive than the outer material. No need to do what I described in the previous comment anymore.

from ray-optics.

carlabarato avatar carlabarato commented on June 19, 2024

I see. Thank you!

from ray-optics.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.