Index: trunk/MagicSoft/Mars/mastro/MAstro.cc
===================================================================
--- trunk/MagicSoft/Mars/mastro/MAstro.cc	(revision 8725)
+++ trunk/MagicSoft/Mars/mastro/MAstro.cc	(revision 8765)
@@ -323,4 +323,36 @@
     // Perform the conversion
     return 1461L*lm10/4 + (306*((m+9)%12)+5)/10 - (3*((lm10+188)/100))/4 + d - 2399904;
+}
+
+// --------------------------------------------------------------------------
+//
+// Convert a mjd to a number yymmdd. The century is just cuts away, e.g.
+//   54393 -->  71020   (2007/10/20)
+//   50741 --> 971020   (1997/10/20)
+//   17868 -->  71020   (1907/10/20)
+//
+UInt_t MAstro::Mjd2Yymmdd(UInt_t mjd)
+{
+    UShort_t y;
+    Byte_t m, d;
+    Mjd2Ymd(mjd, y, m, d);
+
+    return d + m*100 + (y%100)*10000;
+}
+
+// --------------------------------------------------------------------------
+//
+// Convert a yymmdd number to mjd. The century is defined as 2000 for
+// yy<70, 1900 elsewise.
+//    71020 --> 54393 (2007/10/20)
+//   971020 --> 50741 (1997/10/20)
+//
+UInt_t MAstro::Yymmdd2Mjd(UInt_t yymmdd)
+{
+    const Byte_t   dd =  yymmdd%100;
+    const Byte_t   mm = (yymmdd/100)%100;
+    const UShort_t yy = (yymmdd/10000)%100;
+
+    return Ymd2Mjd(yy + (yy<70 ? 2000 : 1900), mm, dd);
 }
 
Index: trunk/MagicSoft/Mars/mastro/MAstro.h
===================================================================
--- trunk/MagicSoft/Mars/mastro/MAstro.h	(revision 8725)
+++ trunk/MagicSoft/Mars/mastro/MAstro.h	(revision 8765)
@@ -74,4 +74,7 @@
     static Int_t Ymd2Mjd(UShort_t y, Byte_t m, Byte_t d);
 
+    static UInt_t Mjd2Yymmdd(UInt_t mjd);
+    static UInt_t Yymmdd2Mjd(UInt_t yymmdd);
+
     static Double_t UT2GMST(Double_t ut1);
 
Index: trunk/MagicSoft/Mars/mastro/MAstroSky2Local.cc
===================================================================
--- trunk/MagicSoft/Mars/mastro/MAstroSky2Local.cc	(revision 8725)
+++ trunk/MagicSoft/Mars/mastro/MAstroSky2Local.cc	(revision 8765)
@@ -87,5 +87,5 @@
 //   C = RotY(r2)     (Make zenith and sky pole the same point)
 //
-//   D = RotZ(180deg) (Align rottaion angle to N=0, E=90)
+//   D = RotZ(180deg) (Align rotation angle to N=0, E=90)
 //
 // with
