Skip to main content

Raytrace module

Project description

Chromatic Confocal Sensor Ray Tracer

Specialized ray tracing engine designed for simulating and optimizing chromatic confocal sensors. This repository provides a powerful toolset for researchers and engineers working on precise optical measurement systems, enabling the accurate modeling of light interactions within chromatic confocal setups.

Defining the setup

The optical setup is defined inside the setup.py file. If, for example, an achromatic doublet is defined each face of both lenses should be defined as follows:

    "AC500-150-A-ML_1": {
        "Front Face": dict(
            curvature=96.85, konic=0, z_0=0, aperture_radius=50 / 2
        ),
        "Back Face": dict(
            curvature=-73.74,
            konic=0,
            z_0=9.5,
            aperture_radius=50 / 2,
        ),
        "Material": "BAK4",
        "Calibration": False,
    },
    "AC500-150-A-ML_2": {
        "Front Face": dict(
            curvature=-73.74, konic=0, z_0=9.5, aperture_radius=50 / 2
        ),
        "Back Face": dict(
            curvature=-241.63,
            konic=0,
            z_0=13.5,
            aperture_radius=50 / 2,
        ),
        "Material": "SF10",
        "Calibration": False,
    },
    "AC500-150-A-ML_1_R": {
        "Front Face": dict(
            curvature=241.63,
            konic=0,
            z_0=0,
            aperture_radius=50 / 2,
        ),
        "Back Face": dict(
            curvature=73.74, konic=0, z_0=4, aperture_radius=50 / 2
        ),
        "Material": "BAK4",
        "Calibration": False,
    },
    "AC500-150-A-ML_2_R": {
        "Front Face": dict(
            curvature=73.74,
            konic=0,
            z_0=4,
            aperture_radius=50 / 2,
        ),
        "Back Face": dict(
            curvature=-96.85, konic=0, z_0=13.5, aperture_radius=50 / 2
        ),
        "Material": "SF10",
        "Calibration": False,
    },
    "Sensor": {
        "Front Face": dict(
            curvature=float("inf"),
            konic=0,
            z_0=170,
            aperture_radius=100,
        ),
        "Back Face": dict(
            curvature=float("inf"),
            konic=0,
            z_0=170,
            aperture_radius=100,
        ),
        "Material": "SF2",
        "Calibration": False,
    },
} ```

## Lens materials

The materials available with their refractive indexes should be specified in a CSV file in the *data* folder as follows:

| wl_nm|intensity|n_BK7|n_SF2|n_SF5|n_BAF10|n_SF10|n_BAK4|n_SF57                                                                                          |
|---------------------------------------------------------------------------------------------------------------------------------------------------------|
| 500.5|0.0851431638|1.5213856439764|1.6587264318676913|1.6847781738090497|1.67825|1.74315|1.57468|1.86746                                                |
| 500.7|0.08645302802|1.5213723632237195|1.6586929033319964|1.6847437966326086|1.6782202524647911|1.7430968741556505|1.574659846238762|1.8673847333525386 |
| 500.8|0.08502408117|1.5213657288620468|1.658676166909398|1.684726608044388|1.6782055071330022|1.7430704823647605|1.5746498284981434|1.8673473595993073  |

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

confocal_raytracer-0.1.22.tar.gz (132.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

confocal_raytracer-0.1.22-py3-none-any.whl (125.4 kB view details)

Uploaded Python 3

File details

Details for the file confocal_raytracer-0.1.22.tar.gz.

File metadata

  • Download URL: confocal_raytracer-0.1.22.tar.gz
  • Upload date:
  • Size: 132.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.2 CPython/3.9.13 Windows/10

File hashes

Hashes for confocal_raytracer-0.1.22.tar.gz
Algorithm Hash digest
SHA256 95c764da074366f75d4c645156c8fae59fbe5a09a7cea34e5fa9aae7467c39e1
MD5 754c678962aa89600ab85794a4b3ffb4
BLAKE2b-256 738c6811bfe937bf57b35db7d1ac59bea0f897dcbe1a136030bcedfcc2e07d09

See more details on using hashes here.

File details

Details for the file confocal_raytracer-0.1.22-py3-none-any.whl.

File metadata

File hashes

Hashes for confocal_raytracer-0.1.22-py3-none-any.whl
Algorithm Hash digest
SHA256 53cda0fd5c1f3885958f0cae10b9eee99aa9114a6d3547a7ae834b124d6c8ad1
MD5 c55ef03a25381f71ea1aa9f1e3ec70cc
BLAKE2b-256 c1af4f1733717c7616a6d56796cc3a3643bc3a87e91412556948b4a6761f8c03

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page