Physipy can be coupled to many usefull package to have a great python physics framework
Handcalcs¶
from handcalcs import render
import handcalcs
from physipy import m, s, K, units, kg
mm = units["mm"]
import physipy
import sys
import warnings
if not sys.warnoptions:
warnings.simplefilter("ignore")
from numpy import exp
from physipy import quad, s, m, sr, K, units, constants
# physical constants
h_p = constants["h"]
c = constants["c"]
k_B = constants["k"]
sigma = constants["Stefan_Boltzmann"]
nm = units["nm"]
mum = units["mum"]
def planck(lmbda):
return 2*h_p*c**2/lmbda**5 * 1/(exp( (h_p * c) / (k_B * 300*K * lmbda)-1)) / sr
lmbda_start = 0.001*nm
lmbda_stop = 1000*mum
\begin{aligned}
a &= 2 \cdot x + 1 \cdot m = 2 \cdot 1.0\,m + 1 \cdot 1.0\,m &= 3.0\,m
\\[10pt]
b &= \left( y \right) ^{ 2 } + 100 \cdot \left( s \right) ^{ 2 } = \left( 2.0\,s \right) ^{ 2 } + 100 \cdot \left( 1.0\,s \right) ^{ 2 } &= 104.0\,s^{2}
\\[10pt]
c &= \sqrt { z \cdot y } = \sqrt { 3 \cdot 2.0\,s } &= 2.45\,s^{0.5}
\end{aligned}