text: 
  long double DTR = 1.74532925199432957692E-2L;
  long double RTD = 5.72957795130823208768E1L;
  long double RTS = 2.06264806247096355156E5L; /* arc seconds per radian */
  long double STR = 4.84813681109535993590E-6L; /* radians per arc second */
  long double PI  = 3.14159265358979323846L;
  /* Standard epochs.  Note Julian epochs (J) are measured in
   * years of 365.25 days.
   */
  long double J2000 = 2451545.0L;	/* 2000 January 1.5 */
  long double B1950 = 2433282.423L; /* 1950 January 0.923 Besselian epoch */
  long double J1900 = 2415020.0L;	/* 1900 January 0, 12h UT */
  long double B1900 = 2415020.313L;
  
  long double Jcentury = 3.6525e4L; /* 1 Julian century */
  long double Jmillenium = 3.6525e5L;
  long double Jtmillenium = 3.6525e6L;
  
  /* These are defined in polevll.c.  */
  #if 0
  long double Zero = 0.0L;
  long double Fourth = 0.25L;
  long double Half = 0.5L;
  long double One = 1.0L;
  long double OneandaHalf = 1.5L;
  long double Two = 2.0L;
  long double Three = 3.0L;
  long double ThreeandaHalf = 3.5L;
  long double Four = 4.0L;
  long double Five = 5.0L;
  long double Six = 6.0L;
  long double Ten = 10.0L;
  #endif
  
  /* Solar system barycentric velocity and position
   * state of Mercury, Venus, EMB, ..., Pluto, MOON, Sun
   * in the order dx/dt, x, dy/dt, y, dz/dt, z for each object.
   *
   * EMB is the arithmetic average of Earth and Moon, weighted by
   * their masses. The coordinates of the Moon variable are the
   * the solar system barycentric coordinates of the Moon
   * minus those of the Earth.
   */
  
  /* Note, these particular numbers are derived from the heliocentric
   * planet states and barycentric Sun state given in the
   * documentation for the DE118.
   */
  
  /* June 28.0, 1969 */
  long double JD0 = 2440400.50L;
  
  long double yn0[6*NTOTAL] = {
  /* Lunar librations */
   1.00015500951082782e-4L,
   6.03343019729665792e-3L,
   1.49039876740924137e-5L,
   3.82393007236771923e-1L,
  -1.19434270765326686e-4L,
   1.28120436555489181e0L,
  /* Mercury */
   3.7085069798210382186e-003L,
   3.6030663368975339466e-001L,
   2.4854958767430945324e-002L,
  -9.4812876741771684223e-002L,
   1.2929109014677844626e-002L,
  -8.7466840117233140436e-002L,
  /* Venus */
   1.1156645711264016669e-002L,
   6.0786466491731583464e-001L,
   1.5494075513638794325e-002L,
  -3.5518362463675619232e-001L,
   6.2773904546696609267e-003L,
  -1.9824142909855515515e-001L,
   /* EMB */
   1.6833251020051496668e-002L,
   1.0820747754938311664e-001L,
   1.5602036176919105255e-003L,
  -9.2711110739430602933e-001L,
   6.7646174015847273137e-004L,
  -4.0209347855944090112e-001L,
  /* Mars */
   1.4481919298277924969e-002L,
  -1.2796408611369531836e-001L,
   8.0528538390447499843e-005L,
  -1.3262618005333617013e+000L,
  -3.5188931029397090065e-004L,
  -6.0530808652523961512e-001L,
  /* Jupiter */
   1.0053452569924098185e-003L,
  -5.3896824544609061333e+000L,
  -6.5298425191689416643e-003L,
  -7.7026549518616593034e-001L,
  -2.8258787532429609536e-003L,
  -1.9866431165907522014e-001L,
  /* Saturn */
  -3.1594662504012930114e-003L,
   7.9527768530257360864e+000L,
   4.3714634278372622354e-003L,
   4.5078822184006553686e+000L,
   1.9441395169137103763e-003L,
   1.5201955253183338898e+000L,
  /* Uranus */
   1.7108310564806817248e-004L,
  -1.8278236586353147533e+001L,
  -3.7646704682815900043e-003L,
  -9.5764572881482056433e-001L,
  -1.6519678610257000136e-003L,
  -1.6132190397271035415e-001L,
  /* Neptune */
   2.6225242764289213785e-003L,
  -1.6367191358770888335e+001L,
  -1.5277473123858904045e-003L,
  -2.3760896725373076342e+001L,
  -6.9183197562182804864e-004L,
  -9.3213866179497290101e+000L,
  /* Pluto */
   2.8177758090360373050e-004L,
  -3.0447680255169362534e+001L,
  -3.1469590804946202045e-003L,
  -5.3177934960261367037e-001L,
  -1.0794238049289112837e-003L,
   9.0596584886274922101e+000L,
  #if EXTRA_BODY
  /* Fictitious asteroid */
   0.0e0L,
   3.0e0L,
   1.0e-2L,
   0.0e0L,
   0.0e0L,
   0.0e0L,
  #endif
  #if MOON
   5.98752118417335956e-4L,
  -8.35703164195952601e-4L,
  -1.74153713527242722e-4L,
  -1.98543915768166071e-3L,
  -8.84771962437116281e-5L,
  -1.08326877048661754e-3L,
  #endif
  /* Sun */
  -2.8369446340813151639e-007L,
   4.5144118714356666407e-003L,
   5.1811944086463255444e-006L,
   7.2282841152065867346e-004L,
   2.2306588340621263489e-006L,
   2.4659100492567986271e-004L,
  /* Asteroid states follow */
  };
  
  
  
  /* Test state, 100 days later: */
  #if 0
  long double JD1 = 2440500.50L;
  
  long double yn1[6*NTOTAL] = {
  -3.85893930164594646e-5L,
   1.29694398195755468e-2L,
   1.14905257263582262e-5L,
   3.82508699238156682e-1L,
   4.75391383166468672e-5L,
   1.27428371119265801e0L,
  
  -2.43015281791706444e-002L,
   2.40773527079857565e-001L,
   1.87910251556777273e-002L,
   1.96954621939863219e-001L,
   1.25591312851252066e-002L,
   8.10048178490518384e-002L,
  
  -1.63440955802718280e-002L,
  -4.21860322028048782e-001L,
  -1.14246422850682140e-002L,
   5.17869026250609690e-001L,
  -4.11622909296383714e-003L,
   2.60203829195766570e-001L,
  
  -3.94484632235194096e-003L,
   9.81177706008309405e-001L,
   1.53727031456690289e-002L,
   1.96484576859672724e-001L,
   6.66612671337020014e-003L,
   8.51297144135776147e-002L,
  
   8.50596535330489333e-003L,
   1.14162585220489816e+000L,
   1.16329928693268469e-002L,
  -7.02290330317807430e-001L,
   5.11130674190038601e-003L,
  -3.52984793305744779e-001L,
  
   1.97739891612302323e-003L,
  -5.24031415190823051e+000L,
  -6.33006771988879063e-003L,
  -1.41424053721658884e+000L,
  -2.76393462026492719e-003L,
  -4.78580847895956282e-001L,
  
  -3.45070902605290058e-003L,
   7.62218572268596801e+000L,
   4.19480008161587867e-003L,
   4.93634138197818904e+000L,
   1.88368464231530789e-003L,
   1.71165065659011950e+000L,
  
   2.59339002502375430e-004L,
  -1.82567140746315272e+001L,
  -3.75914213576224408e-003L,
  -1.33385143258585295e+000L,
  -1.65079191573496991e-003L,
  -3.26466517509008289e-001L,
  
   2.63977839373647663e-003L,
  -1.61040739057229584e+001L,
  -1.50241016013489575e-003L,
  -2.39124059584972814e+001L,
  -6.81887221476645979e-004L,
  -9.39007319300685950e+000L,
  
   3.09967640221318611e-004L,
  -3.04180939220586550e+001L,
  -3.14632190270354497e-003L,
  -8.46445850516399332e-001L,
  -1.08776892324236050e-003L,
   8.95129835863062695e+000L,
  #if EXTRA_BODY
  /* Fictitious asteroid */
   0.0e0L,
   3.0e0L,
   1.0e-2L,
   0.0e0L,
   0.0e0L,
   0.0e0L,
  #endif
  #if MOON
  -4.22681402426694080e-4L,
  -1.72474926563029233e-3L,
  -3.21609581451700993e-4L,
   1.82647356024942241e-3L,
  -1.82676776570974036e-4L,
   9.67995005426182924e-4L,
  #endif
  -9.96208174079740373e-007L,  /* rotated from DE200 */
   4.45122038203489470e-003L,
   5.06057698826071977e-006L,
   1.23363163514498492e-003L,
   2.19376032512757903e-006L,
   4.67156762898216060e-004L,
  };
  #endif /* 0 */
  
  #if 1
  long double JD1 = 2440800.50L;
  
  long double yn1[6*NTOTAL] = {
   1.19798509852348462e-4L,
   3.26749396278042651e-2L,
  -6.85863913398886621e-5L,
   3.85255316277713118e-1L,
  -9.87921606265917336e-5L,
   1.25594900035445747e0L,
  
   1.1640059959070938016e-002L,
  -3.4350297408563828055e-001L,
  -1.7964875644231269124e-002L,
  -2.5118910315168408963e-001L,
  -1.0817311005210173814e-002L,
  -9.9170891227838064646e-002L,
  
   1.8597282203783061216e-002L,
  -2.6914630075961837156e-001L,
  -6.5864799228651037249e-003L,
  -6.1655661757510340864e-001L,
  -4.1428517490915759141e-003L,
  -2.6070731202257053265e-001L,
  
   1.3083581197550196016e-002L,
   6.4260215465460413745e-001L,
   9.8846107560980890857e-003L,
  -7.2083597294516633464e-001L,
   4.2862797207098424858e-003L,
  -3.1263839868006851566e-001L,
  
  -1.0289202815795734684e-002L,
  -1.0394941428468679346e+000L,
  -7.0723334989418045152e-003L,
   1.1522403836312279294e+000L,
  -2.9703138309275424941e-003L,
   5.5677401157133424433e-001L,
  
   4.6228653666202124358e-003L,
  -4.2373615722355993645e+000L,
  -5.0555918692615562352e-003L,
  -3.1464733091277224306e+000L,
  -2.2818455722493645242e-003L,
  -1.2462241659031373286e+000L,
  
  -4.2556740044874090445e-003L,
   6.4633979534971069954e+000L,
   3.5633047172379600052e-003L,
   6.1037564142437140792e+000L,
   1.6573768541155527860e-003L,
   2.2444618449141959815e+000L,
  
   5.2274776790945661154e-004L,
  -1.8139340904007687965e+001L,
  -3.7317457890160985748e-003L,
  -2.4578888288247007605e+000L,
  -1.6425078479167742140e-003L,
  -8.2063943185823257564e-001L,
  
   2.6898588576179062356e-003L,
  -1.5304564931392374665e+001L,
  -1.4254385368896515149e-003L,
  -2.4351618762495032811e+001L,
  -6.5161737589378315099e-004L,
  -9.5901150170962550989e+000L,
  
   3.9518201228036738355e-004L,
  -3.0312344985766555864e+001L,
  -3.1426251869952901448e-003L,
  -1.7898553889579568107e+000L,
  -1.1124350707669052540e-003L,
   8.6212535443336042115e+000L,
  #if EXTRA_BODY
  /* Fictitious asteroid */
   0.0e0L,
   3.0e0L,
   1.0e-2L,
   0.0e0L,
   0.0e0L,
   0.0e0L,
  #endif
  #if MOON
  -4.58408893102436927e-4L,
  -1.60130208907259920e-3L,
  -2.78697065392994499e-4L,
   1.95720839700677492e-3L,
  -1.70697259101564644e-4L,
   9.68483037769266028e-4L,
  #endif
   /* rotated from DE200 */
  /*
  -3.44322101864905357e-006L,
   3.77983010651375442e-003L,
   4.03605242892639870e-006L,
   2.63055823065286220e-003L,
   1.81002374725178528e-006L,
   1.08188006521861207e-003L,
  */
  -3.4432210186490844452e-006L,
   3.7798301065137354516e-003L,
   4.0360524289263751236e-006L,
   2.6305582306528893588e-003L,
   1.8100237472517860139e-006L,
   1.0818800652186113487e-003L,
  };
  #endif /* 1 */
  
  
  /* Speed of light.
   */
  /* DOUBLE CLIGHT = (DOUBLE)2.99792458e5; */
  long double C = 173.144632720536344565L;
  
  /* Earth's mass divided by Moon's mass
   */
  #define EMRATd 8.13005869999999999376E1L
  long double EMRAT = EMRATd;
  
  /* Gaussian gravitational constant */
  long double KG = 0.01720209895L;
  
  /* GM's of the solar system bodies
   * These are scaled such that GMsun = k^2
   * (k = Gaussian gravitational constant).
   */
  long double GMs[] = {
  #if LIBRAT
   0.0L, /*place holder for libration */
  #endif
   4.91254745145081175785E-11L, /* Mercury */
   7.24345620963276523095E-10L, /* Venus */
  
  #if MOON
  /* (GMB*EMRAT)/(1.0+EMRAT), Earth only */
   8.88769273403302327042E-10L,
  #else
   8.99701165855730774179E-10L, /* EMB */
  #endif
   9.54952894222405763492E-11L, /* Mars */
   2.82534210344592625472E-7L, /* Jupiter */
   8.45946850483065929285E-8L, /* Saturn */
   1.28881623813803488851E-8L, /* Uranus */
   1.53211248128427618918E-8L, /* Neptune */
   2.27624775186369921644E-12L, /* Pluto */
  #if EXTRA_BODY
   1.0e-16L, /* Fictitious asteroid */
  #endif
  #if MOON
  /* (GMB)/(1.0+EMRAT),  Moon only */
   1.09318924524284471369E-11L,
  #endif
   2.95912208285591102582E-4L, /* Sun */
  #if AROIDS
   1.746e-13L, /* Ceres */
   3.2e-14L,   /* Pallas */
   4.08e-14L,  /* Vesta */
   1.6e-15L,   /* Iris */
   2.6e-15L    /* Bamberga */
  #endif
  };
  
  
  /* Astronomical unit */
  long double AU = 1.4959787066e11L;
  /* kilometers: */
  long double RADS = 6.96e5L;
  long double RADM = 1738.0L;
  long double RADE = 6378.14L;
  
  
  
  long double Je[] = {
  1.08263e-3L, /* J2E */
  -2.54e-6L,   /* J3E */
  -1.61e-6L    /* J4E */
  };
  
  long double Jm[] = {
  2.02150907893e-4L,  /* J2M */
  1.21260448837e-5L,  /* J3M */
  -1.45383007072e-7L, /* J4M */
  };
  
  long double Cnm[8] = {
   2.230351309e-5L,   /* C22 */
   3.07082741328e-5L, /* C31 */
   4.88840471683e-6L, /* C32 */
   1.43603108489e-6L, /* C33 */
  -7.17780149806e-6L, /* C41 */
  -1.43951838385e-6L, /* C42 */
  -8.54788154819e-8L, /* C43 */
  -1.5490389313e-7L   /* C44 */
  };
  
  long double Snm[8] = {
   0.0,             /* S22 */
   5.61066891941e-6L, /* S31 */
   1.68743052295e-6L, /* S32 */
  -3.343544677e-7L,   /* S33 */
   2.94743374914e-6L, /* S41 */
  -2.8843721272e-6L,  /* S42 */
  -7.88967312839e-7L, /* S43 */
   5.6404155572e-8L   /* S44 */
  };
  
  
  long double K2M = 2.22160557154e-2L;
  long double LOVENO  = 0.30L;
  long double PHASE = 4.0700012e-2L;
  
  /* DE118 initial psidot: */
  long double PSLP1 = 2.29971502189818919e-1L;
  /* PSLPI = 2 pi / PSLP1 = period in days */
  long double PSLPI =  27.32158222801637949485L;
  /* PSLPA + PSLPB = PSLPI */
   /* only top 26 bits are nonzero */
  long double PSLPIA =  27.3215820789337158203125L;
  long double PSLPIB =  1.490826636745416323896386e-7L;
  long double JDEPOCH = 2440400.5L;
  
  /* (C-A)/B */
  #define LBETd 6.31686773468e-4L
  long double LBET = LBETd;
  /* (B-A)/C */
  #define LGAMd 2.28022183594e-4L
  long double LGAM = LGAMd;
  /* C/MR^2 */
  /*
  DOUBLE CMRSQ 0.3906895261319410091
  DOUBLE LGAMBET = (LGAMd - LBETd)/(1.0-LBETd*LGAMd);
  DOUBLE CMR2 = CMRSQ*AMd*AMd;
  DOUBLE BMR2 = CMRSQ*AMd*AMd*(1.0 + LGAMd)/(1.0 + LBETd);
  DOUBLE AMR2 = CMRSQ*AMd*AMd*(1.0 - LBETd * LGAMd)/(1.0 + LBETd);
  */
  long double LGAMBET = -4.03664648017289733947E-4L;
  /* equatorial radius of Earth, in au */
  long double AE =  4.26352325064817808471E-5L;
  /* equatorial radius of Moon, in au */
  #define AMd  1.16178124180819699985E-5L
  long double AM = AMd;
  
  long double CMRSQ = 0.3906895261319410091L;
  long double CMR2 = 5.2732758299330413853212309E-11L;
  long double BMR2 = 5.2711485389894113965222358E-11L;
  long double AMR2 = 5.2699461151199766018387453E-11L;
  