text: /*
   * Automatically Generated from Mathematica.
   * Fri 5 Nov 2021 16:19:57 GMT-04:00
   */
  
  #ifdef MATLAB_MEX_FILE
  #include <stdexcept>
  #include <cmath>
  #include<math.h>
  /**
   * Copied from Wolfram Mathematica C Definitions file mdefs.hpp
   * Changed marcos to inline functions (Eric Cousineau)
   */
  inline double Power(double x, double y) { return pow(x, y); }
  inline double Sqrt(double x) { return sqrt(x); }
  
  inline double Abs(double x) { return fabs(x); }
  
  inline double Exp(double x) { return exp(x); }
  inline double Log(double x) { return log(x); }
  
  inline double Sin(double x) { return sin(x); }
  inline double Cos(double x) { return cos(x); }
  inline double Tan(double x) { return tan(x); }
  
  inline double ArcSin(double x) { return asin(x); }
  inline double ArcCos(double x) { return acos(x); }
  inline double ArcTan(double x) { return atan(x); }
  
  /* update ArcTan function to use atan2 instead. */
  inline double ArcTan(double x, double y) { return atan2(y,x); }
  
  inline double Sinh(double x) { return sinh(x); }
  inline double Cosh(double x) { return cosh(x); }
  inline double Tanh(double x) { return tanh(x); }
  
  const double E	= 2.71828182845904523536029;
  const double Pi = 3.14159265358979323846264;
  const double Degree = 0.01745329251994329576924;
  
  inline double Sec(double x) { return 1/cos(x); }
  inline double Csc(double x) { return 1/sin(x); }
  
  #endif
  
  /*
   * Sub functions
   */
  static void output1(double *p_output1,const double *var1)
  {
    double _NotUsed;
    NULL;
    p_output1[0]=1;
    p_output1[1]=1;
    p_output1[2]=2;
    p_output1[3]=2;
    p_output1[4]=3;
    p_output1[5]=3;
    p_output1[6]=4;
    p_output1[7]=4;
    p_output1[8]=5;
    p_output1[9]=5;
    p_output1[10]=6;
    p_output1[11]=6;
    p_output1[12]=7;
    p_output1[13]=7;
    p_output1[14]=8;
    p_output1[15]=8;
    p_output1[16]=9;
    p_output1[17]=9;
    p_output1[18]=10;
    p_output1[19]=10;
    p_output1[20]=11;
    p_output1[21]=11;
    p_output1[22]=12;
    p_output1[23]=12;
    p_output1[24]=13;
    p_output1[25]=13;
    p_output1[26]=14;
    p_output1[27]=14;
    p_output1[28]=15;
    p_output1[29]=15;
    p_output1[30]=16;
    p_output1[31]=16;
    p_output1[32]=17;
    p_output1[33]=17;
    p_output1[34]=18;
    p_output1[35]=18;
    p_output1[36]=19;
    p_output1[37]=19;
    p_output1[38]=20;
    p_output1[39]=20;
    p_output1[40]=21;
    p_output1[41]=21;
    p_output1[42]=22;
    p_output1[43]=22;
    p_output1[44]=23;
    p_output1[45]=23;
    p_output1[46]=24;
    p_output1[47]=24;
    p_output1[48]=25;
    p_output1[49]=25;
    p_output1[50]=26;
    p_output1[51]=26;
    p_output1[52]=27;
    p_output1[53]=27;
    p_output1[54]=28;
    p_output1[55]=28;
    p_output1[56]=29;
    p_output1[57]=29;
    p_output1[58]=30;
    p_output1[59]=30;
    p_output1[60]=31;
    p_output1[61]=31;
    p_output1[62]=32;
    p_output1[63]=32;
    p_output1[64]=33;
    p_output1[65]=33;
    p_output1[66]=34;
    p_output1[67]=34;
    p_output1[68]=35;
    p_output1[69]=35;
    p_output1[70]=36;
    p_output1[71]=36;
    p_output1[72]=1;
    p_output1[73]=37;
    p_output1[74]=2;
    p_output1[75]=38;
    p_output1[76]=3;
    p_output1[77]=39;
    p_output1[78]=4;
    p_output1[79]=40;
    p_output1[80]=5;
    p_output1[81]=41;
    p_output1[82]=6;
    p_output1[83]=42;
    p_output1[84]=7;
    p_output1[85]=43;
    p_output1[86]=8;
    p_output1[87]=44;
    p_output1[88]=9;
    p_output1[89]=45;
    p_output1[90]=10;
    p_output1[91]=46;
    p_output1[92]=11;
    p_output1[93]=47;
    p_output1[94]=12;
    p_output1[95]=48;
    p_output1[96]=13;
    p_output1[97]=49;
    p_output1[98]=14;
    p_output1[99]=50;
    p_output1[100]=15;
    p_output1[101]=51;
    p_output1[102]=16;
    p_output1[103]=52;
    p_output1[104]=17;
    p_output1[105]=53;
    p_output1[106]=18;
    p_output1[107]=54;
    p_output1[108]=19;
    p_output1[109]=55;
    p_output1[110]=20;
    p_output1[111]=56;
    p_output1[112]=21;
    p_output1[113]=57;
    p_output1[114]=22;
    p_output1[115]=58;
    p_output1[116]=23;
    p_output1[117]=59;
    p_output1[118]=24;
    p_output1[119]=60;
    p_output1[120]=25;
    p_output1[121]=61;
    p_output1[122]=26;
    p_output1[123]=62;
    p_output1[124]=27;
    p_output1[125]=63;
    p_output1[126]=28;
    p_output1[127]=64;
    p_output1[128]=29;
    p_output1[129]=65;
    p_output1[130]=30;
    p_output1[131]=66;
    p_output1[132]=31;
    p_output1[133]=67;
    p_output1[134]=32;
    p_output1[135]=68;
    p_output1[136]=33;
    p_output1[137]=69;
    p_output1[138]=34;
    p_output1[139]=70;
    p_output1[140]=35;
    p_output1[141]=71;
    p_output1[142]=36;
    p_output1[143]=72;
  }
  
  
  
  #ifdef MATLAB_MEX_FILE
  
  #include "mex.h"
  /*
   * Main function
   */
  void mexFunction( int nlhs, mxArray *plhs[],
                    int nrhs, const mxArray *prhs[] )
  {
    size_t mrows, ncols;
  
    double *var1;
    double *p_output1;
  
    /*  Check for proper number of arguments.  */ 
    if( nrhs != 1)
      {
        mexErrMsgIdAndTxt("MATLAB:MShaped:invalidNumInputs", "One input(s) required (var1).");
      }
    else if( nlhs > 1)
      {
        mexErrMsgIdAndTxt("MATLAB:MShaped:maxlhs", "Too many output arguments.");
      }
  
    /*  The input must be a noncomplex double vector or scaler.  */
    mrows = mxGetM(prhs[0]);
    ncols = mxGetN(prhs[0]);
    if( !mxIsDouble(prhs[0]) || mxIsComplex(prhs[0]) ||
      ( !(mrows == 1 && ncols == 1) && 
        !(mrows == 1 && ncols == 1))) 
      {
        mexErrMsgIdAndTxt( "MATLAB:MShaped:inputNotRealVector", "var1 is wrong.");
      }
  
    /*  Assign pointers to each input.  */
    var1 = mxGetPr(prhs[0]);
     
  
  
     
    /*  Create matrices for return arguments.  */
    plhs[0] = mxCreateDoubleMatrix((mwSize) 72, (mwSize) 2, mxREAL);
    p_output1 = mxGetPr(plhs[0]);
  
  
    /* Call the calculation subroutine. */
    output1(p_output1,var1);
  
  
  }
  
  #else // MATLAB_MEX_FILE
  
  #include "Js_xPlusCont_LeftImpact.hh"
  
  namespace LeftImpact
  {
  
  void Js_xPlusCont_LeftImpact_raw(double *p_output1, const double *var1)
  {
    // Call Subroutines
    output1(p_output1, var1);
  
  }
  
  }
  
  #endif // MATLAB_MEX_FILE
  