Feature #2143

ctselect: Galactic coordinates option

Added by Malyshev Dmitry almost 7 years ago. Updated over 6 years ago.

Status:NewStart date:
Priority:NormalDue date:
Assigned To:Cardenzana Josh% Done:

0%

Category:-
Target version:-
Duration:

Description

It would be useful, as an option, to have the input of the ROI center in ctselect in Galactic coordinates, similar to the input in csobsselect.

coordconvert.py Magnifier - python script for converting between galactic & celestial coordinates (1.22 KB) Cardenzana Josh, 07/02/2017 09:38 AM


Recurrence

No recurrence.

History

#1 Updated by Cardenzana Josh almost 7 years ago

Since this is a change to the user interface of one of the main tools, I want to discuss it with Jürgen before making any changes.

In the meantime, I’ve attached a script that should provide you with the ability to convert between galactic & celestial coordinates for input to the different tools. You can call it like this:

python coordconvert.py --xref=184.5575598670153 --yref=-5.78418983587635 --incoordsys=GAL

Converting GAL -> CEL:
   RA : 83.63330000007954
   DEC: 22.0144999999132

or
python coordconvert.py --xref 83.6333 --yref 22.0145 --incoordsys CEL

Converting CEL -> GAL:
   glon: 184.5575598670153
   glat: -5.78418983587635

#2 Updated by Knödlseder Jürgen over 6 years ago

I agree that the interface should accept both celestial and galactic coordinates. I suggest to add the following parameters to the par file:

coordsys,  s, a, CEL,CEL|GAL,, "Coordinate system (CEL - celestial, GAL - galactic)" 
ra,        r, a, 83.63,0,360, "Right Ascension of ROI centre (deg)" 
dec,       r, a, 22.01,-90,90, "Declination of ROI centre (deg)" 
glon,      r, a, 184.56,0,360, "Galactic longitude of ROI centre (deg)" 
glat,      r, a, -5.79,-90,90, "Galactic latitude of ROI centre (deg)" 

#3 Updated by Cardenzana Josh over 6 years ago

I’ve just done a quick 'audit’ of the tools that would be affected by making the 'ra,dec’ and 'glon,glat’ options standard across all tools:

Tools that appear to be ok:
  • csobsselect
Tools that take 'ra’,'dec’ only (no 'glon’ or 'glat’):
  • csfindobs
  • csobsinfo
  • cspull
  • cstsdist
  • ctcubemask
  • ctmodel
  • ctobssim
  • ctselect
Tools that take 'xref’,'yref’:
  • cslightcrv
  • csphasecrv
  • csresmap
  • cstsmapsplit
  • ctbin
  • ctbkgcube
  • ctedispcube
  • ctexpcube
  • ctmapcube
  • ctmodel
  • ctpsfcube
  • ctskymap
  • cttsmap

Regarding ctmodel (which has both ra,dec and xref,yref), 'ra,dec’ specifies the pointing when a single observation is input while xref,yref define the central position of the generated map. My suggestion would be to get rid of the ability to specify a single observation and require use of the 'inobs’ parameter for specifying observations. This is the functionality used in the other cube-generating tools. Does that sound reasonable?

I have a feeling that some of these tools are using the same functions from gammalib to set these parameters, so the number of changes may be small if we would like to update all tools.

Also available in: Atom PDF