domeckert / pyproffit

Pyproffit is a Python code for the analysis of X-ray brightness profiles from clusters of galaxies
GNU General Public License v3.0
18 stars 4 forks source link

Typo in profextract #11

Closed ghost closed 3 years ago

ghost commented 3 years ago

https://github.com/domeckert/pyproffit/blob/a911845c9ed39b1e37e811b8573be2ccc5540f8c/pyproffit/profextract.py#L457

Isn't the square in the wrong place here?

eprof[i] = np.sqrt(np.sum((img[id] / exposure[id] ) 2)) / nv / pixsize 2

domeckert commented 3 years ago

No the formula is correct. The variance of a Poisson number (here img[id]) is the Poisson number itself. Therefore only the denominator (exposure) needs to be squared.