Sovereign 8s.is mirror of standardgalactic/discmodel
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Michael Petersen 304866fbfa
Some checks failed
Tests / test (macos-latest, 3.10) (push) Has been cancelled
Tests / test (macos-latest, 3.11) (push) Has been cancelled
Tests / test (macos-latest, 3.12) (push) Has been cancelled
Tests / test (ubuntu-latest, 3.10) (push) Has been cancelled
Tests / test (ubuntu-latest, 3.11) (push) Has been cancelled
Tests / test (ubuntu-latest, 3.12) (push) Has been cancelled
Tests / test (windows-latest, 3.10) (push) Has been cancelled
Tests / test (windows-latest, 3.11) (push) Has been cancelled
Tests / test (windows-latest, 3.12) (push) Has been cancelled
Merge pull request #2 from michael-petersen/main
Improve coverage, setup to ignore flex
2025-11-25 17:32:57 +00:00
.github/workflows add more coverage 2025-11-25 16:33:38 +00:00
src/discmodel add more coverage 2025-11-25 16:33:38 +00:00
tests Update tests/test_discmodel.py 2025-11-25 17:28:03 +00:00
.gitignore make flex and lintsampler optional 2025-11-07 13:00:42 +00:00
LICENSE first commit 2025-11-07 11:53:14 +00:00
pyproject.toml make flex and lintsampler optional 2025-11-07 13:00:42 +00:00
pytest.ini add more coverage 2025-11-25 16:33:38 +00:00
README.md check flex installation 2025-11-12 11:34:26 +00:00
setup.py first commit 2025-11-07 11:53:14 +00:00
test_requirements.txt check flex installation 2025-11-12 11:34:26 +00:00

discmodel

Simple exponential disc generation for testing galaxy morphology routines.

License: MIT Coverage Status

Installation

Installation of discmodel currently proceeds from local builds after cloning this repository:

git clone https://github.com/ObservationalExpansions/discmodel.git
pip install .

Quickstart example

import discmodel

N= 1_000_000
a = 1.0
M = 1.0
rmax = 5.0
nbins = 100
mmax,nmax = 2,8

# generate N distributed points
D = discmodel.DiscGalaxy(N=N, a=a, M=M)
D.generate_image(rmax=rmax, nbins=nbins)

# now you have
D.img