diff --git a/CHANGELOG.md b/CHANGELOG.md index b6b45fa52f..fe4dda2176 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ #Changelog for the fact-tools +## Version 0.14.1 -- 10.05.2016 +* Bug fix for the calculation of the source position in Monte Carlos: + * Corsika, Ceres and FACT-Tools are using different definitions of the Zd/Az coordinate systen. In FACT-Tools 0.14.0 we change to the definition used by Astropy, but a bug was left in the coordinate transformation for MCs. Now this transformation was changed to fit the definition used in Astropy +* Example XMLs to be used with the tourque/maui grid wrapper, called ERNA (https://github.com/fact-project/erna) + ## Version 0.14.0 -- 03.05.2016 * Bug fix for the calculation of the source position (and position of stars in the camera): diff --git a/examples/forErna/std_analysis_mc_erna.xml b/examples/forErna/std_analysis_mc_erna.xml new file mode 100644 index 0000000000..f59e0ce3b7 --- /dev/null +++ b/examples/forErna/std_analysis_mc_erna.xml @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pom.xml b/pom.xml index 2cf21b83cc..7c5c375699 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ de.sfb876 fact-tools fact-tools - 0.14.0 + 0.14.1 http://sfb876.de/fact-tools/ diff --git a/src/main/java/fact/features/source/SourcePosition.java b/src/main/java/fact/features/source/SourcePosition.java index fff0c29158..30d842487c 100644 --- a/src/main/java/fact/features/source/SourcePosition.java +++ b/src/main/java/fact/features/source/SourcePosition.java @@ -175,10 +175,10 @@ public Data process(Data data) { double pointingAz = Utils.valueToDouble(data.get(pointingAzKey)); double sourceZd = Utils.valueToDouble(data.get(sourceZdKey)); double sourceAz = Utils.valueToDouble(data.get(sourceAzKey)); - // Due to the fact, that Ceres handle the coordinate in a different way, we have to undo - // the coordinate transformation from Ceres - pointingAz = 180 - pointingAz; - sourceAz = 180 - sourceAz; + // Due to the fact, that Ceres handle the coordinate in a different way, we have to + // rotate the coordinate system by 180 deg such that 0 deg is north + pointingAz = 180 + pointingAz; + sourceAz = 180 + sourceAz; // Now we can calculate the source position from the zd,az coordinates for pointing and source double[] sourcePosition = getSourcePosition(pointingAz, pointingZd, sourceAz, sourceZd); data.put(outputKey, sourcePosition);