SWmParam

repo: gserdyuk/gnucap-a

decompiled_code:
__int64 __fastcall SWmParam(int a1, double *a2, __int64 a3)
{
__int64 result; // rax
double v4; // xmm1_8
double v5; // xmm1_8
double v6; // xmm0_8
double v7; // xmm0_8

switch ( a1 )
{
case 'e':
result = 0LL;
break;
case 'f':
v4 = *a2;
*(double *)(a3 + 32) = *a2;
*(double *)(a3 + 80) = 1.0 / v4;
*(_BYTE *)(a3 + 96) |= 1u;
result = 0LL;
break;
case 'g':
v5 = *a2;
*(double *)(a3 + 40) = *a2;
*(double *)(a3 + 88) = 1.0 / v5;
*(_BYTE *)(a3 + 96) |= 2u;
result = 0LL;
break;
case 'h':
*(double *)(a3 + 48) = *a2;
*(_BYTE *)(a3 + 96) |= 4u;
result = 0LL;
break;
case 'i':
v6 = *a2;
if ( *a2 < 0.0 )
*(_QWORD *)&v6 ^= LC2;
*(double *)(a3 + 56) = v6;
*(_BYTE *)(a3 + 96) |= 8u;
result = 0LL;
break;
case 'j':
*(double *)(a3 + 64) = *a2;
*(_BYTE *)(a3 + 96) |= 0x10u;
result = 0LL;
break;
case 'k':
v7 = *a2;
if ( *a2 < 0.0 )
*(_QWORD *)&v7 ^= LC2;
*(double *)(a3 + 72) = v7;
*(_BYTE *)(a3 + 96) |= 0x20u;
result = 0LL;
break;
default:
result = 7LL;
break;
}
return result;
}

original_code:
int
SWmParam(int param, IFvalue *value, GENmodel *inModel)
{
    SWmodel *model = (SWmodel *)inModel;
    switch(param) {
        case 101:
            break;
        case 102:
            model->SWonResistance = value->rValue;
            model->SWonConduct = 1.0/(value->rValue);
            model->SWonGiven = 1;
            break;
        case 103:
            model->SWoffResistance = value->rValue;
            model->SWoffConduct = 1.0/(value->rValue);
            model->SWoffGiven = 1;
            break;
        case 104:
            model->SWvThreshold = value->rValue;
            model->SWthreshGiven = 1;
            break;
        case 105:
            model->SWvHysteresis = value->rValue;
            model->SWhystGiven = 1;
            break;
        default:
            return(7);
    }
    return(0);
}

canonical_original_code:
int SWmParam(int param, union uIFvalue *value, struct sGENmodel *inModel)
{
    struct sSWmodel *model = (SWmodel *)inModel;
    switch(param) {
        case 101:
            break;
        case 102:
            model->SWonResistance = value->rValue;
            model->SWonConduct = 1.0/(value->rValue);
            model->SWonGiven = 1;
            break;
        case 103:
            model->SWoffResistance = value->rValue;
            model->SWoffConduct = 1.0/(value->rValue);
            model->SWoffGiven = 1;
            break;
        case 104:
            model->SWvThreshold = value->rValue;
            model->SWthreshGiven = 1;
            break;
        case 105:
            model->SWvHysteresis = value->rValue;
            model->SWhystGiven = 1;
            break;
        default:
            return(7);
    }
    return(0);
}

variable_types: param int

variable_types: union uIFvalue { int iValue; double rValue; struct sIFcomplex { double real; double imag; } cValue; char *sValue; char *uValue; void *nValue; struct sIFparseTree { int numVars; int *varTypes; union uIFvalue *vars; int (*IFeval)(struct sIFparseTree *, double, double *, double *, double *); } *tValue; struct { int numValue; union { int *iVec; double *rVec; struct sIFcomplex *cVec; char **sVec; char **uVec; void **nVec; } vec; } v; } *

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 sSWmodel { int SWmodType; struct sSWmodel *SWnextModel; struct sSWinstance { struct sSWmodel *SWmodPtr; struct sSWinstance *SWnextInstance; char *SWname; int SWowner; int SWstate; int SWposNode; int SWnegNode; int SWposCntrlNode; int SWnegCntrlNode; double *SWposPosptr; double *SWnegPosptr; double *SWposNegptr; double *SWnegNegptr; double SWcond; unsigned int SWzero_stateGiven; double SWnVar[3]; } *SWinstances; char *SWmodName; double SWonResistance; double SWoffResistance; double SWvThreshold; double SWvHysteresis; double SWonConduct; double SWoffConduct; unsigned int SWonGiven; unsigned int SWoffGiven; unsigned int SWthreshGiven; unsigned int SWhystGiven; } *

return_type: int

user_defined_types: union uIFvalue { int iValue; double rValue; struct sIFcomplex cValue; char *sValue; char *uValue; void *nValue; struct sIFparseTree *tValue; struct { int numValue; union { int *iVec; double *rVec; struct sIFcomplex *cVec; char **sVec; char **uVec; void **nVec; } vec; } v; }

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

user_defined_types: struct sSWmodel { int SWmodType; struct sSWmodel *SWnextModel; struct sSWinstance *SWinstances; char *SWmodName; double SWonResistance; double SWoffResistance; double SWvThreshold; double SWvHysteresis; double SWonConduct; double SWoffConduct; unsigned int SWonGiven; unsigned int SWoffGiven; unsigned int SWthreshGiven; unsigned int SWhystGiven; }


REStemp

original_code:
int
REStemp(GENmodel *inModel, CKTcircuit *ckt)
{
    RESmodel *model = (RESmodel *)inModel;
    RESinstance *here;
    double factor;
    double difference;
    for( ; model != ((void *)0); model = model->RESnextModel ) {
        if(!model->REStnomGiven) model->REStnom = ckt->CKTnomTemp;
        if(!model->RESsheetResGiven) model->RESsheetRes = 0.0;
        if(!model->RESdefWidthGiven) model->RESdefWidth = 10.e-6;
        if(!model->REStc1Given) model->REStempCoeff1 = 0.0;
        if(!model->REStc2Given) model->REStempCoeff2 = 0.0;
        if(!model->RESnarrowGiven) model->RESnarrow = 0.0;
        if(!model->RESshortGiven) model->RESshort = 0.0;
 if(!model->RESfNcoefGiven) model->RESfNcoef = 0.0;
 if(!model->RESfNexpGiven) model->RESfNexp = 1.0;
        for (here = model->RESinstances; here != ((void *)0) ;
                here=here->RESnextInstance) {
     if (here->RESowner != ARCHme) continue;
     if(!here->REStempGiven) {
        here->REStemp = ckt->CKTtemp;
        if(!here->RESdtempGiven) here->RESdtemp = 0.0;
      } else {
        here->RESdtemp = 0.0;
        if (here->RESdtempGiven)
            printf("%s: Instance temperature specified, dtemp ignored\n", here->RESname);
      }
     if(!here->RESwidthGiven) here->RESwidth = model->RESdefWidth;
            if(!here->RESlengthGiven) here->RESlength = 0.0;
     if(!here->RESscaleGiven) here->RESscale = 1.0;
     if(!here->RESmGiven) here->RESm = 1.0;
            if(!here->RESnoisyGiven) here->RESnoisy = 1;
            if(!here->RESresGiven) {
                if(model->RESsheetResGiven && (model->RESsheetRes != 0) &&
                        (here->RESlength != 0)) {
                    here->RESresist = model->RESsheetRes * (here->RESlength -
                        model->RESshort) / (here->RESwidth - model->RESnarrow);
                } else {
                    (*(SPfrontEnd->IFerror))(0x1,
                            "%s: resistance = 0 ohm, set to 1000 ohm",&(here->RESname));
                    here->RESresist=1000;
                }
            }
            difference = (here->REStemp + here->RESdtemp) - model->REStnom;
     factor = 1.0 + (model->REStempCoeff1)*difference +
                    (model->REStempCoeff2)*difference*difference;
            here -> RESconduct = (1.0/(here->RESresist * factor * here->RESscale));
     if(here->RESacresGiven)
        here->RESacConduct = (1.0/(here->RESacResist * factor * here->RESscale));
     else {
        here -> RESacConduct = here -> RESconduct;
        here -> RESacResist = here -> RESresist;
    }
        }
    }
    return(0);
}

canonical_original_code:
int REStemp(struct sGENmodel *inModel, struct CKTcircuit *ckt)
{
    struct sRESmodel *model = (RESmodel *)inModel;
    struct sRESinstance *here;
    double factor;
    double difference;
    for( ; model != ((void *)0); model = model->RESnextModel ) {
        if(!model->REStnomGiven) model->REStnom = ckt->CKTnomTemp;
        if(!model->RESsheetResGiven) model->RESsheetRes = 0.0;
        if(!model->RESdefWidthGiven) model->RESdefWidth = 10.e-6;
        if(!model->REStc1Given) model->REStempCoeff1 = 0.0;
        if(!model->REStc2Given) model->REStempCoeff2 = 0.0;
        if(!model->RESnarrowGiven) model->RESnarrow = 0.0;
        if(!model->RESshortGiven) model->RESshort = 0.0;
 if(!model->RESfNcoefGiven) model->RESfNcoef = 0.0;
 if(!model->RESfNexpGiven) model->RESfNexp = 1.0;
        for (here = model->RESinstances; here != ((void *)0) ;
                here=here->RESnextInstance) {
     if (here->RESowner != ARCHme) continue;
     if(!here->REStempGiven) {
        here->REStemp = ckt->CKTtemp;
        if(!here->RESdtempGiven) here->RESdtemp = 0.0;
      } else {
        here->RESdtemp = 0.0;
        if (here->RESdtempGiven)
            printf("%s: Instance temperature specified, dtemp ignored\n", here->RESname);
      }
     if(!here->RESwidthGiven) here->RESwidth = model->RESdefWidth;
            if(!here->RESlengthGiven) here->RESlength = 0.0;
     if(!here->RESscaleGiven) here->RESscale = 1.0;
     if(!here->RESmGiven) here->RESm = 1.0;
            if(!here->RESnoisyGiven) here->RESnoisy = 1;
            if(!here->RESresGiven) {
                if(model->RESsheetResGiven && (model->RESsheetRes != 0) &&
                        (here->RESlength != 0)) {
                    here->RESresist = model->RESsheetRes * (here->RESlength -
                        model->RESshort) / (here->RESwidth - model->RESnarrow);
                } else {
                    (*(SPfrontEnd->IFerror))(0x1,
                            "%s: resistance = 0 ohm, set to 1000 ohm",&(here->RESname));
                    here->RESresist=1000;
                }
            }
            difference = (here->REStemp + here->RESdtemp) - model->REStnom;
     factor = 1.0 + (model->REStempCoeff1)*difference +
                    (model->REStempCoeff2)*difference*difference;
            here -> RESconduct = (1.0/(here->RESresist * factor * here->RESscale));
     if(here->RESacresGiven)
        here->RESacConduct = (1.0/(here->RESacResist * factor * here->RESscale));
     else {
        here -> RESacConduct = here -> RESconduct;
        here -> RESacResist = here -> RESresist;
    }
        }
    }
    return(0);
}

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 sRESmodel { int RESmodType; struct sRESmodel *RESnextModel; struct sRESinstance { struct sRESmodel *RESmodPtr; struct sRESinstance *RESnextInstance; char *RESname; int RESowner; int RESstate; int RESposNode; int RESnegNode; double REStemp; double RESdtemp; double RESconduct; double RESresist; double REScurrent; double RESacResist; double RESacConduct; double RESwidth; double RESlength; double RESscale; double RESm; double REStc1; double REStc2; int RESnoisy; double *RESposPosptr; double *RESnegNegptr; double *RESposNegptr; double *RESnegPosptr; unsigned int RESresGiven; unsigned int RESwidthGiven; unsigned int RESlengthGiven; unsigned int RESscaleGiven; unsigned int REStempGiven; unsigned int RESdtempGiven; unsigned int RESacresGiven; unsigned int RESmGiven; unsigned int REStc1Given; unsigned int REStc2Given; unsigned int RESnoisyGiven; int RESsenParmNo; double RESnVar[3][3]; } *RESinstances; char *RESmodName; double REStnom; double REStempCoeff1; double REStempCoeff2; double RESsheetRes; double RESdefWidth; double RESnarrow; double RESshort; double RESfNcoef; double RESfNexp; unsigned int REStnomGiven; unsigned int REStc1Given; unsigned int REStc2Given; unsigned int RESsheetResGiven; unsigned int RESdefWidthGiven; unsigned int RESnarrowGiven; unsigned int RESshortGiven; unsigned int RESfNcoefGiven; unsigned int RESfNexpGiven; } *

variable_types: struct sRESinstance { struct sRESmodel { int RESmodType; struct sRESmodel *RESnextModel; struct sRESinstance *RESinstances; char *RESmodName; double REStnom; double REStempCoeff1; double REStempCoeff2; double RESsheetRes; double RESdefWidth; double RESnarrow; double RESshort; double RESfNcoef; double RESfNexp; unsigned int REStnomGiven; unsigned int REStc1Given; unsigned int REStc2Given; unsigned int RESsheetResGiven; unsigned int RESdefWidthGiven; unsigned int RESnarrowGiven; unsigned int RESshortGiven; unsigned int RESfNcoefGiven; unsigned int RESfNexpGiven; } *RESmodPtr; struct sRESinstance *RESnextInstance; char *RESname; int RESowner; int RESstate; int RESposNode; int RESnegNode; double REStemp; double RESdtemp; double RESconduct; double RESresist; double REScurrent; double RESacResist; double RESacConduct; double RESwidth; double RESlength; double RESscale; double RESm; double REStc1; double REStc2; int RESnoisy; double *RESposPosptr; double *RESnegNegptr; double *RESposNegptr; double *RESnegPosptr; unsigned int RESresGiven; unsigned int RESwidthGiven; unsigned int RESlengthGiven; unsigned int RESscaleGiven; unsigned int REStempGiven; unsigned int RESdtempGiven; unsigned int RESacresGiven; unsigned int RESmGiven; unsigned int REStc1Given; unsigned int REStc2Given; unsigned int RESnoisyGiven; int RESsenParmNo; double RESnVar[3][3]; } *

variable_types: factor double

variable_types: difference double

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; }

user_defined_types: 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; }


JFETsetup

original_code:
int
JFETsetup(SMPmatrix *matrix, GENmodel *inModel, CKTcircuit *ckt, int *states)
{
    JFETmodel *model = (JFETmodel*)inModel;
    JFETinstance *here;
    int error;
    CKTnode *tmp;
    for( ; model != ((void *)0); model = model->JFETnextModel ) {
        if( (model->JFETtype != 1) && (model->JFETtype != -1) ) {
            model->JFETtype = 1;
        }
        if(!model->JFETthresholdGiven) {
            model->JFETthreshold = -2;
        }
        if(!model->JFETbetaGiven) {
            model->JFETbeta = 1e-4;
        }
        if(!model->JFETlModulationGiven) {
            model->JFETlModulation = 0;
        }
        if(!model->JFETdrainResistGiven) {
            model->JFETdrainResist = 0;
        }
        if(!model->JFETsourceResistGiven) {
            model->JFETsourceResist = 0;
        }
        if(!model->JFETcapGSGiven) {
            model->JFETcapGS = 0;
        }
        if(!model->JFETcapGDGiven) {
            model->JFETcapGD = 0;
        }
        if(!model->JFETgatePotentialGiven) {
            model->JFETgatePotential = 1;
        }
        if(!model->JFETgateSatCurrentGiven) {
            model->JFETgateSatCurrent = 1e-14;
        }
        if(!model->JFETdepletionCapCoeffGiven) {
            model->JFETdepletionCapCoeff = .5;
        }
 if(!model->JFETfNcoefGiven) {
     model->JFETfNcoef = 0;
 }
 if(!model->JFETfNexpGiven) {
     model->JFETfNexp = 1;
 }
 if(!model->JFETbGiven) {
     model->JFETb = 1.0;
 }
        if(model->JFETdrainResist != 0) {
            model->JFETdrainConduct = 1/model->JFETdrainResist;
        } else {
            model->JFETdrainConduct = 0;
        }
        if(model->JFETsourceResist != 0) {
            model->JFETsourceConduct = 1/model->JFETsourceResist;
        } else {
            model->JFETsourceConduct = 0;
        }
        for (here = model->JFETinstances; here != ((void *)0) ;
                here=here->JFETnextInstance) {
     if (here->JFETowner != ARCHme) goto matrixpointers;
            if(!here->JFETareaGiven) {
                here->JFETarea = 1;
            }
            if(!here->JFETmGiven) {
                here->JFETm = 1;
            }
            here->JFETstate = *states;
            *states += 13;
matrixpointers:
            if(model->JFETsourceResist != 0 && here->JFETsourcePrimeNode==0) {
                error = CKTmkVolt(ckt,&tmp,here->JFETname,"source");
                if(error) return(error);
                here->JFETsourcePrimeNode = tmp->number;
                if (ckt->CKTcopyNodesets) {
      CKTnode *tmpNode;
      IFuid tmpName;
                  if (CKTinst2Node(ckt,here,3,&tmpNode,&tmpName)==0) {
                     if (tmpNode->nsGiven) {
                       tmp->nodeset=tmpNode->nodeset;
                       tmp->nsGiven=tmpNode->nsGiven;
                     }
                  }
                }
            } else {
                here->JFETsourcePrimeNode = here->JFETsourceNode;
            }
            if(model->JFETdrainResist != 0 && here->JFETdrainPrimeNode==0) {
                error = CKTmkVolt(ckt,&tmp,here->JFETname,"drain");
                if(error) return(error);
                here->JFETdrainPrimeNode = tmp->number;
                if (ckt->CKTcopyNodesets) {
      CKTnode *tmpNode;
      IFuid tmpName;
                  if (CKTinst2Node(ckt,here,1,&tmpNode,&tmpName)==0) {
                     if (tmpNode->nsGiven) {
                       tmp->nodeset=tmpNode->nodeset;
                       tmp->nsGiven=tmpNode->nsGiven;
                     }
                  }
                }
            } else {
                here->JFETdrainPrimeNode = here->JFETdrainNode;
            }
            if((here->JFETdrainDrainPrimePtr = SMPmakeElt(matrix,here->JFETdrainNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateDrainPrimePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateSourcePrimePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourceSourcePrimePtr = SMPmakeElt(matrix,here->JFETsourceNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeDrainPtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETdrainNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeGatePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeSourcePrimePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeGatePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeSourcePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETsourceNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeDrainPrimePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainDrainPtr = SMPmakeElt(matrix,here->JFETdrainNode,here->JFETdrainNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateGatePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourceSourcePtr = SMPmakeElt(matrix,here->JFETsourceNode,here->JFETsourceNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeDrainPrimePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeSourcePrimePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
        }
    }
    return(0);
}

canonical_original_code:
int JFETsetup(void *matrix, struct sGENmodel *inModel, struct CKTcircuit *ckt, int *states)
{
    struct sJFETmodel *model = (JFETmodel*)inModel;
    struct sJFETinstance *here;
    int error;
    struct sCKTnode *tmp;
    for( ; model != ((void *)0); model = model->JFETnextModel ) {
        if( (model->JFETtype != 1) && (model->JFETtype != -1) ) {
            model->JFETtype = 1;
        }
        if(!model->JFETthresholdGiven) {
            model->JFETthreshold = -2;
        }
        if(!model->JFETbetaGiven) {
            model->JFETbeta = 1e-4;
        }
        if(!model->JFETlModulationGiven) {
            model->JFETlModulation = 0;
        }
        if(!model->JFETdrainResistGiven) {
            model->JFETdrainResist = 0;
        }
        if(!model->JFETsourceResistGiven) {
            model->JFETsourceResist = 0;
        }
        if(!model->JFETcapGSGiven) {
            model->JFETcapGS = 0;
        }
        if(!model->JFETcapGDGiven) {
            model->JFETcapGD = 0;
        }
        if(!model->JFETgatePotentialGiven) {
            model->JFETgatePotential = 1;
        }
        if(!model->JFETgateSatCurrentGiven) {
            model->JFETgateSatCurrent = 1e-14;
        }
        if(!model->JFETdepletionCapCoeffGiven) {
            model->JFETdepletionCapCoeff = .5;
        }
 if(!model->JFETfNcoefGiven) {
     model->JFETfNcoef = 0;
 }
 if(!model->JFETfNexpGiven) {
     model->JFETfNexp = 1;
 }
 if(!model->JFETbGiven) {
     model->JFETb = 1.0;
 }
        if(model->JFETdrainResist != 0) {
            model->JFETdrainConduct = 1/model->JFETdrainResist;
        } else {
            model->JFETdrainConduct = 0;
        }
        if(model->JFETsourceResist != 0) {
            model->JFETsourceConduct = 1/model->JFETsourceResist;
        } else {
            model->JFETsourceConduct = 0;
        }
        for (here = model->JFETinstances; here != ((void *)0) ;
                here=here->JFETnextInstance) {
     if (here->JFETowner != ARCHme) goto matrixpointers;
            if(!here->JFETareaGiven) {
                here->JFETarea = 1;
            }
            if(!here->JFETmGiven) {
                here->JFETm = 1;
            }
            here->JFETstate = *states;
            *states += 13;
matrixpointers:
            if(model->JFETsourceResist != 0 && here->JFETsourcePrimeNode==0) {
                error = CKTmkVolt(ckt,&tmp,here->JFETname,"source");
                if(error) return(error);
                here->JFETsourcePrimeNode = tmp->number;
                if (ckt->CKTcopyNodesets) {
      struct sCKTnode *tmpNode;
      char *tmpName;
                  if (CKTinst2Node(ckt,here,3,&tmpNode,&tmpName)==0) {
                     if (tmpNode->nsGiven) {
                       tmp->nodeset=tmpNode->nodeset;
                       tmp->nsGiven=tmpNode->nsGiven;
                     }
                  }
                }
            } else {
                here->JFETsourcePrimeNode = here->JFETsourceNode;
            }
            if(model->JFETdrainResist != 0 && here->JFETdrainPrimeNode==0) {
                error = CKTmkVolt(ckt,&tmp,here->JFETname,"drain");
                if(error) return(error);
                here->JFETdrainPrimeNode = tmp->number;
                if (ckt->CKTcopyNodesets) {
      struct sCKTnode *tmpNode;
      char *tmpName;
                  if (CKTinst2Node(ckt,here,1,&tmpNode,&tmpName)==0) {
                     if (tmpNode->nsGiven) {
                       tmp->nodeset=tmpNode->nodeset;
                       tmp->nsGiven=tmpNode->nsGiven;
                     }
                  }
                }
            } else {
                here->JFETdrainPrimeNode = here->JFETdrainNode;
            }
            if((here->JFETdrainDrainPrimePtr = SMPmakeElt(matrix,here->JFETdrainNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateDrainPrimePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateSourcePrimePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourceSourcePrimePtr = SMPmakeElt(matrix,here->JFETsourceNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeDrainPtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETdrainNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeGatePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeSourcePrimePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeGatePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeSourcePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETsourceNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeDrainPrimePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainDrainPtr = SMPmakeElt(matrix,here->JFETdrainNode,here->JFETdrainNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETgateGatePtr = SMPmakeElt(matrix,here->JFETgateNode,here->JFETgateNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourceSourcePtr = SMPmakeElt(matrix,here->JFETsourceNode,here->JFETsourceNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETdrainPrimeDrainPrimePtr = SMPmakeElt(matrix,here->JFETdrainPrimeNode,here->JFETdrainPrimeNode))==(double *)((void *)0)){ return(8);}
            if((here->JFETsourcePrimeSourcePrimePtr = SMPmakeElt(matrix,here->JFETsourcePrimeNode,here->JFETsourcePrimeNode))==(double *)((void *)0)){ return(8);}
        }
    }
    return(0);
}

variable_types:
matrix
void *

variable_types:
states
int *

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: error int

variable_types: struct sCKTnode { char *name; int type; int number; double ic; double nodeset; double *ptr; struct sCKTnode *next; unsigned int icGiven; unsigned int nsGiven; } *

variable_types:
tmpName
char *

user_defined_types: 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; }

user_defined_types: struct sJOB { int JOBtype; struct sJOB *JOBnextJob; char *JOBname; }

user_defined_types: 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; }


original_code:
int
B2convTest(GENmodel *inModel, CKTcircuit *ckt)
{
    B2model *model = (B2model*)inModel;
    B2instance *here;
    double cbd;
    double cbhat;
    double cbs;
    double cd;
    double cdhat;
    double delvbd;
    double delvbs;
    double delvds;
    double delvgd;
    double delvgs;
    double tol;
    double vbd;
    double vbs;
    double vds;
    double vgd;
    double vgdo;
    double vgs;
    for( ; model != ((void *)0); model = model->B2nextModel ) {
        for (here = model->B2instances; here != ((void *)0) ;
                here=here->B2nextInstance) {
     if (here->B2owner != ARCHme) continue;
            vbs = model->B2type * (
                *(ckt->CKTrhsOld+here->B2bNode) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vgs = model->B2type * (
                *(ckt->CKTrhsOld+here->B2gNode) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vds = model->B2type * (
                *(ckt->CKTrhsOld+here->B2dNodePrime) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vbd=vbs-vds;
            vgd=vgs-vds;
            vgdo = *(ckt->CKTstates[0] + here->B2states+ 2) -
                *(ckt->CKTstates[0] + here->B2states+ 3);
            delvbs = vbs - *(ckt->CKTstates[0] + here->B2states+ 1);
            delvbd = vbd - *(ckt->CKTstates[0] + here->B2states+ 0);
            delvgs = vgs - *(ckt->CKTstates[0] + here->B2states+ 2);
            delvds = vds - *(ckt->CKTstates[0] + here->B2states+ 3);
            delvgd = vgd-vgdo;
            if (here->B2mode >= 0) {
                cdhat=
                    *(ckt->CKTstates[0] + here->B2states+ 4) -
                    *(ckt->CKTstates[0] + here->B2states+ 10) * delvbd +
                    *(ckt->CKTstates[0] + here->B2states+ 9) * delvbs +
                    *(ckt->CKTstates[0] + here->B2states+ 7) * delvgs +
                    *(ckt->CKTstates[0] + here->B2states+ 8) * delvds ;
            } else {
                cdhat=
                    *(ckt->CKTstates[0] + here->B2states+ 4) -
                    ( *(ckt->CKTstates[0] + here->B2states+ 10) -
                      *(ckt->CKTstates[0] + here->B2states+ 9)) * delvbd -
                    *(ckt->CKTstates[0] + here->B2states+ 7) * delvgd +
                    *(ckt->CKTstates[0] + here->B2states+ 8) * delvds;
            }
            cbhat=
                *(ckt->CKTstates[0] + here->B2states+ 5) +
                *(ckt->CKTstates[0] + here->B2states+ 6) +
                *(ckt->CKTstates[0] + here->B2states+ 10) * delvbd +
                *(ckt->CKTstates[0] + here->B2states+ 11) * delvbs ;
            cd = *(ckt->CKTstates[0] + here->B2states+ 4);
            cbs = *(ckt->CKTstates[0] + here->B2states+ 5);
            cbd = *(ckt->CKTstates[0] + here->B2states+ 6);
            if ( (here->B2off == 0) || (!(ckt->CKTmode & 0x400)) ){
                tol=ckt->CKTreltol*((fabs(cdhat)) > (fabs(cd)) ? (fabs(cdhat)) : (fabs(cd)))+ckt->CKTabstol;
                if (fabs(cdhat-cd) >= tol) {
                    ckt->CKTnoncon++;
      ckt->CKTtroubleElt = (GENinstance *) here;
                    return(0);
                }
                tol=ckt->CKTreltol*((fabs(cbhat)) > (fabs(cbs+cbd)) ? (fabs(cbhat)) : (fabs(cbs+cbd)))+
                    ckt->CKTabstol;
                if (fabs(cbhat-(cbs+cbd)) > tol) {
                    ckt->CKTnoncon++;
      ckt->CKTtroubleElt = (GENinstance *) here;
                    return(0);
                }
            }
        }
    }
    return(0);
}

canonical_original_code:
int B2convTest(struct sGENmodel *inModel, struct CKTcircuit *ckt)
{
    struct sBSIM2model *model = (B2model*)inModel;
    struct sBSIM2instance *here;
    double cbd;
    double cbhat;
    double cbs;
    double cd;
    double cdhat;
    double delvbd;
    double delvbs;
    double delvds;
    double delvgd;
    double delvgs;
    double tol;
    double vbd;
    double vbs;
    double vds;
    double vgd;
    double vgdo;
    double vgs;
    for( ; model != ((void *)0); model = model->B2nextModel ) {
        for (here = model->B2instances; here != ((void *)0) ;
                here=here->B2nextInstance) {
     if (here->B2owner != ARCHme) continue;
            vbs = model->B2type * (
                *(ckt->CKTrhsOld+here->B2bNode) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vgs = model->B2type * (
                *(ckt->CKTrhsOld+here->B2gNode) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vds = model->B2type * (
                *(ckt->CKTrhsOld+here->B2dNodePrime) -
                *(ckt->CKTrhsOld+here->B2sNodePrime));
            vbd=vbs-vds;
            vgd=vgs-vds;
            vgdo = *(ckt->CKTstates[0] + here->B2states+ 2) -
                *(ckt->CKTstates[0] + here->B2states+ 3);
            delvbs = vbs - *(ckt->CKTstates[0] + here->B2states+ 1);
            delvbd = vbd - *(ckt->CKTstates[0] + here->B2states+ 0);
            delvgs = vgs - *(ckt->CKTstates[0] + here->B2states+ 2);
            delvds = vds - *(ckt->CKTstates[0] + here->B2states+ 3);
            delvgd = vgd-vgdo;
            if (here->B2mode >= 0) {
                cdhat=
                    *(ckt->CKTstates[0] + here->B2states+ 4) -
                    *(ckt->CKTstates[0] + here->B2states+ 10) * delvbd +
                    *(ckt->CKTstates[0] + here->B2states+ 9) * delvbs +
                    *(ckt->CKTstates[0] + here->B2states+ 7) * delvgs +
                    *(ckt->CKTstates[0] + here->B2states+ 8) * delvds ;
            } else {
                cdhat=
                    *(ckt->CKTstates[0] + here->B2states+ 4) -
                    ( *(ckt->CKTstates[0] + here->B2states+ 10) -
                      *(ckt->CKTstates[0] + here->B2states+ 9)) * delvbd -
                    *(ckt->CKTstates[0] + here->B2states+ 7) * delvgd +
                    *(ckt->CKTstates[0] + here->B2states+ 8) * delvds;
            }
            cbhat=
                *(ckt->CKTstates[0] + here->B2states+ 5) +
                *(ckt->CKTstates[0] + here->B2states+ 6) +
                *(ckt->CKTstates[0] + here->B2states+ 10) * delvbd +
                *(ckt->CKTstates[0] + here->B2states+ 11) * delvbs ;
            cd = *(ckt->CKTstates[0] + here->B2states+ 4);
            cbs = *(ckt->CKTstates[0] + here->B2states+ 5);
            cbd = *(ckt->CKTstates[0] + here->B2states+ 6);
            if ( (here->B2off == 0) || (!(ckt->CKTmode & 0x400)) ){
                tol=ckt->CKTreltol*((fabs(cdhat)) > (fabs(cd)) ? (fabs(cdhat)) : (fabs(cd)))+ckt->CKTabstol;
                if (fabs(cdhat-cd) >= tol) {
                    ckt->CKTnoncon++;
      ckt->CKTtroubleElt = (struct sGENinstance *) here;
                    return(0);
                }
                tol=ckt->CKTreltol*((fabs(cbhat)) > (fabs(cbs+cbd)) ? (fabs(cbhat)) : (fabs(cbs+cbd)))+
                    ckt->CKTabstol;
                if (fabs(cbhat-(cbs+cbd)) > tol) {
                    ckt->CKTnoncon++;
      ckt->CKTtroubleElt = (struct sGENinstance *) here;
                    return(0);
                }
            }
        }
    }
    return(0);
}

variable_types: struct sBSIM2model { int B2modType; struct sBSIM2model *B2nextModel; struct sBSIM2instance { struct sBSIM2model *B2modPtr; struct sBSIM2instance *B2nextInstance; char *B2name; int B2owner; int B2states; int B2dNode; int B2gNode; int B2sNode; int B2bNode; int B2dNodePrime; int B2sNodePrime; double B2l; double B2w; double B2m; double B2drainArea; double B2sourceArea; double B2drainSquares; double B2sourceSquares; double B2drainPerimeter; double B2sourcePerimeter; double B2sourceConductance; double B2drainConductance; double B2icVBS; double B2icVDS; double B2icVGS; double B2von; double B2vdsat; int B2off; int B2mode; struct bsim2SizeDependParam { double Width; double Length; double B2vfb; double B2phi; double B2k1; double B2k2; double B2eta0; double B2etaB; double B2beta0; double B2beta0B; double B2betas0; double B2betasB; double B2beta20; double B2beta2B; double B2beta2G; double B2beta30; double B2beta3B; double B2beta3G; double B2beta40; double B2beta4B; double B2beta4G; double B2ua0; double B2uaB; double B2ub0; double B2ubB; double B2u10; double B2u1B; double B2u1D; double B2n0; double B2nB; double B2nD; double B2vof0; double B2vofB; double B2vofD; double B2ai0; double B2aiB; double B2bi0; double B2biB; double B2vghigh; double B2vglow; double B2GDoverlapCap; double B2GSoverlapCap; double B2GBoverlapCap; double SqrtPhi; double Phis3; double CoxWL; double One_Third_CoxWL; double Two_Third_CoxWL; double Arg; double B2vt0; struct bsim2SizeDependParam *pNext; } *pParam; unsigned int B2lGiven; unsigned int B2wGiven; unsigned int B2mGiven; unsigned int B2drainAreaGiven; unsigned int B2sourceAreaGiven; unsigned int B2drainSquaresGiven; unsigned int B2sourceSquaresGiven; unsigned int B2drainPerimeterGiven; unsigned int B2sourcePerimeterGiven; unsigned int B2dNodePrimeSet; unsigned int B2sNodePrimeSet; unsigned int B2icVBSGiven; unsigned int B2icVDSGiven; unsigned int B2icVGSGiven; unsigned int B2vonGiven; unsigned int B2vdsatGiven; double *B2DdPtr; double *B2GgPtr; double *B2SsPtr; double *B2BbPtr; double *B2DPdpPtr; double *B2SPspPtr; double *B2DdpPtr; double *B2GbPtr; double *B2GdpPtr; double *B2GspPtr; double *B2SspPtr; double *B2BdpPtr; double *B2BspPtr; double *B2DPspPtr; double *B2DPdPtr; double *B2BgPtr; double *B2DPgPtr; double *B2SPgPtr; double *B2SPsPtr; double *B2DPbPtr; double *B2SPbPtr; double *B2SPdpPtr; double B2nVar[3][5]; } *B2instances; char *B2modName; int B2type; int pad; double B2vfb0; double B2vfbL; double B2vfbW; double B2phi0; double B2phiL; double B2phiW; double B2k10; double B2k1L; double B2k1W; double B2k20; double B2k2L; double B2k2W; double B2eta00; double B2eta0L; double B2eta0W; double B2etaB0; double B2etaBL; double B2etaBW; double B2deltaL; double B2deltaW; double B2mob00; double B2mob0B0; double B2mob0BL; double B2mob0BW; double B2mobs00; double B2mobs0L; double B2mobs0W; double B2mobsB0; double B2mobsBL; double B2mobsBW; double B2mob200; double B2mob20L; double B2mob20W; double B2mob2B0; double B2mob2BL; double B2mob2BW; double B2mob2G0; double B2mob2GL; double B2mob2GW; double B2mob300; double B2mob30L; double B2mob30W; double B2mob3B0; double B2mob3BL; double B2mob3BW; double B2mob3G0; double B2mob3GL; double B2mob3GW; double B2mob400; double B2mob40L; double B2mob40W; double B2mob4B0; double B2mob4BL; double B2mob4BW; double B2mob4G0; double B2mob4GL; double B2mob4GW; double B2ua00; double B2ua0L; double B2ua0W; double B2uaB0; double B2uaBL; double B2uaBW; double B2ub00; double B2ub0L; double B2ub0W; double B2ubB0; double B2ubBL; double B2ubBW; double B2u100; double B2u10L; double B2u10W; double B2u1B0; double B2u1BL; double B2u1BW; double B2u1D0; double B2u1DL; double B2u1DW; double B2n00; double B2n0L; double B2n0W; double B2nB0; double B2nBL; double B2nBW; double B2nD0; double B2nDL; double B2nDW; double B2vof00; double B2vof0L; double B2vof0W; double B2vofB0; double B2vofBL; double B2vofBW; double B2vofD0; double B2vofDL; double B2vofDW; double B2ai00; double B2ai0L; double B2ai0W; double B2aiB0; double B2aiBL; double B2aiBW; double B2bi00; double B2bi0L; double B2bi0W; double B2biB0; double B2biBL; double B2biBW; double B2vghigh0; double B2vghighL; double B2vghighW; double B2vglow0; double B2vglowL; double B2vglowW; double B2tox; double B2Cox; double B2temp; double B2vdd; double B2vdd2; double B2vgg; double B2vgg2; double B2vbb; double B2vbb2; double B2gateSourceOverlapCap; double B2gateDrainOverlapCap; double B2gateBulkOverlapCap; double B2Vtm; double B2sheetResistance; double B2jctSatCurDensity; double B2bulkJctPotential; double B2bulkJctBotGradingCoeff; double B2bulkJctSideGradingCoeff; double B2sidewallJctPotential; double B2unitAreaJctCap; double B2unitLengthSidewallJctCap; double B2defaultWidth; double B2deltaLength; double B2fNcoef; double B2fNexp; struct bsim2SizeDependParam *pSizeDependParamKnot; unsigned int B2channelChargePartitionFlag; unsigned int B2vfb0Given; unsigned int B2vfbLGiven; unsigned int B2vfbWGiven; unsigned int B2phi0Given; unsigned int B2phiLGiven; unsigned int B2phiWGiven; unsigned int B2k10Given; unsigned int B2k1LGiven; unsigned int B2k1WGiven; unsigned int B2k20Given; unsigned int B2k2LGiven; unsigned int B2k2WGiven; unsigned int B2eta00Given; unsigned int B2eta0LGiven; unsigned int B2eta0WGiven; unsigned int B2etaB0Given; unsigned int B2etaBLGiven; unsigned int B2etaBWGiven; unsigned int B2deltaLGiven; unsigned int B2deltaWGiven; unsigned int B2mob00Given; unsigned int B2mob0B0Given; unsigned int B2mob0BLGiven; unsigned int B2mob0BWGiven; unsigned int B2mobs00Given; unsigned int B2mobs0LGiven; unsigned int B2mobs0WGiven; unsigned int B2mobsB0Given; unsigned int B2mobsBLGiven; unsigned int B2mobsBWGiven; unsigned int B2mob200Given; unsigned int B2mob20LGiven; unsigned int B2mob20WGiven; unsigned int B2mob2B0Given; unsigned int B2mob2BLGiven; unsigned int B2mob2BWGiven; unsigned int B2mob2G0Given; unsigned int B2mob2GLGiven; unsigned int B2mob2GWGiven; unsigned int B2mob300Given; unsigned int B2mob30LGiven; unsigned int B2mob30WGiven; unsigned int B2mob3B0Given; unsigned int B2mob3BLGiven; unsigned int B2mob3BWGiven; unsigned int B2mob3G0Given; unsigned int B2mob3GLGiven; unsigned int B2mob3GWGiven; unsigned int B2mob400Given; unsigned int B2mob40LGiven; unsigned int B2mob40WGiven; unsigned int B2mob4B0Given; unsigned int B2mob4BLGiven; unsigned int B2mob4BWGiven; unsigned int B2mob4G0Given; unsigned int B2mob4GLGiven; unsigned int B2mob4GWGiven; unsigned int B2ua00Given; unsigned int B2ua0LGiven; unsigned int B2ua0WGiven; unsigned int B2uaB0Given; unsigned int B2uaBLGiven; unsigned int B2uaBWGiven; unsigned int B2ub00Given; unsigned int B2ub0LGiven; unsigned int B2ub0WGiven; unsigned int B2ubB0Given; unsigned int B2ubBLGiven; unsigned int B2ubBWGiven; unsigned int B2u100Given; unsigned int B2u10LGiven; unsigned int B2u10WGiven; unsigned int B2u1B0Given; unsigned int B2u1BLGiven; unsigned int B2u1BWGiven; unsigned int B2u1D0Given; unsigned int B2u1DLGiven; unsigned int B2u1DWGiven; unsigned int B2n00Given; unsigned int B2n0LGiven; unsigned int B2n0WGiven; unsigned int B2nB0Given; unsigned int B2nBLGiven; unsigned int B2nBWGiven; unsigned int B2nD0Given; unsigned int B2nDLGiven; unsigned int B2nDWGiven; unsigned int B2vof00Given; unsigned int B2vof0LGiven; unsigned int B2vof0WGiven; unsigned int B2vofB0Given; unsigned int B2vofBLGiven; unsigned int B2vofBWGiven; unsigned int B2vofD0Given; unsigned int B2vofDLGiven; unsigned int B2vofDWGiven; unsigned int B2ai00Given; unsigned int B2ai0LGiven; unsigned int B2ai0WGiven; unsigned int B2aiB0Given; unsigned int B2aiBLGiven; unsigned int B2aiBWGiven; unsigned int B2bi00Given; unsigned int B2bi0LGiven; unsigned int B2bi0WGiven; unsigned int B2biB0Given; unsigned int B2biBLGiven; unsigned int B2biBWGiven; unsigned int B2vghigh0Given; unsigned int B2vghighLGiven; unsigned int B2vghighWGiven; unsigned int B2vglow0Given; unsigned int B2vglowLGiven; unsigned int B2vglowWGiven; unsigned int B2toxGiven; unsigned int B2tempGiven; unsigned int B2vddGiven; unsigned int B2vggGiven; unsigned int B2vbbGiven; unsigned int B2gateSourceOverlapCapGiven; unsigned int B2gateDrainOverlapCapGiven; unsigned int B2gateBulkOverlapCapGiven; unsigned int B2channelChargePartitionFlagGiven; unsigned int B2sheetResistanceGiven; unsigned int B2jctSatCurDensityGiven; unsigned int B2bulkJctPotentialGiven; unsigned int B2bulkJctBotGradingCoeffGiven; unsigned int B2sidewallJctPotentialGiven; unsigned int B2bulkJctSideGradingCoeffGiven; unsigned int B2unitAreaJctCapGiven; unsigned int B2unitLengthSidewallJctCapGiven; unsigned int B2defaultWidthGiven; unsigned int B2deltaLengthGiven; unsigned int B2fNcoefGiven; unsigned int B2fNexpGiven; unsigned int B2typeGiven; } *

variable_types: struct sBSIM2instance { struct sBSIM2model { int B2modType; struct sBSIM2model *B2nextModel; struct sBSIM2instance *B2instances; char *B2modName; int B2type; int pad; double B2vfb0; double B2vfbL; double B2vfbW; double B2phi0; double B2phiL; double B2phiW; double B2k10; double B2k1L; double B2k1W; double B2k20; double B2k2L; double B2k2W; double B2eta00; double B2eta0L; double B2eta0W; double B2etaB0; double B2etaBL; double B2etaBW; double B2deltaL; double B2deltaW; double B2mob00; double B2mob0B0; double B2mob0BL; double B2mob0BW; double B2mobs00; double B2mobs0L; double B2mobs0W; double B2mobsB0; double B2mobsBL; double B2mobsBW; double B2mob200; double B2mob20L; double B2mob20W; double B2mob2B0; double B2mob2BL; double B2mob2BW; double B2mob2G0; double B2mob2GL; double B2mob2GW; double B2mob300; double B2mob30L; double B2mob30W; double B2mob3B0; double B2mob3BL; double B2mob3BW; double B2mob3G0; double B2mob3GL; double B2mob3GW; double B2mob400; double B2mob40L; double B2mob40W; double B2mob4B0; double B2mob4BL; double B2mob4BW; double B2mob4G0; double B2mob4GL; double B2mob4GW; double B2ua00; double B2ua0L; double B2ua0W; double B2uaB0; double B2uaBL; double B2uaBW; double B2ub00; double B2ub0L; double B2ub0W; double B2ubB0; double B2ubBL; double B2ubBW; double B2u100; double B2u10L; double B2u10W; double B2u1B0; double B2u1BL; double B2u1BW; double B2u1D0; double B2u1DL; double B2u1DW; double B2n00; double B2n0L; double B2n0W; double B2nB0; double B2nBL; double B2nBW; double B2nD0; double B2nDL; double B2nDW; double B2vof00; double B2vof0L; double B2vof0W; double B2vofB0; double B2vofBL; double B2vofBW; double B2vofD0; double B2vofDL; double B2vofDW; double B2ai00; double B2ai0L; double B2ai0W; double B2aiB0; double B2aiBL; double B2aiBW; double B2bi00; double B2bi0L; double B2bi0W; double B2biB0; double B2biBL; double B2biBW; double B2vghigh0; double B2vghighL; double B2vghighW; double B2vglow0; double B2vglowL; double B2vglowW; double B2tox; double B2Cox; double B2temp; double B2vdd; double B2vdd2; double B2vgg; double B2vgg2; double B2vbb; double B2vbb2; double B2gateSourceOverlapCap; double B2gateDrainOverlapCap; double B2gateBulkOverlapCap; double B2Vtm; double B2sheetResistance; double B2jctSatCurDensity; double B2bulkJctPotential; double B2bulkJctBotGradingCoeff; double B2bulkJctSideGradingCoeff; double B2sidewallJctPotential; double B2unitAreaJctCap; double B2unitLengthSidewallJctCap; double B2defaultWidth; double B2deltaLength; double B2fNcoef; double B2fNexp; struct bsim2SizeDependParam { double Width; double Length; double B2vfb; double B2phi; double B2k1; double B2k2; double B2eta0; double B2etaB; double B2beta0; double B2beta0B; double B2betas0; double B2betasB; double B2beta20; double B2beta2B; double B2beta2G; double B2beta30; double B2beta3B; double B2beta3G; double B2beta40; double B2beta4B; double B2beta4G; double B2ua0; double B2uaB; double B2ub0; double B2ubB; double B2u10; double B2u1B; double B2u1D; double B2n0; double B2nB; double B2nD; double B2vof0; double B2vofB; double B2vofD; double B2ai0; double B2aiB; double B2bi0; double B2biB; double B2vghigh; double B2vglow; double B2GDoverlapCap; double B2GSoverlapCap; double B2GBoverlapCap; double SqrtPhi; double Phis3; double CoxWL; double One_Third_CoxWL; double Two_Third_CoxWL; double Arg; double B2vt0; struct bsim2SizeDependParam *pNext; } *pSizeDependParamKnot; unsigned int B2channelChargePartitionFlag; unsigned int B2vfb0Given; unsigned int B2vfbLGiven; unsigned int B2vfbWGiven; unsigned int B2phi0Given; unsigned int B2phiLGiven; unsigned int B2phiWGiven; unsigned int B2k10Given; unsigned int B2k1LGiven; unsigned int B2k1WGiven; unsigned int B2k20Given; unsigned int B2k2LGiven; unsigned int B2k2WGiven; unsigned int B2eta00Given; unsigned int B2eta0LGiven; unsigned int B2eta0WGiven; unsigned int B2etaB0Given; unsigned int B2etaBLGiven; unsigned int B2etaBWGiven; unsigned int B2deltaLGiven; unsigned int B2deltaWGiven; unsigned int B2mob00Given; unsigned int B2mob0B0Given; unsigned int B2mob0BLGiven; unsigned int B2mob0BWGiven; unsigned int B2mobs00Given; unsigned int B2mobs0LGiven; unsigned int B2mobs0WGiven; unsigned int B2mobsB0Given; unsigned int B2mobsBLGiven; unsigned int B2mobsBWGiven; unsigned int B2mob200Given; unsigned int B2mob20LGiven; unsigned int B2mob20WGiven; unsigned int B2mob2B0Given; unsigned int B2mob2BLGiven; unsigned int B2mob2BWGiven; unsigned int B2mob2G0Given; unsigned int B2mob2GLGiven; unsigned int B2mob2GWGiven; unsigned int B2mob300Given; unsigned int B2mob30LGiven; unsigned int B2mob30WGiven; unsigned int B2mob3B0Given; unsigned int B2mob3BLGiven; unsigned int B2mob3BWGiven; unsigned int B2mob3G0Given; unsigned int B2mob3GLGiven; unsigned int B2mob3GWGiven; unsigned int B2mob400Given; unsigned int B2mob40LGiven; unsigned int B2mob40WGiven; unsigned int B2mob4B0Given; unsigned int B2mob4BLGiven; unsigned int B2mob4BWGiven; unsigned int B2mob4G0Given; unsigned int B2mob4GLGiven; unsigned int B2mob4GWGiven; unsigned int B2ua00Given; unsigned int B2ua0LGiven; unsigned int B2ua0WGiven; unsigned int B2uaB0Given; unsigned int B2uaBLGiven; unsigned int B2uaBWGiven; unsigned int B2ub00Given; unsigned int B2ub0LGiven; unsigned int B2ub0WGiven; unsigned int B2ubB0Given; unsigned int B2ubBLGiven; unsigned int B2ubBWGiven; unsigned int B2u100Given; unsigned int B2u10LGiven; unsigned int B2u10WGiven; unsigned int B2u1B0Given; unsigned int B2u1BLGiven; unsigned int B2u1BWGiven; unsigned int B2u1D0Given; unsigned int B2u1DLGiven; unsigned int B2u1DWGiven; unsigned int B2n00Given; unsigned int B2n0LGiven; unsigned int B2n0WGiven; unsigned int B2nB0Given; unsigned int B2nBLGiven; unsigned int B2nBWGiven; unsigned int B2nD0Given; unsigned int B2nDLGiven; unsigned int B2nDWGiven; unsigned int B2vof00Given; unsigned int B2vof0LGiven; unsigned int B2vof0WGiven; unsigned int B2vofB0Given; unsigned int B2vofBLGiven; unsigned int B2vofBWGiven; unsigned int B2vofD0Given; unsigned int B2vofDLGiven; unsigned int B2vofDWGiven; unsigned int B2ai00Given; unsigned int B2ai0LGiven; unsigned int B2ai0WGiven; unsigned int B2aiB0Given; unsigned int B2aiBLGiven; unsigned int B2aiBWGiven; unsigned int B2bi00Given; unsigned int B2bi0LGiven; unsigned int B2bi0WGiven; unsigned int B2biB0Given; unsigned int B2biBLGiven; unsigned int B2biBWGiven; unsigned int B2vghigh0Given; unsigned int B2vghighLGiven; unsigned int B2vghighWGiven; unsigned int B2vglow0Given; unsigned int B2vglowLGiven; unsigned int B2vglowWGiven; unsigned int B2toxGiven; unsigned int B2tempGiven; unsigned int B2vddGiven; unsigned int B2vggGiven; unsigned int B2vbbGiven; unsigned int B2gateSourceOverlapCapGiven; unsigned int B2gateDrainOverlapCapGiven; unsigned int B2gateBulkOverlapCapGiven; unsigned int B2channelChargePartitionFlagGiven; unsigned int B2sheetResistanceGiven; unsigned int B2jctSatCurDensityGiven; unsigned int B2bulkJctPotentialGiven; unsigned int B2bulkJctBotGradingCoeffGiven; unsigned int B2sidewallJctPotentialGiven; unsigned int B2bulkJctSideGradingCoeffGiven; unsigned int B2unitAreaJctCapGiven; unsigned int B2unitLengthSidewallJctCapGiven; unsigned int B2defaultWidthGiven; unsigned int B2deltaLengthGiven; unsigned int B2fNcoefGiven; unsigned int B2fNexpGiven; unsigned int B2typeGiven; } *B2modPtr; struct sBSIM2instance *B2nextInstance; char *B2name; int B2owner; int B2states; int B2dNode; int B2gNode; int B2sNode; int B2bNode; int B2dNodePrime; int B2sNodePrime; double B2l; double B2w; double B2m; double B2drainArea; double B2sourceArea; double B2drainSquares; double B2sourceSquares; double B2drainPerimeter; double B2sourcePerimeter; double B2sourceConductance; double B2drainConductance; double B2icVBS; double B2icVDS; double B2icVGS; double B2von; double B2vdsat; int B2off; int B2mode; struct bsim2SizeDependParam *pParam; unsigned int B2lGiven; unsigned int B2wGiven; unsigned int B2mGiven; unsigned int B2drainAreaGiven; unsigned int B2sourceAreaGiven; unsigned int B2drainSquaresGiven; unsigned int B2sourceSquaresGiven; unsigned int B2drainPerimeterGiven; unsigned int B2sourcePerimeterGiven; unsigned int B2dNodePrimeSet; unsigned int B2sNodePrimeSet; unsigned int B2icVBSGiven; unsigned int B2icVDSGiven; unsigned int B2icVGSGiven; unsigned int B2vonGiven; unsigned int B2vdsatGiven; double *B2DdPtr; double *B2GgPtr; double *B2SsPtr; double *B2BbPtr; double *B2DPdpPtr; double *B2SPspPtr; double *B2DdpPtr; double *B2GbPtr; double *B2GdpPtr; double *B2GspPtr; double *B2SspPtr; double *B2BdpPtr; double *B2BspPtr; double *B2DPspPtr; double *B2DPdPtr; double *B2BgPtr; double *B2DPgPtr; double *B2SPgPtr; double *B2SPsPtr; double *B2DPbPtr; double *B2SPbPtr; double *B2SPdpPtr; double B2nVar[3][5]; } *

variable_types: cbd double

variable_types: cbhat double

variable_types: cbs double

variable_types: cd double

variable_types: cdhat double

variable_types: delvbd double

variable_types: delvbs double

variable_types: delvds double

variable_types: delvgd double

variable_types: delvgs double

variable_types: tol double

variable_types: vbd double

variable_types: vbs double

variable_types: vds double

variable_types: vgd double

variable_types: vgdo double

variable_types: vgs double

user_defined_types: struct sBSIM2model { int B2modType; struct sBSIM2model *B2nextModel; struct sBSIM2instance *B2instances; char *B2modName; int B2type; int pad; double B2vfb0; double B2vfbL; double B2vfbW; double B2phi0; double B2phiL; double B2phiW; double B2k10; double B2k1L; double B2k1W; double B2k20; double B2k2L; double B2k2W; double B2eta00; double B2eta0L; double B2eta0W; double B2etaB0; double B2etaBL; double B2etaBW; double B2deltaL; double B2deltaW; double B2mob00; double B2mob0B0; double B2mob0BL; double B2mob0BW; double B2mobs00; double B2mobs0L; double B2mobs0W; double B2mobsB0; double B2mobsBL; double B2mobsBW; double B2mob200; double B2mob20L; double B2mob20W; double B2mob2B0; double B2mob2BL; double B2mob2BW; double B2mob2G0; double B2mob2GL; double B2mob2GW; double B2mob300; double B2mob30L; double B2mob30W; double B2mob3B0; double B2mob3BL; double B2mob3BW; double B2mob3G0; double B2mob3GL; double B2mob3GW; double B2mob400; double B2mob40L; double B2mob40W; double B2mob4B0; double B2mob4BL; double B2mob4BW; double B2mob4G0; double B2mob4GL; double B2mob4GW; double B2ua00; double B2ua0L; double B2ua0W; double B2uaB0; double B2uaBL; double B2uaBW; double B2ub00; double B2ub0L; double B2ub0W; double B2ubB0; double B2ubBL; double B2ubBW; double B2u100; double B2u10L; double B2u10W; double B2u1B0; double B2u1BL; double B2u1BW; double B2u1D0; double B2u1DL; double B2u1DW; double B2n00; double B2n0L; double B2n0W; double B2nB0; double B2nBL; double B2nBW; double B2nD0; double B2nDL; double B2nDW; double B2vof00; double B2vof0L; double B2vof0W; double B2vofB0; double B2vofBL; double B2vofBW; double B2vofD0; double B2vofDL; double B2vofDW; double B2ai00; double B2ai0L; double B2ai0W; double B2aiB0; double B2aiBL; double B2aiBW; double B2bi00; double B2bi0L; double B2bi0W; double B2biB0; double B2biBL; double B2biBW; double B2vghigh0; double B2vghighL; double B2vghighW; double B2vglow0; double B2vglowL; double B2vglowW; double B2tox; double B2Cox; double B2temp; double B2vdd; double B2vdd2; double B2vgg; double B2vgg2; double B2vbb; double B2vbb2; double B2gateSourceOverlapCap; double B2gateDrainOverlapCap; double B2gateBulkOverlapCap; double B2Vtm; double B2sheetResistance; double B2jctSatCurDensity; double B2bulkJctPotential; double B2bulkJctBotGradingCoeff; double B2bulkJctSideGradingCoeff; double B2sidewallJctPotential; double B2unitAreaJctCap; double B2unitLengthSidewallJctCap; double B2defaultWidth; double B2deltaLength; double B2fNcoef; double B2fNexp; struct bsim2SizeDependParam *pSizeDependParamKnot; unsigned int B2channelChargePartitionFlag; unsigned int B2vfb0Given; unsigned int B2vfbLGiven; unsigned int B2vfbWGiven; unsigned int B2phi0Given; unsigned int B2phiLGiven; unsigned int B2phiWGiven; unsigned int B2k10Given; unsigned int B2k1LGiven; unsigned int B2k1WGiven; unsigned int B2k20Given; unsigned int B2k2LGiven; unsigned int B2k2WGiven; unsigned int B2eta00Given; unsigned int B2eta0LGiven; unsigned int B2eta0WGiven; unsigned int B2etaB0Given; unsigned int B2etaBLGiven; unsigned int B2etaBWGiven; unsigned int B2deltaLGiven; unsigned int B2deltaWGiven; unsigned int B2mob00Given; unsigned int B2mob0B0Given; unsigned int B2mob0BLGiven; unsigned int B2mob0BWGiven; unsigned int B2mobs00Given; unsigned int B2mobs0LGiven; unsigned int B2mobs0WGiven; unsigned int B2mobsB0Given; unsigned int B2mobsBLGiven; unsigned int B2mobsBWGiven; unsigned int B2mob200Given; unsigned int B2mob20LGiven; unsigned int B2mob20WGiven; unsigned int B2mob2B0Given; unsigned int B2mob2BLGiven; unsigned int B2mob2BWGiven; unsigned int B2mob2G0Given; unsigned int B2mob2GLGiven; unsigned int B2mob2GWGiven; unsigned int B2mob300Given; unsigned int B2mob30LGiven; unsigned int B2mob30WGiven; unsigned int B2mob3B0Given; unsigned int B2mob3BLGiven; unsigned int B2mob3BWGiven; unsigned int B2mob3G0Given; unsigned int B2mob3GLGiven; unsigned int B2mob3GWGiven; unsigned int B2mob400Given; unsigned int B2mob40LGiven; unsigned int B2mob40WGiven; unsigned int B2mob4B0Given; unsigned int B2mob4BLGiven; unsigned int B2mob4BWGiven; unsigned int B2mob4G0Given; unsigned int B2mob4GLGiven; unsigned int B2mob4GWGiven; unsigned int B2ua00Given; unsigned int B2ua0LGiven; unsigned int B2ua0WGiven; unsigned int B2uaB0Given; unsigned int B2uaBLGiven; unsigned int B2uaBWGiven; unsigned int B2ub00Given; unsigned int B2ub0LGiven; unsigned int B2ub0WGiven; unsigned int B2ubB0Given; unsigned int B2ubBLGiven; unsigned int B2ubBWGiven; unsigned int B2u100Given; unsigned int B2u10LGiven; unsigned int B2u10WGiven; unsigned int B2u1B0Given; unsigned int B2u1BLGiven; unsigned int B2u1BWGiven; unsigned int B2u1D0Given; unsigned int B2u1DLGiven; unsigned int B2u1DWGiven; unsigned int B2n00Given; unsigned int B2n0LGiven; unsigned int B2n0WGiven; unsigned int B2nB0Given; unsigned int B2nBLGiven; unsigned int B2nBWGiven; unsigned int B2nD0Given; unsigned int B2nDLGiven; unsigned int B2nDWGiven; unsigned int B2vof00Given; unsigned int B2vof0LGiven; unsigned int B2vof0WGiven; unsigned int B2vofB0Given; unsigned int B2vofBLGiven; unsigned int B2vofBWGiven; unsigned int B2vofD0Given; unsigned int B2vofDLGiven; unsigned int B2vofDWGiven; unsigned int B2ai00Given; unsigned int B2ai0LGiven; unsigned int B2ai0WGiven; unsigned int B2aiB0Given; unsigned int B2aiBLGiven; unsigned int B2aiBWGiven; unsigned int B2bi00Given; unsigned int B2bi0LGiven; unsigned int B2bi0WGiven; unsigned int B2biB0Given; unsigned int B2biBLGiven; unsigned int B2biBWGiven; unsigned int B2vghigh0Given; unsigned int B2vghighLGiven; unsigned int B2vghighWGiven; unsigned int B2vglow0Given; unsigned int B2vglowLGiven; unsigned int B2vglowWGiven; unsigned int B2toxGiven; unsigned int B2tempGiven; unsigned int B2vddGiven; unsigned int B2vggGiven; unsigned int B2vbbGiven; unsigned int B2gateSourceOverlapCapGiven; unsigned int B2gateDrainOverlapCapGiven; unsigned int B2gateBulkOverlapCapGiven; unsigned int B2channelChargePartitionFlagGiven; unsigned int B2sheetResistanceGiven; unsigned int B2jctSatCurDensityGiven; unsigned int B2bulkJctPotentialGiven; unsigned int B2bulkJctBotGradingCoeffGiven; unsigned int B2sidewallJctPotentialGiven; unsigned int B2bulkJctSideGradingCoeffGiven; unsigned int B2unitAreaJctCapGiven; unsigned int B2unitLengthSidewallJctCapGiven; unsigned int B2defaultWidthGiven; unsigned int B2deltaLengthGiven; unsigned int B2fNcoefGiven; unsigned int B2fNexpGiven; unsigned int B2typeGiven; }

user_defined_types: struct sBSIM2instance { struct sBSIM2model *B2modPtr; struct sBSIM2instance *B2nextInstance; char *B2name; int B2owner; int B2states; int B2dNode; int B2gNode; int B2sNode; int B2bNode; int B2dNodePrime; int B2sNodePrime; double B2l; double B2w; double B2m; double B2drainArea; double B2sourceArea; double B2drainSquares; double B2sourceSquares; double B2drainPerimeter; double B2sourcePerimeter; double B2sourceConductance; double B2drainConductance; double B2icVBS; double B2icVDS; double B2icVGS; double B2von; double B2vdsat; int B2off; int B2mode; struct bsim2SizeDependParam *pParam; unsigned int B2lGiven; unsigned int B2wGiven; unsigned int B2mGiven; unsigned int B2drainAreaGiven; unsigned int B2sourceAreaGiven; unsigned int B2drainSquaresGiven; unsigned int B2sourceSquaresGiven; unsigned int B2drainPerimeterGiven; unsigned int B2sourcePerimeterGiven; unsigned int B2dNodePrimeSet; unsigned int B2sNodePrimeSet; unsigned int B2icVBSGiven; unsigned int B2icVDSGiven; unsigned int B2icVGSGiven; unsigned int B2vonGiven; unsigned int B2vdsatGiven; double *B2DdPtr; double *B2GgPtr; double *B2SsPtr; double *B2BbPtr; double *B2DPdpPtr; double *B2SPspPtr; double *B2DdpPtr; double *B2GbPtr; double *B2GdpPtr; double *B2GspPtr; double *B2SspPtr; double *B2BdpPtr; double *B2BspPtr; double *B2DPspPtr; double *B2DPdPtr; double *B2BgPtr; double *B2DPgPtr; double *B2SPgPtr; double *B2SPsPtr; double *B2DPbPtr; double *B2SPbPtr; double *B2SPdpPtr; double B2nVar[3][5]; }

user_defined_types: struct sCKTnode { char *name; int type; int number; double ic; double nodeset; double *ptr; struct sCKTnode *next; unsigned int icGiven; unsigned int nsGiven; }