eblur / dust

For calculating dust scattering and extinction
8 stars 8 forks source link

Use caching to speed up bhmie algorithm #2

Open eblur opened 8 years ago

eblur commented 8 years ago

Instead of calculating the bessel function terms each time, use caching to store values so there are fewer repeated calculations.

Input terms: a (grain size), E (photon energy), n (index) -- see Van de Hulst or Bohren & Huffman

Compute S1 and S2 matrices of dimension a, E, n. Add along n-axis any time a new term is needed.

eblur commented 8 years ago

See branch speed_up_mie