Skip to main content

A simple Exposure Time Calculator for the Lux mission concept

Project description

Lux_Proposal Repository

This is a location for code under development for the Lux mission concept. Currently it contains a simple exposure time calculator.

Dependencies: numpy, pandas, astropy, matplotlib

NOTE: Currently (v0.0.1) only the optical channel is implemented, and sensitivities are based on current best estimates. This will be modified soon to include the UV and NIR channels, as well as sensitivies at requirement levels.

Installation: pip install luxetc

Usage:

In [1]: import luxetc

Instatiate a LuxETC object.

In [2]: x = luxetc.LuxETC()

Create a source with AB mag = 20.24.

In [3]: import astropy.units as u

In [4]: source = (20.24 * u.ABmag).to(u.erg / u.cm**2 / u.s / u.AA, u.spectral_d ⋮ ensity(luxetc.config.WAV))

Calculate the SNR for 100 s exposures in the g, r, and i-bands.

In [5]: x.get_snr(source, texps={"g": 100., "r": 100., "i": 100.}) Out[5]: {'g': np.float64(8.998968741725024), 'r': np.float64(6.431131860915084), 'i': np.float64(4.068752741726464)}

Calculate the necessary exposure time to achieve SNR = 9.0, 6.43, and 4.07 in g, r, and i-band (respectively).

In [6]: x.get_texp(source, snrs={"g": 9.0, "r": 6.43, "i": 4.07}) Out[6]: {'g': np.float64(97.27769274305454), 'r': np.float64(97.66486947726992), 'i': np.float64(96.48492257823999)}

Calculate the limiting magnitude for a given filter, exposure time, and SNR.

In [7]: x.get_limmag({"g": (100., 9.0), "r": (100., 6.43), "i": (100., 4.07)}) Out[7]: {'g': np.float64(20.258951551047254), 'r': np.float64(20.249997756265422), 'i': np.float64(20.259083138906384)}

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

luxetc-0.0.2.tar.gz (668.9 kB view details)

Uploaded Source

Built Distribution

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

luxetc-0.0.2-py3-none-any.whl (661.8 kB view details)

Uploaded Python 3

File details

Details for the file luxetc-0.0.2.tar.gz.

File metadata

  • Download URL: luxetc-0.0.2.tar.gz
  • Upload date:
  • Size: 668.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for luxetc-0.0.2.tar.gz
Algorithm Hash digest
SHA256 6df1ca84d282fff8f917a87948a1bf0adb509fe84ce5395f37f80c27f186bda3
MD5 2d5b965fe3e2e0c8f3c9e7f319fed64f
BLAKE2b-256 8af4be81326d44c215392a55ac9ec369147d390184b8b5107de9cb68417a5f6c

See more details on using hashes here.

File details

Details for the file luxetc-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: luxetc-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 661.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for luxetc-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 bbcc8c12cd4bc692ad870bf932747c53e54c8c9487959679bfcebfb29787de9b
MD5 58714d4078b34fff2b7b5b60b4812622
BLAKE2b-256 40df2cbe1eb2121aea46ede23b825b50391bcd0a7accea8738031c1c75e57715

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