Skip to main content

TestStatus PyPiStatus BlackStyle BlackPackStyle LicenseBadge

This python-packag is about the thin-lens-equation:

ImgThinLens

 1     1     1
--- = --- + ---
 f     g     b

The focal-length of the imaging-optics: f. The image-distance an image has from the aperture’s principal plane: b. The object-distance an object has from the aperture’s principal plane: g. The screen-distance a screen has from the aperture’s principal plane: d.

Note that the screen-distance d is not part of the thin-lens-equation. In case d != b the image on the screen is ‘out of focus’, thus blurred. Only when d == b the image on the screen is ‘in focus’, thus sharp.

Install

pip install thin_lens

Usage

import thin_lens

f = 1.0

b = thin_lens.compute_image_distance_for_object_distance(
    object_distance=100.0,
    focal_length=f,
)

assert b > f

print(b)

gives:

1.0101010101010102

Metadata

Release files for thin-lens 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for thin-lens 0.0.3
File Size Uploaded
thin_lens-0.0.3.tar.gz 4.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for thin-lens 0.0.3
File Interpreter ABI Platform
thin_lens-0.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 8.6 kB

Release files / thin_lens-0.0.3.tar.gz

Download URL thin_lens-0.0.3.tar.gz
Size 4.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6791aa6aee075220cc865d05c459fb0a251fd72435cdef9d959ba1c66c66119f
BLAKE2b-256 checksum
How to use checksums
1a9a1c28512d87e985f9afea61eac17fd7a525c0602f5e72f6631d281b91e574
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.12.4

Release files / thin_lens-0.0.3-py3-none-any.whl

Download URL thin_lens-0.0.3-py3-none-any.whl
Size 4.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
60332a6ccd0181a8fa7fe16e183988ea3b8f844daa02d36f3903729a75a957ac
BLAKE2b-256 checksum
How to use checksums
817c5ee7e53fa0d6db689fca0f63a6a1fb018b98960cf9e71c9438f69b274684
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.12.4

Release history Release notifications | RSS feed

This release

0.0.3 This release

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page