Subject: Re: JEM-X misalignment Dear Carol Anne, > we're going to need a new misalignment matrix. ok, but you'll have to do it yourself this time, don't worry it's not complicated. > Basically: what is the data structure name? Where is it stored? How do > you > create one? What do we need as input data to the creation? How can we > ensure > that the correct misalignment matrix is used with the corresponding > version of > the software? Why isn't it part of the IMOD group? Thierry and I expected such questions, that's why a chapter of my phd is dedicated to this topic. This chapter is now ready and should appear on the isdc doc web page as a tech note soon. I'm attaching it to this email. Section 8.9 will answer your questions, see also points 1 and 2 below. Then to derive the new matrix, I suggest that you first skip sections 8.2 to 8.5 and read section 8.6 to have an idea of what you'll have to do. Then jump to the cookbook, section 8.10. Here are some advices: 1- if you recreate the aux branch as it is described in section 8.10, then you ensure that the matrix used is the one in this new (aux branch) location. The file copied there can include unity or non-unity matrices 2- when a reasonable matrix is obtained, I mean which improve the results with respect to the previous one, it can be ingested in the archive. The file will then receive a time stamp which ensure that this one ie the latest will be used in the future. Note that Roland has to agree with the results before allowing the ingestion 3- the very first thing to do is to select a bunch of pointings, from a source like grs1915+105 for example, as the Crab is not a point source in this X band. I took as much as 300 pointings. 4- then set an osa environment, recreate the aux branch and copy there the last matrix from the archive. Set the jemx1 and jemx2 matrices to unity: 1 0 0 0 1 0 0 0 1 and run the osa whith your prefered set of parameters. Note that for jemx I was using only pointings with attitude stable within 2.5''. You'll need a few days to complete this task. 5- once this is done, collect the results as stated in the cookbook and fill a "sources" file with the following columns: ra_catalog, dec_cat, ra_measured, dec_mes, ra_scx, dec_scx, ra_scz, dec_scz. I attached an example. 6-run misfit.cpp in isdcroot and make sure the matrix produced is copied in the fits file. The misfit.cpp attached is the one used with the files sources attached. 7-test it !!! Note, no need to run on 300 pointings this time. You can follow the steps made in section 8.6. The best is that you try and just ask your questions as they pop up, I'll try to react asap, hope this answer all your questions ! We'll stay in touch, Pascal > Best wishes for the successful completion of your thesis, thanks, it has been submitted now, I'm waiting on the Jury note: in misfit.cpp, you just have to update "numlines", the name of the fits file in DALobjectOpen("inst_misalign_20030701.fits[1]",&fitsfile,0); and nrow according to the jemx unit you are working on. Now the code starting after the comment "Display" can (and should) be customized according to your need, wishes etc. You start from the code existing there but I cannot garantee it will work on your data. In the end, I was always using other tools to plot the results as root can be a bit heavy and slow sometimes for this. -- Pascal Favre phone: +41 22 950 91 20 (direct) INTEGRAL Science Data Centre +41 22 950 91 00 (switchb.) Chemin d'Ecogia 16 fax: +41 22 950 91 33 CH-1290 Versoix e-mail: Pascal.Favre@obs.unige.ch Switzerland WWW: http://isdc.unige.ch