Skip to main content

UBC Solar's Simulation Environment

Project description

UBC Solar Physics

Documentation Status

UBC Solar's physics and environment models for simulating our groundbreaking solar cars.

The API is currently unstable, and backwards compatibility may not be maintained.

Requirements

Versions indicated are recommended

  • Git [^1]
  • Python >=3.9 [^2]
  • Rustc >=1.79.0 [^3]
  • Cargo >=1.79.0 [^4]

Installation

First, clone this repository.

git clone https://github.com/UBC-Solar/physics.git

Then, create and activate a virtual environment. Next, install dependencies in editable mode.

pip3 install -e .

Getting Started

Example of calculating solar arrays produced energy

from physics.models.arrays import BasicArray
import numpy as np

efficiency = 0.25  # 25.0% efficient
panel_size = 4.0   # 4.0m^2 of panels
tick = 1.0         # 1.0s interval

arrays = BasicArray(panel_efficiency=efficiency, panel_size=panel_size)

irradiance = np.full([5], 400.0)  # 10 seconds of 400.0W/m^2 irradiance

solar_power_produced = arrays.calculate_produced_energy(solar_irradiance=irradiance, tick=tick)

assert np.array_equal(solar_power_produced, np.array([400.0, 400.0, 400.0, 400.0, 400.0]))

Appendix

[^1]: use git --version to verify version

[^2]: use python3 --version to verify version

[^3]: use rustc --version to verify version

[^4]: use cargo --version to verify version

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

ubc_solar_physics-1.1.0.tar.gz (36.4 kB view details)

Uploaded Source

Built Distributions

ubc_solar_physics-1.1.0-cp313-cp313-win_amd64.whl (197.0 kB view details)

Uploaded CPython 3.13 Windows x86-64

ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (353.6 kB view details)

Uploaded CPython 3.13 manylinux: glibc 2.17+ x86-64

ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (358.2 kB view details)

Uploaded CPython 3.13 manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

ubc_solar_physics-1.1.0-cp313-cp313-macosx_11_0_arm64.whl (298.7 kB view details)

Uploaded CPython 3.13 macOS 11.0+ ARM64

ubc_solar_physics-1.1.0-cp313-cp313-macosx_10_13_x86_64.whl (305.3 kB view details)

Uploaded CPython 3.13 macOS 10.13+ x86-64

ubc_solar_physics-1.1.0-cp312-cp312-win_amd64.whl (197.0 kB view details)

Uploaded CPython 3.12 Windows x86-64

ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (353.6 kB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (358.2 kB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

ubc_solar_physics-1.1.0-cp312-cp312-macosx_11_0_arm64.whl (298.7 kB view details)

Uploaded CPython 3.12 macOS 11.0+ ARM64

ubc_solar_physics-1.1.0-cp312-cp312-macosx_10_9_x86_64.whl (305.3 kB view details)

Uploaded CPython 3.12 macOS 10.9+ x86-64

ubc_solar_physics-1.1.0-cp311-cp311-win_amd64.whl (196.9 kB view details)

Uploaded CPython 3.11 Windows x86-64

ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (353.7 kB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (359.1 kB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

ubc_solar_physics-1.1.0-cp311-cp311-macosx_11_0_arm64.whl (298.4 kB view details)

Uploaded CPython 3.11 macOS 11.0+ ARM64

ubc_solar_physics-1.1.0-cp311-cp311-macosx_10_9_x86_64.whl (306.6 kB view details)

Uploaded CPython 3.11 macOS 10.9+ x86-64

ubc_solar_physics-1.1.0-cp310-cp310-win_amd64.whl (197.1 kB view details)

Uploaded CPython 3.10 Windows x86-64

ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (353.6 kB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (359.0 kB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

ubc_solar_physics-1.1.0-cp310-cp310-macosx_11_0_arm64.whl (298.2 kB view details)

Uploaded CPython 3.10 macOS 11.0+ ARM64

ubc_solar_physics-1.1.0-cp310-cp310-macosx_10_9_x86_64.whl (306.5 kB view details)

Uploaded CPython 3.10 macOS 10.9+ x86-64

ubc_solar_physics-1.1.0-cp39-cp39-win_amd64.whl (197.2 kB view details)

Uploaded CPython 3.9 Windows x86-64

ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (354.4 kB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (359.2 kB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

ubc_solar_physics-1.1.0-cp39-cp39-macosx_11_0_arm64.whl (299.2 kB view details)

Uploaded CPython 3.9 macOS 11.0+ ARM64

ubc_solar_physics-1.1.0-cp39-cp39-macosx_10_9_x86_64.whl (306.5 kB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

File details

Details for the file ubc_solar_physics-1.1.0.tar.gz.

File metadata

  • Download URL: ubc_solar_physics-1.1.0.tar.gz
  • Upload date:
  • Size: 36.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for ubc_solar_physics-1.1.0.tar.gz
Algorithm Hash digest
SHA256 36b46d141cf6eac842eacf0eef9e726e3c46830e710011f752325ef73b4e6153
MD5 431d2bde76530f1be325d0d3b4ada023
BLAKE2b-256 82d507abb8c5a78780998dec6d4ff78410ffe5c184e79bd0406397de14af907b

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 1276f222b176138acebe853b393ec5cdda472e567f346c1d3bc950f7e066b04a
MD5 4c91d6c770dcac8f372c5684603d6cd7
BLAKE2b-256 c7f1a8e39e57eb25876480542f50852f5d810fa1baece51fcd5c22051dc0895c

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a66ef3bbb9aba8504ef74b1be818b5b8cdae3f5daa6a53c221bbc982b6713bee
MD5 29b43217d882f1d809b6b89d36b15000
BLAKE2b-256 cef33c6104e3388b9f1f85daf74b573ba55f4163a0ee478ae3fb46590e322184

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 7afa8544914d03d7281c6f8fd5b8e7ae322ad6f1e868d49e277af4e1c7012edd
MD5 5b50ba4a00d7ab4680ac6d0b20786d92
BLAKE2b-256 4ef951e9aa11b9fc57fcbdf1baf696f14aa2cf7ed740da4dd898587bf3a1b9e3

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1b5ed46570fdee9119a5eedc72d5f48132412884d6b1637145fb461ff201fdeb
MD5 f1b94cc2d882432006d495c99216f61b
BLAKE2b-256 55907029026e9863086f7aa811aea2bc3ab06c89f33b031ba847968b774d1eeb

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp313-cp313-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp313-cp313-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 dd4ef433f2bae2dee252d20cac2d7bd911e23f9725536030e77cf26f5579b84b
MD5 756337f0b6fde2a3a67cab7e592c21e0
BLAKE2b-256 453d145dd77d3ede5aabe9d89afd56cec0edb2d0aa875f24c99a58682949208e

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 1a36fafbaf9cca9fce02519afc1977198ddfb75b6cdb43530b02da424780b6df
MD5 9d655e5f87e7bd4cee5708b88c3dd0d9
BLAKE2b-256 7f4c43202f76a4efcee90f4e8c667d1352c122ea680559dd357f5ec0f173cda3

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 befbfa4e345b66371027a51b4147774e4b0f5049b88729b13dae727e53765a75
MD5 34476f0bd49ef3106ee2f247f9f94b69
BLAKE2b-256 f230b38e9ac541d623c9f938ef57326a02dcc65a8958718e49c165c0dbc8acb2

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 7b25d6152ab9986a8d17f2c98f3ff8cabf78fbd7a84945ffb3555438b21d9583
MD5 e5bea031167b5e71abc5c1414a64e151
BLAKE2b-256 2cdeaf2d168f8f0022712020ddf11c3e76971ecc9a2dc8b01887f0a5b115ae65

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 74238ad3270f839d7178aa50d23ec0181c360a6a73f46965eaa6605c7dcb1bfc
MD5 9f805624853013313247664b48e78529
BLAKE2b-256 0130fc12e063e18f37b7d30b00c86c9295e7bcb43bdbd3bd8fe413c5cf741697

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp312-cp312-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp312-cp312-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 a887bdcaff331a9d181866e65581a9646d6fd153aa0bad342bcfcf55f78c2ee7
MD5 52790b2c2587f640549cfbe1b3ea2a77
BLAKE2b-256 ba14fee6fb05779c736f9f5645c059376076ff8a685a9f70d032ee76e40c5f30

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 ab5df16b8cc6d3c53c8f19feb19df4462fc77f82388553ab06b35a92dfcb5f98
MD5 4128b5014771c16e17a53f5b1357aa4a
BLAKE2b-256 3f853a65e5e060ce76343ba8de4820546f9823a45b28564c138698248a446c2c

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 4d18be1a8331dd6eacbcd3d750f00a94a748bd9928b8c2f91f9c8e4e20fcc33b
MD5 27eef6ad6584aa75e0185e05907ea09e
BLAKE2b-256 8c9c0fbfc76d4689f8cb200476ecc01912b3c26ded51c5b7cf04dbe870153cd1

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 8ed72aa9a89d5da363cd7c372fc80ca9b71b9222851111f69d7e2f83d62319b5
MD5 04fe16aac8b410018e9728076c12d563
BLAKE2b-256 8871e441c31a376b0f43c253418631615d0d10c5ac18b87bad81d72a2186e3c1

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 09b8964f7ed42f052d7d5dc348011d7b23013d34c3cfd645a6d6715873a543b7
MD5 2eb5a1b3212e4ce3acd0ff7116f18eab
BLAKE2b-256 9e04c2d56771d452504690a4da4de157e9ac6424be447a85c3f243873103d6c1

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp311-cp311-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 40edd46fd9ca2d2e17e33a282f5e4b7e0173d9a46dd4651c37fa62b0a0e81a08
MD5 700974d41aec6564975b6394dd7c272a
BLAKE2b-256 d708c169c12991876ea0a8298a0288381848d7d92a4c0f6a4cab81c73f2658f5

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 214e88bcec2de7aad56ddb69dee1bc1460cb4a9fdc4458e3bbb50f531edc851a
MD5 e6d053d953f987b08ee5b5c4cb8841be
BLAKE2b-256 47b8c663f2146c89d1b86f0a498ed9b439146fb2520cf5163b73e9d521242e6d

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1ef67dcad65a110e71afa404fbe27bbb6ac72c27d42f7aac7325e8308018daa8
MD5 f486aa2dbdf8435d8274bc8b92b67428
BLAKE2b-256 94a0bd997960b47c5564aa248b3ef31a50c502c094692e46712c199f389b7569

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 6003edd522531c19da6edfc263fc083b9119010502667d44fc01b736c1d543c0
MD5 0b5a11774125d08037008b692b41716f
BLAKE2b-256 6afd9ac9c7644dfc30357b135c4e8026f54d92d4c489a1196d4d07bb21cacbdc

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 18a0428862b9229f36cf73ad62a86d3db4923db0ea9bcc8f18b1a13e55e83b45
MD5 0ebf67225e7378f09cab55f653aa085f
BLAKE2b-256 a0e9675c8bf6d23f75be02d502c669a35dcb69ecfc98dbd50827e7a84a733c9f

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 d9fea7aeddad3a6645e2ff432c8e2bca455c4cca4f5d7f3ba37faa15f31bba8b
MD5 d2911df7b3c5455876b4b7ac787bc9dd
BLAKE2b-256 f2da33c1fa7b70db9a7ce1c22c4350ada3ee91fa21994f8758f3f4240a6cf77f

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 5326f9ef2372338003da3be0e8ce9eb19385cf3110e9bf595b487b7c132da202
MD5 beaa08af1989220b27e1b4cda75604dd
BLAKE2b-256 5bbadd1bede8ac6a31cf90cf97c80a59ea73ea9cf9fc312c008dcc30f6e72cda

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 8f2f2ab3db259b4717ef9bb6743205e9d7c4dcf333ddfd3d418019c5eb908d99
MD5 856f9c886ef104093105111e1045df01
BLAKE2b-256 e8f5bdc028ff4585348f9259331533bf32e0e24c0738d67d374c3d7b4f37d826

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 f1eb1ce701ddc1d66275b40cc6abb4b2e657bd9cb8e2a15a351a747cb010ecba
MD5 d7ac5efaca1f2c93171972a85b2d44d5
BLAKE2b-256 07413a0cfd18e89974407636f0770911fa01f43493479320acc86c925fd040f9

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 152d2c06b0017147696f685847d72256cd8d76a9a0b22d0aa368a2bcd4a0adc1
MD5 fcbfddf2727e3d135284d4e91d3dbfd3
BLAKE2b-256 cd8629fada3551cb52b12b399e93289a0e146ce1cf061bc7895668ad701d7074

See more details on using hashes here.

File details

Details for the file ubc_solar_physics-1.1.0-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for ubc_solar_physics-1.1.0-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 c607a681be3a9d7501001dc8dd044fcb3d84f211c486368566940355b1f75ecd
MD5 c823e9dcdbbdea25a4a94795c2d2a67b
BLAKE2b-256 0fbe3ce5a68c77d99391a5d66d102e7a7c7a4e1662b37db150f29a3844f0573c

See more details on using hashes here.

Supported by

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