aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2017-08-23 15:17:49 +0800
committerAaron LI <aly@aaronly.me>2017-08-23 15:17:49 +0800
commite65379d62e5f92f96603775e8806ab32b97c60a9 (patch)
tree1c777eea56767b93e445bac5f03ca9e13d8acda7
parentd27d0118baff3287d298e4c035cc984e284cd9bf (diff)
downloadfg21sim-e65379d62e5f92f96603775e8806ab32b97c60a9.tar.bz2
galactic/synchrotron.py: Take absolute value on spectral index
-rw-r--r--fg21sim/galactic/synchrotron.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/fg21sim/galactic/synchrotron.py b/fg21sim/galactic/synchrotron.py
index 96f4df1..5881c4c 100644
--- a/fg21sim/galactic/synchrotron.py
+++ b/fg21sim/galactic/synchrotron.py
@@ -223,7 +223,8 @@ class Synchrotron:
logger.info("Simulating {name} map at {freq} ({unit}) ...".format(
name=self.name, freq=frequency, unit=self.freq_unit))
skymap_f = (self.template.data *
- (frequency / self.template_freq) ** self.indexmap.data)
+ (frequency/self.template_freq) **
+ (-np.abs(self.indexmap.data)))
#
if self.save:
filepath = self.output(skymap_f, frequency)