LTRAaccept

repo: gserdyuk/gnucap-a

original_code:
int
LTRAaccept(CKTcircuit *ckt, GENmodel *inModel)
{
  LTRAmodel *model = (LTRAmodel *) inModel;
  LTRAinstance *here;
  double v1, v2, v3, v4;
  double v5, v6, d1, d2, d3, d4;
  int tmp_test;
  int error;
  int compact = 1;
  for (; model != ((void *)0); model = model->LTRAnextModel) {
    if (ckt->CKTmode & 0x1000) {
      model->LTRAmodelListSize = 10;
      if ( model->LTRAh1dashCoeffs != ((void *)0)) {if (model->LTRAh1dashCoeffs) {txfree((char *)(model->LTRAh1dashCoeffs));(model->LTRAh1dashCoeffs) = 0;}}; model->LTRAh1dashCoeffs = (double *) tmalloc((unsigned)(model->LTRAmodelListSize * sizeof(double)));
   if ( model->LTRAh2Coeffs != ((void *)0)) {if (model->LTRAh2Coeffs) {txfree((char *)(model->LTRAh2Coeffs));(model->LTRAh2Coeffs) = 0;}}; model->LTRAh2Coeffs = (double *) tmalloc((unsigned)(model->LTRAmodelListSize * sizeof(double)));
   if ( model->LTRAh3dashCoeffs != ((void *)0)) {if (model->LTRAh3dashCoeffs) {txfree((char *)(model->LTRAh3dashCoeffs));(model->LTRAh3dashCoeffs) = 0;}}; model->LTRAh3dashCoeffs = (double *) tmalloc((unsigned)(model->LTRAmodelListSize * sizeof(double)));
    }
    if (ckt->CKTtimeIndex >= model->LTRAmodelListSize) {
      model->LTRAmodelListSize += ckt->CKTsizeIncr;
      model->LTRAh1dashCoeffs = (double *)
   trealloc((char *)((char *) model->LTRAh1dashCoeffs),(unsigned)(sizeof(double) * model->LTRAmodelListSize));
      model->LTRAh2Coeffs = (double *)
   trealloc((char *)((char *) model->LTRAh2Coeffs),(unsigned)(sizeof(double) * model->LTRAmodelListSize));
      model->LTRAh3dashCoeffs = (double *)
   trealloc((char *)((char *) model->LTRAh3dashCoeffs),(unsigned)(sizeof(double) * model->LTRAmodelListSize));
    }
    for (here = model->LTRAinstances; here != ((void *)0);
 here = here->LTRAnextInstance) {
      if (here->LTRAowner != ARCHme) continue;
      if (ckt->CKTmode & 0x1000) {
 here->LTRAinstListSize = 10;
 if ( here->LTRAv1 != ((void *)0)) {if (here->LTRAv1) {txfree((char *)(here->LTRAv1));(here->LTRAv1) = 0;}}; here->LTRAv1 = (double *) tmalloc((unsigned)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAi1 != ((void *)0)) {if (here->LTRAi1) {txfree((char *)(here->LTRAi1));(here->LTRAi1) = 0;}}; here->LTRAi1 = (double *) tmalloc((unsigned)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAv2 != ((void *)0)) {if (here->LTRAv2) {txfree((char *)(here->LTRAv2));(here->LTRAv2) = 0;}}; here->LTRAv2 = (double *) tmalloc((unsigned)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAi2 != ((void *)0)) {if (here->LTRAi2) {txfree((char *)(here->LTRAi2));(here->LTRAi2) = 0;}}; here->LTRAi2 = (double *) tmalloc((unsigned)(here->LTRAinstListSize * sizeof(double)));
      }
      if (ckt->CKTtimeIndex >= here->LTRAinstListSize) {
 here->LTRAinstListSize += ckt->CKTsizeIncr;
 here->LTRAv1 = (double *) trealloc((char *)((char *) here->LTRAv1),(unsigned)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAi1 = (double *) trealloc((char *)((char *) here->LTRAi1),(unsigned)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAi2 = (double *) trealloc((char *)((char *) here->LTRAi2),(unsigned)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAv2 = (double *) trealloc((char *)((char *) here->LTRAv2),(unsigned)(sizeof(double) * (here->LTRAinstListSize)));
      }
      *(here->LTRAv1 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAposNode1) - *(ckt->CKTrhsOld +
   here->LTRAnegNode1);
      *(here->LTRAv2 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAposNode2) - *(ckt->CKTrhsOld +
   here->LTRAnegNode2);
      *(here->LTRAi1 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAbrEq1);
      *(here->LTRAi2 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAbrEq2);
      if (ckt->CKTtryToCompact && (ckt->CKTtimeIndex >= 2)) {
 {
   double t1, t2, t3;
   t1 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 2);
   t2 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1);
   t3 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex);
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAv1 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAv1 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAv1 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAv2 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAv2 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAv2 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAi1 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAi1 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAi1 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAi2 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAi2 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAi2 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
 }
      }
      if (ckt->CKTtimeIndex > 0) {
 v1 = (*(here->LTRAv1 + ckt->CKTtimeIndex) +
     *(here->LTRAi1 + ckt->CKTtimeIndex) *
     model->LTRAimped) * model->LTRAattenuation;
 v2 = (*(here->LTRAv1 + ckt->CKTtimeIndex - 1) +
     *(here->LTRAi1 + ckt->CKTtimeIndex - 1) *
     model->LTRAimped) * model->LTRAattenuation;
 v3 = ckt->CKTtimeIndex < 2 ? v2 : (*(here->LTRAv1 + ckt->CKTtimeIndex - 2) +
     *(here->LTRAi1 + ckt->CKTtimeIndex - 2) *
     model->LTRAimped) * model->LTRAattenuation;
 v4 = (*(here->LTRAv2 + ckt->CKTtimeIndex) +
     *(here->LTRAi2 + ckt->CKTtimeIndex) *
     model->LTRAimped) * model->LTRAattenuation;
 v5 = (*(here->LTRAv2 + ckt->CKTtimeIndex - 1) +
     *(here->LTRAi2 + ckt->CKTtimeIndex - 1) *
     model->LTRAimped) * model->LTRAattenuation;
 v6 = ckt->CKTtimeIndex < 2 ? v5 : (*(here->LTRAv2 + ckt->CKTtimeIndex - 2) +
     *(here->LTRAi2 + ckt->CKTtimeIndex - 2) *
     model->LTRAimped) * model->LTRAattenuation;
 d1 = (v1 - v2) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1));
 d2 = (v2 - v3) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 2));
 d3 = (v4 - v5) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1));
 d4 = (v5 - v6) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 2));
 tmp_test = (fabs(d1 - d2)
     >= model->LTRAreltol * ((fabs(d1)) > (fabs(d2)) ? (fabs(d1)) : (fabs(d2))) +
     model->LTRAabstol)
     && (((((v1) > (v2) ? (v1) : (v2))) > (v3) ? (((v1) > (v2) ? (v1) : (v2))) : (v3))-((((v1) < (v2) ? (v1) : (v2))) < (v3) ? (((v1) < (v2) ? (v1) : (v2))) : (v3)) >= fabs(50.0*(ckt->CKTreltol/3.0*(v1+v2+v3) + ckt->CKTabstol)));
 if (tmp_test || ((fabs(d3 - d4)
      >= model->LTRAreltol * ((fabs(d3)) > (fabs(d4)) ? (fabs(d3)) : (fabs(d4))) +
      model->LTRAabstol)
  && (((((v4) > (v5) ? (v4) : (v5))) > (v6) ? (((v4) > (v5) ? (v4) : (v5))) : (v6))-((((v4) < (v5) ? (v4) : (v5))) < (v6) ? (((v4) < (v5) ? (v4) : (v5))) : (v6)) >= fabs(50.0*(ckt->CKTreltol/3.0*(v4+v5+v6) + ckt->CKTabstol))))) {
   error = CKTsetBreak(ckt,
       *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1) +
       model->LTRAtd);
   if (error)
     return (error);
 }
      }
    }
  }
  if (ckt->CKTtryToCompact && compact && (ckt->CKTtimeIndex >= 2)) {
    model = (LTRAmodel *) inModel;
    for (; model != ((void *)0); model = model->LTRAnextModel) {
      for (here = model->LTRAinstances; here != ((void *)0);
   here = here->LTRAnextInstance) {
 *(here->LTRAv1 + ckt->CKTtimeIndex - 1) = *(here->LTRAv1 +
     ckt->CKTtimeIndex);
 *(here->LTRAv2 + ckt->CKTtimeIndex - 1) = *(here->LTRAv2 +
     ckt->CKTtimeIndex);
 *(here->LTRAi1 + ckt->CKTtimeIndex - 1) = *(here->LTRAi1 +
     ckt->CKTtimeIndex);
 *(here->LTRAi2 + ckt->CKTtimeIndex - 1) = *(here->LTRAi2 +
     ckt->CKTtimeIndex);
      }
    }
    *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1) =
 *(ckt->CKTtimePoints + ckt->CKTtimeIndex);
    ckt->CKTtimeIndex--;
  }
  return (0);
}

canonical_original_code:
int LTRAaccept(struct CKTcircuit *ckt, struct sGENmodel *inModel)
{
  struct sLTRAmodel *model = (LTRAmodel *) inModel;
  struct sLTRAinstance *here;
  double v1; double v2; double v3; double v4;
  double v5; double v6; double d1; double d2; double d3; double d4;
  int tmp_test;
  int error;
  int compact = 1;
  for (; model != ((void *)0); model = model->LTRAnextModel) {
    if (ckt->CKTmode & 0x1000) {
      model->LTRAmodelListSize = 10;
      if ( model->LTRAh1dashCoeffs != ((void *)0)) {if (model->LTRAh1dashCoeffs) {txfree((char *)(model->LTRAh1dashCoeffs));(model->LTRAh1dashCoeffs) = 0;}}; model->LTRAh1dashCoeffs = (double *) tmalloc((unsigned int)(model->LTRAmodelListSize * sizeof(double)));
   if ( model->LTRAh2Coeffs != ((void *)0)) {if (model->LTRAh2Coeffs) {txfree((char *)(model->LTRAh2Coeffs));(model->LTRAh2Coeffs) = 0;}}; model->LTRAh2Coeffs = (double *) tmalloc((unsigned int)(model->LTRAmodelListSize * sizeof(double)));
   if ( model->LTRAh3dashCoeffs != ((void *)0)) {if (model->LTRAh3dashCoeffs) {txfree((char *)(model->LTRAh3dashCoeffs));(model->LTRAh3dashCoeffs) = 0;}}; model->LTRAh3dashCoeffs = (double *) tmalloc((unsigned int)(model->LTRAmodelListSize * sizeof(double)));
    }
    if (ckt->CKTtimeIndex >= model->LTRAmodelListSize) {
      model->LTRAmodelListSize += ckt->CKTsizeIncr;
      model->LTRAh1dashCoeffs = (double *)
   trealloc((char *)((char *) model->LTRAh1dashCoeffs),(unsigned int)(sizeof(double) * model->LTRAmodelListSize));
      model->LTRAh2Coeffs = (double *)
   trealloc((char *)((char *) model->LTRAh2Coeffs),(unsigned int)(sizeof(double) * model->LTRAmodelListSize));
      model->LTRAh3dashCoeffs = (double *)
   trealloc((char *)((char *) model->LTRAh3dashCoeffs),(unsigned int)(sizeof(double) * model->LTRAmodelListSize));
    }
    for (here = model->LTRAinstances; here != ((void *)0);
 here = here->LTRAnextInstance) {
      if (here->LTRAowner != ARCHme) continue;
      if (ckt->CKTmode & 0x1000) {
 here->LTRAinstListSize = 10;
 if ( here->LTRAv1 != ((void *)0)) {if (here->LTRAv1) {txfree((char *)(here->LTRAv1));(here->LTRAv1) = 0;}}; here->LTRAv1 = (double *) tmalloc((unsigned int)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAi1 != ((void *)0)) {if (here->LTRAi1) {txfree((char *)(here->LTRAi1));(here->LTRAi1) = 0;}}; here->LTRAi1 = (double *) tmalloc((unsigned int)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAv2 != ((void *)0)) {if (here->LTRAv2) {txfree((char *)(here->LTRAv2));(here->LTRAv2) = 0;}}; here->LTRAv2 = (double *) tmalloc((unsigned int)(here->LTRAinstListSize * sizeof(double)));
     if ( here->LTRAi2 != ((void *)0)) {if (here->LTRAi2) {txfree((char *)(here->LTRAi2));(here->LTRAi2) = 0;}}; here->LTRAi2 = (double *) tmalloc((unsigned int)(here->LTRAinstListSize * sizeof(double)));
      }
      if (ckt->CKTtimeIndex >= here->LTRAinstListSize) {
 here->LTRAinstListSize += ckt->CKTsizeIncr;
 here->LTRAv1 = (double *) trealloc((char *)((char *) here->LTRAv1),(unsigned int)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAi1 = (double *) trealloc((char *)((char *) here->LTRAi1),(unsigned int)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAi2 = (double *) trealloc((char *)((char *) here->LTRAi2),(unsigned int)(sizeof(double) * (here->LTRAinstListSize)));
 here->LTRAv2 = (double *) trealloc((char *)((char *) here->LTRAv2),(unsigned int)(sizeof(double) * (here->LTRAinstListSize)));
      }
      *(here->LTRAv1 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAposNode1) - *(ckt->CKTrhsOld +
   here->LTRAnegNode1);
      *(here->LTRAv2 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAposNode2) - *(ckt->CKTrhsOld +
   here->LTRAnegNode2);
      *(here->LTRAi1 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAbrEq1);
      *(here->LTRAi2 + ckt->CKTtimeIndex) = *(ckt->CKTrhsOld +
   here->LTRAbrEq2);
      if (ckt->CKTtryToCompact && (ckt->CKTtimeIndex >= 2)) {
 {
   double t1; double t2; double t3;
   t1 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 2);
   t2 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1);
   t3 = *(ckt->CKTtimePoints + ckt->CKTtimeIndex);
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAv1 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAv1 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAv1 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAv2 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAv2 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAv2 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAi1 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAi1 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAi1 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
   if (compact) {
     compact = LTRAstraightLineCheck(t1,
  *(here->LTRAi2 + ckt->CKTtimeIndex - 2),
  t2, *(here->LTRAi2 + ckt->CKTtimeIndex - 1),
  t3, *(here->LTRAi2 + ckt->CKTtimeIndex),
  model->LTRAstLineReltol, model->LTRAstLineAbstol);
   }
 }
      }
      if (ckt->CKTtimeIndex > 0) {
 v1 = (*(here->LTRAv1 + ckt->CKTtimeIndex) +
     *(here->LTRAi1 + ckt->CKTtimeIndex) *
     model->LTRAimped) * model->LTRAattenuation;
 v2 = (*(here->LTRAv1 + ckt->CKTtimeIndex - 1) +
     *(here->LTRAi1 + ckt->CKTtimeIndex - 1) *
     model->LTRAimped) * model->LTRAattenuation;
 v3 = ckt->CKTtimeIndex < 2 ? v2 : (*(here->LTRAv1 + ckt->CKTtimeIndex - 2) +
     *(here->LTRAi1 + ckt->CKTtimeIndex - 2) *
     model->LTRAimped) * model->LTRAattenuation;
 v4 = (*(here->LTRAv2 + ckt->CKTtimeIndex) +
     *(here->LTRAi2 + ckt->CKTtimeIndex) *
     model->LTRAimped) * model->LTRAattenuation;
 v5 = (*(here->LTRAv2 + ckt->CKTtimeIndex - 1) +
     *(here->LTRAi2 + ckt->CKTtimeIndex - 1) *
     model->LTRAimped) * model->LTRAattenuation;
 v6 = ckt->CKTtimeIndex < 2 ? v5 : (*(here->LTRAv2 + ckt->CKTtimeIndex - 2) +
     *(here->LTRAi2 + ckt->CKTtimeIndex - 2) *
     model->LTRAimped) * model->LTRAattenuation;
 d1 = (v1 - v2) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1));
 d2 = (v2 - v3) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 2));
 d3 = (v4 - v5) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1));
 d4 = (v5 - v6) / (*(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 1) - *(ckt->CKTtimePoints +
  ckt->CKTtimeIndex - 2));
 tmp_test = (fabs(d1 - d2)
     >= model->LTRAreltol * ((fabs(d1)) > (fabs(d2)) ? (fabs(d1)) : (fabs(d2))) +
     model->LTRAabstol)
     && (((((v1) > (v2) ? (v1) : (v2))) > (v3) ? (((v1) > (v2) ? (v1) : (v2))) : (v3))-((((v1) < (v2) ? (v1) : (v2))) < (v3) ? (((v1) < (v2) ? (v1) : (v2))) : (v3)) >= fabs(50.0*(ckt->CKTreltol/3.0*(v1+v2+v3) + ckt->CKTabstol)));
 if (tmp_test || ((fabs(d3 - d4)
      >= model->LTRAreltol * ((fabs(d3)) > (fabs(d4)) ? (fabs(d3)) : (fabs(d4))) +
      model->LTRAabstol)
  && (((((v4) > (v5) ? (v4) : (v5))) > (v6) ? (((v4) > (v5) ? (v4) : (v5))) : (v6))-((((v4) < (v5) ? (v4) : (v5))) < (v6) ? (((v4) < (v5) ? (v4) : (v5))) : (v6)) >= fabs(50.0*(ckt->CKTreltol/3.0*(v4+v5+v6) + ckt->CKTabstol))))) {
   error = CKTsetBreak(ckt,
       *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1) +
       model->LTRAtd);
   if (error)
     return (error);
 }
      }
    }
  }
  if (ckt->CKTtryToCompact && compact && (ckt->CKTtimeIndex >= 2)) {
    model = (struct sLTRAmodel *) inModel;
    for (; model != ((void *)0); model = model->LTRAnextModel) {
      for (here = model->LTRAinstances; here != ((void *)0);
   here = here->LTRAnextInstance) {
 *(here->LTRAv1 + ckt->CKTtimeIndex - 1) = *(here->LTRAv1 +
     ckt->CKTtimeIndex);
 *(here->LTRAv2 + ckt->CKTtimeIndex - 1) = *(here->LTRAv2 +
     ckt->CKTtimeIndex);
 *(here->LTRAi1 + ckt->CKTtimeIndex - 1) = *(here->LTRAi1 +
     ckt->CKTtimeIndex);
 *(here->LTRAi2 + ckt->CKTtimeIndex - 1) = *(here->LTRAi2 +
     ckt->CKTtimeIndex);
      }
    }
    *(ckt->CKTtimePoints + ckt->CKTtimeIndex - 1) =
 *(ckt->CKTtimePoints + ckt->CKTtimeIndex);
    ckt->CKTtimeIndex--;
  }
  return (0);
}

variable_types: struct CKTcircuit { struct sGENmodel { int GENmodType; struct sGENmodel *GENnextModel; struct sGENinstance { struct sGENmodel *GENmodPtr; struct sGENinstance *GENnextInstance; char *GENname; int GENowner; int GENstate; int GENnode1; int GENnode2; int GENnode3; int GENnode4; int GENnode5; int GENnode6; int GENnode7; } *GENinstances; char *GENmodName; } **CKThead; struct STATistics { int STATnumIter; int STATtranIter; int STAToldIter; int STATtimePts; int STATaccepted; int STATrejected; double STATtotAnalTime; double STATloadTime; double STATdecompTime; double STATsolveTime; double STATreorderTime; double STATcombineTime; double STATsyncTime; double STATtranTime; double STATtranDecompTime; double STATtranSolveTime; double STATtranLoadTime; double STATtranTruncTime; double STATtranCombTime; double STATtranSyncTime; double STATacTime; double STATacDecompTime; double STATacSolveTime; double STATacLoadTime; double STATacCombTime; double STATacSyncTime; } *CKTstat; double *CKTstates[8]; double CKTtime; double CKTdelta; double CKTdeltaOld[7]; double CKTtemp; double CKTnomTemp; double CKTvt; double CKTag[7]; double CKTagp[7]; int CKTorder; int CKTmaxOrder; int CKTintegrateMethod; void *CKTmatrix; int CKTniState; double *CKTrhs; double *CKTrhsOld; double *CKTrhsSpare; double *CKTirhs; double *CKTirhsOld; double *CKTirhsSpare; double *CKTpred; double *CKTsols[8]; double *CKTrhsOp; double *CKTsenRhs; double *CKTseniRhs; int CKTmaxEqNum; int CKTcurrentAnalysis; struct sCKTnode { char *name; int type; int number; double ic; double nodeset; double *ptr; struct sCKTnode *next; unsigned int icGiven; unsigned int nsGiven; } *CKTnodes; struct sCKTnode *CKTlastNode; int CKTnumStates; long CKTmode; int CKTbypass; int CKTdcMaxIter; int CKTdcTrcvMaxIter; int CKTtranMaxIter; int CKTbreakSize; int CKTbreak; double CKTsaveDelta; double CKTminBreak; double *CKTbreaks; double CKTabstol; double CKTpivotAbsTol; double CKTpivotRelTol; double CKTreltol; double CKTchgtol; double CKTvoltTol; double CKTgmin; double CKTgshunt; double CKTdelmin; double CKTtrtol; double CKTfinalTime; double CKTstep; double CKTmaxStep; double CKTinitTime; double CKTomega; double CKTsrcFact; double CKTdiagGmin; int CKTnumSrcSteps; int CKTnumGminSteps; double CKTgminFactor; int CKTnoncon; double CKTdefaultMosM; double CKTdefaultMosL; double CKTdefaultMosW; double CKTdefaultMosAD; double CKTdefaultMosAS; unsigned int CKThadNodeset; unsigned int CKTfixLimit; unsigned int CKTnoOpIter; unsigned int CKTisSetup; struct sJOB { int JOBtype; struct sJOB *JOBnextJob; char *JOBname; } *CKTcurJob; struct SENstruct { int JOBtype; struct sJOB *JOBnextJob; char *JOBname; int SENnumVal; char **SENdevices; char **SENparmNames; unsigned int SENinitflag; unsigned int SENicflag; unsigned int SENstatus; unsigned int SENacpertflag; int SENmode; int SENparms; double SENpertfac; double **SEN_Sap; double **SEN_RHS; double **SEN_iRHS; int SENsize; void *SEN_Jacmat; double *SEN_parmVal; char **SEN_parmName; } *CKTsenInfo; double *CKTtimePoints; double *CKTdeltaList; int CKTtimeListSize; int CKTtimeIndex; int CKTsizeIncr; unsigned int CKTtryToCompact; unsigned int CKTbadMos3; unsigned int CKTkeepOpInfo; unsigned int CKTcopyNodesets; unsigned int CKTnodeDamping; double CKTabsDv; double CKTrelDv; int CKTtroubleNode; struct sGENinstance *CKTtroubleElt; } *

variable_types:
inModel
struct sGENmodel *

variable_types: struct sLTRAmodel { int LTRAmodType; struct sLTRAmodel *LTRAnextModel; struct sLTRAinstance { struct sLTRAmodel *LTRAmodPtr; struct sLTRAinstance *LTRAnextInstance; char *LTRAname; int LTRAowner; int LTRAstate; int LTRAposNode1; int LTRAnegNode1; int LTRAposNode2; int LTRAnegNode2; int LTRAbrEq1; int LTRAbrEq2; double LTRAinput1; double LTRAinput2; double LTRAinitVolt1; double LTRAinitCur1; double LTRAinitVolt2; double LTRAinitCur2; double *LTRAv1; double *LTRAi1; double *LTRAv2; double *LTRAi2; int LTRAinstListSize; double *LTRAibr1Ibr1Ptr; double *LTRAibr1Ibr2Ptr; double *LTRAibr1Pos1Ptr; double *LTRAibr1Neg1Ptr; double *LTRAibr1Pos2Ptr; double *LTRAibr1Neg2Ptr; double *LTRAibr2Ibr1Ptr; double *LTRAibr2Ibr2Ptr; double *LTRAibr2Pos1Ptr; double *LTRAibr2Neg1Ptr; double *LTRAibr2Pos2Ptr; double *LTRAibr2Neg2Ptr; double *LTRAneg1Ibr1Ptr; double *LTRAneg2Ibr2Ptr; double *LTRApos1Ibr1Ptr; double *LTRApos2Ibr2Ptr; double *LTRApos1Pos1Ptr; double *LTRAneg1Neg1Ptr; double *LTRApos2Pos2Ptr; double *LTRAneg2Neg2Ptr; unsigned int LTRAicV1Given; unsigned int LTRAicC1Given; unsigned int LTRAicV2Given; unsigned int LTRAicC2Given; } *LTRAinstances; char *LTRAmodName; double LTRAh1dashFirstVal; double LTRAh2FirstVal; double LTRAh3dashFirstVal; double LTRAh1dashFirstCoeff; double LTRAh2FirstCoeff; double LTRAh3dashFirstCoeff; double *LTRAh1dashCoeffs; double *LTRAh2Coeffs; double *LTRAh3dashCoeffs; int LTRAmodelListSize; double LTRAconduct; double LTRAresist; double LTRAinduct; double LTRAcapac; double LTRAlength; double LTRAtd; double LTRAimped; double LTRAadmit; double LTRAalpha; double LTRAbeta; double LTRAattenuation; double LTRAcByR; double LTRArclsqr; double LTRAintH1dash; double LTRAintH2; double LTRAintH3dash; double LTRAnl; double LTRAf; double LTRAcoshlrootGR; double LTRArRsLrGRorG; double LTRArGsLrGRorR; int LTRAauxIndex; double LTRAstLineReltol; double LTRAchopReltol; double LTRAstLineAbstol; double LTRAchopAbstol; unsigned int LTRAreltolGiven; unsigned int LTRAabstolGiven; unsigned int LTRAtruncNR; unsigned int LTRAtruncDontCut; double LTRAmaxSafeStep; unsigned int LTRAresistGiven; unsigned int LTRAconductGiven; unsigned int LTRAinductGiven; unsigned int LTRAcapacGiven; unsigned int LTRAlengthGiven; unsigned int LTRAnlGiven; int LTRAlteConType; int LTRAhowToInterp; unsigned int LTRAprintFlag; int LTRAstepLimit; unsigned int LTRAfGiven; double LTRAabstol; double LTRAreltol; int LTRAspecialCase; } *

variable_types: struct sLTRAinstance { struct sLTRAmodel { int LTRAmodType; struct sLTRAmodel *LTRAnextModel; struct sLTRAinstance *LTRAinstances; char *LTRAmodName; double LTRAh1dashFirstVal; double LTRAh2FirstVal; double LTRAh3dashFirstVal; double LTRAh1dashFirstCoeff; double LTRAh2FirstCoeff; double LTRAh3dashFirstCoeff; double *LTRAh1dashCoeffs; double *LTRAh2Coeffs; double *LTRAh3dashCoeffs; int LTRAmodelListSize; double LTRAconduct; double LTRAresist; double LTRAinduct; double LTRAcapac; double LTRAlength; double LTRAtd; double LTRAimped; double LTRAadmit; double LTRAalpha; double LTRAbeta; double LTRAattenuation; double LTRAcByR; double LTRArclsqr; double LTRAintH1dash; double LTRAintH2; double LTRAintH3dash; double LTRAnl; double LTRAf; double LTRAcoshlrootGR; double LTRArRsLrGRorG; double LTRArGsLrGRorR; int LTRAauxIndex; double LTRAstLineReltol; double LTRAchopReltol; double LTRAstLineAbstol; double LTRAchopAbstol; unsigned int LTRAreltolGiven; unsigned int LTRAabstolGiven; unsigned int LTRAtruncNR; unsigned int LTRAtruncDontCut; double LTRAmaxSafeStep; unsigned int LTRAresistGiven; unsigned int LTRAconductGiven; unsigned int LTRAinductGiven; unsigned int LTRAcapacGiven; unsigned int LTRAlengthGiven; unsigned int LTRAnlGiven; int LTRAlteConType; int LTRAhowToInterp; unsigned int LTRAprintFlag; int LTRAstepLimit; unsigned int LTRAfGiven; double LTRAabstol; double LTRAreltol; int LTRAspecialCase; } *LTRAmodPtr; struct sLTRAinstance *LTRAnextInstance; char *LTRAname; int LTRAowner; int LTRAstate; int LTRAposNode1; int LTRAnegNode1; int LTRAposNode2; int LTRAnegNode2; int LTRAbrEq1; int LTRAbrEq2; double LTRAinput1; double LTRAinput2; double LTRAinitVolt1; double LTRAinitCur1; double LTRAinitVolt2; double LTRAinitCur2; double *LTRAv1; double *LTRAi1; double *LTRAv2; double *LTRAi2; int LTRAinstListSize; double *LTRAibr1Ibr1Ptr; double *LTRAibr1Ibr2Ptr; double *LTRAibr1Pos1Ptr; double *LTRAibr1Neg1Ptr; double *LTRAibr1Pos2Ptr; double *LTRAibr1Neg2Ptr; double *LTRAibr2Ibr1Ptr; double *LTRAibr2Ibr2Ptr; double *LTRAibr2Pos1Ptr; double *LTRAibr2Neg1Ptr; double *LTRAibr2Pos2Ptr; double *LTRAibr2Neg2Ptr; double *LTRAneg1Ibr1Ptr; double *LTRAneg2Ibr2Ptr; double *LTRApos1Ibr1Ptr; double *LTRApos2Ibr2Ptr; double *LTRApos1Pos1Ptr; double *LTRAneg1Neg1Ptr; double *LTRApos2Pos2Ptr; double *LTRAneg2Neg2Ptr; unsigned int LTRAicV1Given; unsigned int LTRAicC1Given; unsigned int LTRAicV2Given; unsigned int LTRAicC2Given; } *

variable_types: error int

variable_types: compact int

return_type: int

user_defined_types: struct CKTcircuit { struct sGENmodel **CKThead; struct STATistics *CKTstat; double *CKTstates[8]; double CKTtime; double CKTdelta; double CKTdeltaOld[7]; double CKTtemp; double CKTnomTemp; double CKTvt; double CKTag[7]; double CKTagp[7]; int CKTorder; int CKTmaxOrder; int CKTintegrateMethod; void *CKTmatrix; int CKTniState; double *CKTrhs; double *CKTrhsOld; double *CKTrhsSpare; double *CKTirhs; double *CKTirhsOld; double *CKTirhsSpare; double *CKTpred; double *CKTsols[8]; double *CKTrhsOp; double *CKTsenRhs; double *CKTseniRhs; int CKTmaxEqNum; int CKTcurrentAnalysis; struct sCKTnode *CKTnodes; struct sCKTnode *CKTlastNode; int CKTnumStates; long CKTmode; int CKTbypass; int CKTdcMaxIter; int CKTdcTrcvMaxIter; int CKTtranMaxIter; int CKTbreakSize; int CKTbreak; double CKTsaveDelta; double CKTminBreak; double *CKTbreaks; double CKTabstol; double CKTpivotAbsTol; double CKTpivotRelTol; double CKTreltol; double CKTchgtol; double CKTvoltTol; double CKTgmin; double CKTgshunt; double CKTdelmin; double CKTtrtol; double CKTfinalTime; double CKTstep; double CKTmaxStep; double CKTinitTime; double CKTomega; double CKTsrcFact; double CKTdiagGmin; int CKTnumSrcSteps; int CKTnumGminSteps; double CKTgminFactor; int CKTnoncon; double CKTdefaultMosM; double CKTdefaultMosL; double CKTdefaultMosW; double CKTdefaultMosAD; double CKTdefaultMosAS; unsigned int CKThadNodeset; unsigned int CKTfixLimit; unsigned int CKTnoOpIter; unsigned int CKTisSetup; struct sJOB *CKTcurJob; struct SENstruct *CKTsenInfo; double *CKTtimePoints; double *CKTdeltaList; int CKTtimeListSize; int CKTtimeIndex; int CKTsizeIncr; unsigned int CKTtryToCompact; unsigned int CKTbadMos3; unsigned int CKTkeepOpInfo; unsigned int CKTcopyNodesets; unsigned int CKTnodeDamping; double CKTabsDv; double CKTrelDv; int CKTtroubleNode; struct sGENinstance *CKTtroubleElt; }


JFETpzLoad

original_code:
int
JFETpzLoad(GENmodel *inModel, CKTcircuit *ckt, SPcomplex *s)
{
    JFETmodel *model = (JFETmodel*)inModel;
    JFETinstance *here;
    double gdpr;
    double gspr;
    double gm;
    double gds;
    double ggs;
    double xgs;
    double ggd;
    double xgd;
    double m;
    for( ; model != ((void *)0); model = model->JFETnextModel ) {
        for( here = model->JFETinstances; here != ((void *)0);
                here = here->JFETnextInstance) {
     if (here->JFETowner != ARCHme) continue;
            m = here->JFETm;
            gdpr=model->JFETdrainConduct * here->JFETarea;
            gspr=model->JFETsourceConduct * here->JFETarea;
            gm= *(ckt->CKTstates[0] + here->JFETstate+5) ;
            gds= *(ckt->CKTstates[0] + here->JFETstate+6) ;
            ggs= *(ckt->CKTstates[0] + here->JFETstate+7) ;
            xgs= *(ckt->CKTstates[0] + here->JFETstate+9) ;
            ggd= *(ckt->CKTstates[0] + here->JFETstate+8) ;
            xgd= *(ckt->CKTstates[0] + here->JFETstate+11) ;
            *(here->JFETdrainDrainPtr ) += m * gdpr;
            *(here->JFETgateGatePtr ) += m * (ggd+ggs);
            *(here->JFETgateGatePtr ) += m * ((xgd+xgs) * s->real);
            *(here->JFETgateGatePtr +1) += m * ((xgd+xgs) * s->imag);
            *(here->JFETsourceSourcePtr ) += m * (gspr);
            *(here->JFETdrainPrimeDrainPrimePtr ) += m * (gdpr+gds+ggd);
            *(here->JFETdrainPrimeDrainPrimePtr ) += m * (xgd * s->real);
            *(here->JFETdrainPrimeDrainPrimePtr +1) += m * (xgd * s->imag);
            *(here->JFETsourcePrimeSourcePrimePtr ) += m * (gspr+gds+gm+ggs);
            *(here->JFETsourcePrimeSourcePrimePtr ) += m * (xgs * s->real);
            *(here->JFETsourcePrimeSourcePrimePtr +1) += m * (xgs * s->imag);
            *(here->JFETdrainDrainPrimePtr ) -= m * (gdpr);
            *(here->JFETgateDrainPrimePtr ) -= m * (ggd);
            *(here->JFETgateDrainPrimePtr ) -= m * (xgd * s->real);
            *(here->JFETgateDrainPrimePtr +1) -= m * (xgd * s->imag);
            *(here->JFETgateSourcePrimePtr ) -= m * (ggs);
            *(here->JFETgateSourcePrimePtr ) -= m * (xgs * s->real);
            *(here->JFETgateSourcePrimePtr +1) -= m * (xgs * s->imag);
            *(here->JFETsourceSourcePrimePtr ) -= m * (gspr);
            *(here->JFETdrainPrimeDrainPtr ) -= m * (gdpr);
            *(here->JFETdrainPrimeGatePtr ) += m * (-ggd+gm);
            *(here->JFETdrainPrimeGatePtr ) -= m * (xgd * s->real);
            *(here->JFETdrainPrimeGatePtr +1) -= m * (xgd * s->imag);
            *(here->JFETdrainPrimeSourcePrimePtr ) += m * (-gds-gm);
            *(here->JFETsourcePrimeGatePtr ) += m * (-ggs-gm);
            *(here->JFETsourcePrimeGatePtr ) -= m * (xgs * s->real);
            *(here->JFETsourcePrimeGatePtr +1) -= m * (xgs * s->imag);
            *(here->JFETsourcePrimeSourcePtr ) -= m * (gspr);
            *(here->JFETsourcePrimeDrainPrimePtr ) -= m * (gds);
        }
    }
    return(0);
}

canonical_original_code:
int JFETpzLoad(struct sGENmodel *inModel, struct CKTcircuit *ckt, struct SPcomplex *s)
{
    struct sJFETmodel *model = (JFETmodel*)inModel;
    struct sJFETinstance *here;
    double gdpr;
    double gspr;
    double gm;
    double gds;
    double ggs;
    double xgs;
    double ggd;
    double xgd;
    double m;
    for( ; model != ((void *)0); model = model->JFETnextModel ) {
        for( here = model->JFETinstances; here != ((void *)0);
                here = here->JFETnextInstance) {
     if (here->JFETowner != ARCHme) continue;
            m = here->JFETm;
            gdpr=model->JFETdrainConduct * here->JFETarea;
            gspr=model->JFETsourceConduct * here->JFETarea;
            gm= *(ckt->CKTstates[0] + here->JFETstate+5) ;
            gds= *(ckt->CKTstates[0] + here->JFETstate+6) ;
            ggs= *(ckt->CKTstates[0] + here->JFETstate+7) ;
            xgs= *(ckt->CKTstates[0] + here->JFETstate+9) ;
            ggd= *(ckt->CKTstates[0] + here->JFETstate+8) ;
            xgd= *(ckt->CKTstates[0] + here->JFETstate+11) ;
            *(here->JFETdrainDrainPtr ) += m * gdpr;
            *(here->JFETgateGatePtr ) += m * (ggd+ggs);
            *(here->JFETgateGatePtr ) += m * ((xgd+xgs) * s->real);
            *(here->JFETgateGatePtr +1) += m * ((xgd+xgs) * s->imag);
            *(here->JFETsourceSourcePtr ) += m * (gspr);
            *(here->JFETdrainPrimeDrainPrimePtr ) += m * (gdpr+gds+ggd);
            *(here->JFETdrainPrimeDrainPrimePtr ) += m * (xgd * s->real);
            *(here->JFETdrainPrimeDrainPrimePtr +1) += m * (xgd * s->imag);
            *(here->JFETsourcePrimeSourcePrimePtr ) += m * (gspr+gds+gm+ggs);
            *(here->JFETsourcePrimeSourcePrimePtr ) += m * (xgs * s->real);
            *(here->JFETsourcePrimeSourcePrimePtr +1) += m * (xgs * s->imag);
            *(here->JFETdrainDrainPrimePtr ) -= m * (gdpr);
            *(here->JFETgateDrainPrimePtr ) -= m * (ggd);
            *(here->JFETgateDrainPrimePtr ) -= m * (xgd * s->real);
            *(here->JFETgateDrainPrimePtr +1) -= m * (xgd * s->imag);
            *(here->JFETgateSourcePrimePtr ) -= m * (ggs);
            *(here->JFETgateSourcePrimePtr ) -= m * (xgs * s->real);
            *(here->JFETgateSourcePrimePtr +1) -= m * (xgs * s->imag);
            *(here->JFETsourceSourcePrimePtr ) -= m * (gspr);
            *(here->JFETdrainPrimeDrainPtr ) -= m * (gdpr);
            *(here->JFETdrainPrimeGatePtr ) += m * (-ggd+gm);
            *(here->JFETdrainPrimeGatePtr ) -= m * (xgd * s->real);
            *(here->JFETdrainPrimeGatePtr +1) -= m * (xgd * s->imag);
            *(here->JFETdrainPrimeSourcePrimePtr ) += m * (-gds-gm);
            *(here->JFETsourcePrimeGatePtr ) += m * (-ggs-gm);
            *(here->JFETsourcePrimeGatePtr ) -= m * (xgs * s->real);
            *(here->JFETsourcePrimeGatePtr +1) -= m * (xgs * s->imag);
            *(here->JFETsourcePrimeSourcePtr ) -= m * (gspr);
            *(here->JFETsourcePrimeDrainPrimePtr ) -= m * (gds);
        }
    }
    return(0);
}

variable_types: struct sGENmodel { int GENmodType; struct sGENmodel *GENnextModel; struct sGENinstance { struct sGENmodel *GENmodPtr; struct sGENinstance *GENnextInstance; char *GENname; int GENowner; int GENstate; int GENnode1; int GENnode2; int GENnode3; int GENnode4; int GENnode5; int GENnode6; int GENnode7; } *GENinstances; char *GENmodName; } *

variable_types: struct CKTcircuit { struct sGENmodel **CKThead; struct STATistics { int STATnumIter; int STATtranIter; int STAToldIter; int STATtimePts; int STATaccepted; int STATrejected; double STATtotAnalTime; double STATloadTime; double STATdecompTime; double STATsolveTime; double STATreorderTime; double STATcombineTime; double STATsyncTime; double STATtranTime; double STATtranDecompTime; double STATtranSolveTime; double STATtranLoadTime; double STATtranTruncTime; double STATtranCombTime; double STATtranSyncTime; double STATacTime; double STATacDecompTime; double STATacSolveTime; double STATacLoadTime; double STATacCombTime; double STATacSyncTime; } *CKTstat; double *CKTstates[8]; double CKTtime; double CKTdelta; double CKTdeltaOld[7]; double CKTtemp; double CKTnomTemp; double CKTvt; double CKTag[7]; double CKTagp[7]; int CKTorder; int CKTmaxOrder; int CKTintegrateMethod; void *CKTmatrix; int CKTniState; double *CKTrhs; double *CKTrhsOld; double *CKTrhsSpare; double *CKTirhs; double *CKTirhsOld; double *CKTirhsSpare; double *CKTpred; double *CKTsols[8]; double *CKTrhsOp; double *CKTsenRhs; double *CKTseniRhs; int CKTmaxEqNum; int CKTcurrentAnalysis; struct sCKTnode { char *name; int type; int number; double ic; double nodeset; double *ptr; struct sCKTnode *next; unsigned int icGiven; unsigned int nsGiven; } *CKTnodes; struct sCKTnode *CKTlastNode; int CKTnumStates; long CKTmode; int CKTbypass; int CKTdcMaxIter; int CKTdcTrcvMaxIter; int CKTtranMaxIter; int CKTbreakSize; int CKTbreak; double CKTsaveDelta; double CKTminBreak; double *CKTbreaks; double CKTabstol; double CKTpivotAbsTol; double CKTpivotRelTol; double CKTreltol; double CKTchgtol; double CKTvoltTol; double CKTgmin; double CKTgshunt; double CKTdelmin; double CKTtrtol; double CKTfinalTime; double CKTstep; double CKTmaxStep; double CKTinitTime; double CKTomega; double CKTsrcFact; double CKTdiagGmin; int CKTnumSrcSteps; int CKTnumGminSteps; double CKTgminFactor; int CKTnoncon; double CKTdefaultMosM; double CKTdefaultMosL; double CKTdefaultMosW; double CKTdefaultMosAD; double CKTdefaultMosAS; unsigned int CKThadNodeset; unsigned int CKTfixLimit; unsigned int CKTnoOpIter; unsigned int CKTisSetup; struct sJOB { int JOBtype; struct sJOB *JOBnextJob; char *JOBname; } *CKTcurJob; struct SENstruct { int JOBtype; struct sJOB *JOBnextJob; char *JOBname; int SENnumVal; char **SENdevices; char **SENparmNames; unsigned int SENinitflag; unsigned int SENicflag; unsigned int SENstatus; unsigned int SENacpertflag; int SENmode; int SENparms; double SENpertfac; double **SEN_Sap; double **SEN_RHS; double **SEN_iRHS; int SENsize; void *SEN_Jacmat; double *SEN_parmVal; char **SEN_parmName; } *CKTsenInfo; double *CKTtimePoints; double *CKTdeltaList; int CKTtimeListSize; int CKTtimeIndex; int CKTsizeIncr; unsigned int CKTtryToCompact; unsigned int CKTbadMos3; unsigned int CKTkeepOpInfo; unsigned int CKTcopyNodesets; unsigned int CKTnodeDamping; double CKTabsDv; double CKTrelDv; int CKTtroubleNode; struct sGENinstance *CKTtroubleElt; } *

variable_types: struct SPcomplex { double real; double imag; } *

variable_types: struct sJFETmodel { int JFETmodType; struct sJFETmodel *JFETnextModel; struct sJFETinstance { struct sJFETmodel *JFETmodPtr; struct sJFETinstance *JFETnextInstance; char *JFETname; int JFETowner; int JFETstate; int JFETdrainNode; int JFETgateNode; int JFETsourceNode; int JFETdrainPrimeNode; int JFETsourcePrimeNode; double *JFETdrainDrainPrimePtr; double *JFETgateDrainPrimePtr; double *JFETgateSourcePrimePtr; double *JFETsourceSourcePrimePtr; double *JFETdrainPrimeDrainPtr; double *JFETdrainPrimeGatePtr; double *JFETdrainPrimeSourcePrimePtr; double *JFETsourcePrimeGatePtr; double *JFETsourcePrimeSourcePtr; double *JFETsourcePrimeDrainPrimePtr; double *JFETdrainDrainPtr; double *JFETgateGatePtr; double *JFETsourceSourcePtr; double *JFETdrainPrimeDrainPrimePtr; double *JFETsourcePrimeSourcePrimePtr; int JFETmode; double JFETdCoeffs[21]; double JFETnVar[3][5]; unsigned int JFEToff; unsigned int JFETareaGiven; unsigned int JFETmGiven; unsigned int JFETicVDSGiven; unsigned int JFETicVGSGiven; unsigned int JFETtempGiven; unsigned int JFETdtempGiven; double JFETarea; double JFETm; double JFETicVDS; double JFETicVGS; double JFETtemp; double JFETdtemp; double JFETtSatCur; double JFETtGatePot; double JFETtCGS; double JFETtCGD; double JFETcorDepCap; double JFETvcrit; double JFETf1; } *JFETinstances; char *JFETmodName; int JFETtype; double JFETthreshold; double JFETbeta; double JFETlModulation; double JFETdrainResist; double JFETsourceResist; double JFETcapGS; double JFETcapGD; double JFETgatePotential; double JFETgateSatCurrent; double JFETdepletionCapCoeff; double JFETfNcoef; double JFETfNexp; double JFETdrainConduct; double JFETsourceConduct; double JFETf2; double JFETf3; double JFETb; double JFETbFac; double JFETtnom; unsigned int JFETthresholdGiven; unsigned int JFETbetaGiven; unsigned int JFETlModulationGiven; unsigned int JFETdrainResistGiven; unsigned int JFETsourceResistGiven; unsigned int JFETcapGSGiven; unsigned int JFETcapGDGiven; unsigned int JFETgatePotentialGiven; unsigned int JFETgateSatCurrentGiven; unsigned int JFETdepletionCapCoeffGiven; unsigned int JFETbGiven; unsigned int JFETtnomGiven; unsigned int JFETfNcoefGiven; unsigned int JFETfNexpGiven; } *

variable_types: struct sJFETinstance { struct sJFETmodel { int JFETmodType; struct sJFETmodel *JFETnextModel; struct sJFETinstance *JFETinstances; char *JFETmodName; int JFETtype; double JFETthreshold; double JFETbeta; double JFETlModulation; double JFETdrainResist; double JFETsourceResist; double JFETcapGS; double JFETcapGD; double JFETgatePotential; double JFETgateSatCurrent; double JFETdepletionCapCoeff; double JFETfNcoef; double JFETfNexp; double JFETdrainConduct; double JFETsourceConduct; double JFETf2; double JFETf3; double JFETb; double JFETbFac; double JFETtnom; unsigned int JFETthresholdGiven; unsigned int JFETbetaGiven; unsigned int JFETlModulationGiven; unsigned int JFETdrainResistGiven; unsigned int JFETsourceResistGiven; unsigned int JFETcapGSGiven; unsigned int JFETcapGDGiven; unsigned int JFETgatePotentialGiven; unsigned int JFETgateSatCurrentGiven; unsigned int JFETdepletionCapCoeffGiven; unsigned int JFETbGiven; unsigned int JFETtnomGiven; unsigned int JFETfNcoefGiven; unsigned int JFETfNexpGiven; } *JFETmodPtr; struct sJFETinstance *JFETnextInstance; char *JFETname; int JFETowner; int JFETstate; int JFETdrainNode; int JFETgateNode; int JFETsourceNode; int JFETdrainPrimeNode; int JFETsourcePrimeNode; double *JFETdrainDrainPrimePtr; double *JFETgateDrainPrimePtr; double *JFETgateSourcePrimePtr; double *JFETsourceSourcePrimePtr; double *JFETdrainPrimeDrainPtr; double *JFETdrainPrimeGatePtr; double *JFETdrainPrimeSourcePrimePtr; double *JFETsourcePrimeGatePtr; double *JFETsourcePrimeSourcePtr; double *JFETsourcePrimeDrainPrimePtr; double *JFETdrainDrainPtr; double *JFETgateGatePtr; double *JFETsourceSourcePtr; double *JFETdrainPrimeDrainPrimePtr; double *JFETsourcePrimeSourcePrimePtr; int JFETmode; double JFETdCoeffs[21]; double JFETnVar[3][5]; unsigned int JFEToff; unsigned int JFETareaGiven; unsigned int JFETmGiven; unsigned int JFETicVDSGiven; unsigned int JFETicVGSGiven; unsigned int JFETtempGiven; unsigned int JFETdtempGiven; double JFETarea; double JFETm; double JFETicVDS; double JFETicVGS; double JFETtemp; double JFETdtemp; double JFETtSatCur; double JFETtGatePot; double JFETtCGS; double JFETtCGD; double JFETcorDepCap; double JFETvcrit; double JFETf1; } *

variable_types: gdpr double

variable_types: gspr double

variable_types: gm double

variable_types: gds double

variable_types: ggs double

variable_types: xgs double

variable_types: ggd double

variable_types: xgd double

variable_types: m double

user_defined_types: struct sGENmodel { int GENmodType; struct sGENmodel *GENnextModel; struct sGENinstance *GENinstances; char *GENmodName; }