📄 b3soifdset.c
字号:
if (!model->B3SOIFDpdvt2Given) model->B3SOIFDpdvt2 = 0.0; if (!model->B3SOIFDpdvt0wGiven) model->B3SOIFDpdvt0w = 0.0; if (!model->B3SOIFDpdvt1wGiven) model->B3SOIFDpdvt1w = 0.0; if (!model->B3SOIFDpdvt2wGiven) model->B3SOIFDpdvt2w = 0.0; if (!model->B3SOIFDpu0Given) model->B3SOIFDpu0 = 0.0; if (!model->B3SOIFDpuaGiven) model->B3SOIFDpua = 0.0; if (!model->B3SOIFDpubGiven) model->B3SOIFDpub = 0.0; if (!model->B3SOIFDpucGiven) model->B3SOIFDpuc = 0.0; if (!model->B3SOIFDpvsatGiven) model->B3SOIFDpvsat = 0.0; if (!model->B3SOIFDpa0Given) model->B3SOIFDpa0 = 0.0; if (!model->B3SOIFDpagsGiven) model->B3SOIFDpags = 0.0; if (!model->B3SOIFDpb0Given) model->B3SOIFDpb0 = 0.0; if (!model->B3SOIFDpb1Given) model->B3SOIFDpb1 = 0.0; if (!model->B3SOIFDpketaGiven) model->B3SOIFDpketa = 0.0; if (!model->B3SOIFDpabpGiven) model->B3SOIFDpabp = 0.0; if (!model->B3SOIFDpmxcGiven) model->B3SOIFDpmxc = 0.0; if (!model->B3SOIFDpadice0Given) model->B3SOIFDpadice0 = 0.0; if (!model->B3SOIFDpa1Given) model->B3SOIFDpa1 = 0.0; if (!model->B3SOIFDpa2Given) model->B3SOIFDpa2 = 0.0; if (!model->B3SOIFDprdswGiven) model->B3SOIFDprdsw = 0.0; if (!model->B3SOIFDpprwbGiven) model->B3SOIFDpprwb = 0.0; if (!model->B3SOIFDpprwgGiven) model->B3SOIFDpprwg = 0.0; if (!model->B3SOIFDpwrGiven) model->B3SOIFDpwr = 0.0; if (!model->B3SOIFDpnfactorGiven) model->B3SOIFDpnfactor = 0.0; if (!model->B3SOIFDpdwgGiven) model->B3SOIFDpdwg = 0.0; if (!model->B3SOIFDpdwbGiven) model->B3SOIFDpdwb = 0.0; if (!model->B3SOIFDpvoffGiven) model->B3SOIFDpvoff = 0.0; if (!model->B3SOIFDpeta0Given) model->B3SOIFDpeta0 = 0.0; if (!model->B3SOIFDpetabGiven) model->B3SOIFDpetab = 0.0; if (!model->B3SOIFDpdsubGiven) model->B3SOIFDpdsub = 0.0; if (!model->B3SOIFDpcitGiven) model->B3SOIFDpcit = 0.0; if (!model->B3SOIFDpcdscGiven) model->B3SOIFDpcdsc = 0.0; if (!model->B3SOIFDpcdscbGiven) model->B3SOIFDpcdscb = 0.0; if (!model->B3SOIFDpcdscdGiven) model->B3SOIFDpcdscd = 0.0; if (!model->B3SOIFDppclmGiven) model->B3SOIFDppclm = 0.0; if (!model->B3SOIFDppdibl1Given) model->B3SOIFDppdibl1 = 0.0; if (!model->B3SOIFDppdibl2Given) model->B3SOIFDppdibl2 = 0.0; if (!model->B3SOIFDppdiblbGiven) model->B3SOIFDppdiblb = 0.0; if (!model->B3SOIFDpdroutGiven) model->B3SOIFDpdrout = 0.0; if (!model->B3SOIFDppvagGiven) model->B3SOIFDppvag = 0.0; if (!model->B3SOIFDpdeltaGiven) model->B3SOIFDpdelta = 0.0; if (!model->B3SOIFDpaiiGiven) model->B3SOIFDpaii = 0.0; if (!model->B3SOIFDpbiiGiven) model->B3SOIFDpbii = 0.0; if (!model->B3SOIFDpciiGiven) model->B3SOIFDpcii = 0.0; if (!model->B3SOIFDpdiiGiven) model->B3SOIFDpdii = 0.0; if (!model->B3SOIFDpalpha0Given) model->B3SOIFDpalpha0 = 0.0; if (!model->B3SOIFDpalpha1Given) model->B3SOIFDpalpha1 = 0.0; if (!model->B3SOIFDpbeta0Given) model->B3SOIFDpbeta0 = 0.0; if (!model->B3SOIFDpagidlGiven) model->B3SOIFDpagidl = 0.0; if (!model->B3SOIFDpbgidlGiven) model->B3SOIFDpbgidl = 0.0; if (!model->B3SOIFDpngidlGiven) model->B3SOIFDpngidl = 0.0; if (!model->B3SOIFDpntunGiven) model->B3SOIFDpntun = 0.0; if (!model->B3SOIFDpndiodeGiven) model->B3SOIFDpndiode = 0.0; if (!model->B3SOIFDpisbjtGiven) model->B3SOIFDpisbjt = 0.0; if (!model->B3SOIFDpisdifGiven) model->B3SOIFDpisdif = 0.0; if (!model->B3SOIFDpisrecGiven) model->B3SOIFDpisrec = 0.0; if (!model->B3SOIFDpistunGiven) model->B3SOIFDpistun = 0.0; if (!model->B3SOIFDpedlGiven) model->B3SOIFDpedl = 0.0; if (!model->B3SOIFDpkbjt1Given) model->B3SOIFDpkbjt1 = 0.0; /* CV Model */ if (!model->B3SOIFDpvsdfbGiven) model->B3SOIFDpvsdfb = 0.0; if (!model->B3SOIFDpvsdthGiven) model->B3SOIFDpvsdth = 0.0;/* Added for binning - END */ if (!model->B3SOIFDcfGiven) model->B3SOIFDcf = 2.0 * EPSOX / PI * log(1.0 + 0.4e-6 / model->B3SOIFDtox); if (!model->B3SOIFDcgdoGiven) { if (model->B3SOIFDdlcGiven && (model->B3SOIFDdlc > 0.0)) { model->B3SOIFDcgdo = model->B3SOIFDdlc * model->B3SOIFDcox - model->B3SOIFDcgdl ; } else model->B3SOIFDcgdo = 0.6 * model->B3SOIFDxj * model->B3SOIFDcox; } if (!model->B3SOIFDcgsoGiven) { if (model->B3SOIFDdlcGiven && (model->B3SOIFDdlc > 0.0)) { model->B3SOIFDcgso = model->B3SOIFDdlc * model->B3SOIFDcox - model->B3SOIFDcgsl ; } else model->B3SOIFDcgso = 0.6 * model->B3SOIFDxj * model->B3SOIFDcox; } if (!model->B3SOIFDcgeoGiven) { model->B3SOIFDcgeo = 0.0; } if (!model->B3SOIFDxpartGiven) model->B3SOIFDxpart = 0.0; if (!model->B3SOIFDsheetResistanceGiven) model->B3SOIFDsheetResistance = 0.0; if (!model->B3SOIFDcsdeswGiven) model->B3SOIFDcsdesw = 0.0; if (!model->B3SOIFDunitLengthGateSidewallJctCapGiven) model->B3SOIFDunitLengthGateSidewallJctCap = 1e-10; if (!model->B3SOIFDGatesidewallJctPotentialGiven) model->B3SOIFDGatesidewallJctPotential = 0.7; if (!model->B3SOIFDbodyJctGateSideGradingCoeffGiven) model->B3SOIFDbodyJctGateSideGradingCoeff = 0.5; if (!model->B3SOIFDoxideTrapDensityAGiven) { if (model->B3SOIFDtype == NMOS) model->B3SOIFDoxideTrapDensityA = 1e20; else model->B3SOIFDoxideTrapDensityA=9.9e18; } if (!model->B3SOIFDoxideTrapDensityBGiven) { if (model->B3SOIFDtype == NMOS) model->B3SOIFDoxideTrapDensityB = 5e4; else model->B3SOIFDoxideTrapDensityB = 2.4e3; } if (!model->B3SOIFDoxideTrapDensityCGiven) { if (model->B3SOIFDtype == NMOS) model->B3SOIFDoxideTrapDensityC = -1.4e-12; else model->B3SOIFDoxideTrapDensityC = 1.4e-12; } if (!model->B3SOIFDemGiven) model->B3SOIFDem = 4.1e7; /* V/m */ if (!model->B3SOIFDefGiven) model->B3SOIFDef = 1.0; if (!model->B3SOIFDafGiven) model->B3SOIFDaf = 1.0; if (!model->B3SOIFDkfGiven) model->B3SOIFDkf = 0.0; if (!model->B3SOIFDnoifGiven) model->B3SOIFDnoif = 1.0; /* loop through all the instances of the model */ for (here = model->B3SOIFDinstances; here != NULL ; here=here->B3SOIFDnextInstance) { if (here->B3SOIFDowner == ARCHme) { /* allocate a chunk of the state vector */ here->B3SOIFDstates = *states; *states += B3SOIFDnumStates; } /* perform the parameter defaulting */ if (!here->B3SOIFDdrainAreaGiven) here->B3SOIFDdrainArea = 0.0; if (!here->B3SOIFDdrainPerimeterGiven) here->B3SOIFDdrainPerimeter = 0.0; if (!here->B3SOIFDdrainSquaresGiven) here->B3SOIFDdrainSquares = 1.0; if (!here->B3SOIFDicVBSGiven) here->B3SOIFDicVBS = 0; if (!here->B3SOIFDicVDSGiven) here->B3SOIFDicVDS = 0; if (!here->B3SOIFDicVGSGiven) here->B3SOIFDicVGS = 0; if (!here->B3SOIFDicVESGiven) here->B3SOIFDicVES = 0; if (!here->B3SOIFDicVPSGiven) here->B3SOIFDicVPS = 0; if (!here->B3SOIFDbjtoffGiven) here->B3SOIFDbjtoff = 0; if (!here->B3SOIFDdebugModGiven) here->B3SOIFDdebugMod = 0; if (!here->B3SOIFDrth0Given) here->B3SOIFDrth0 = model->B3SOIFDrth0; if (!here->B3SOIFDcth0Given) here->B3SOIFDcth0 = model->B3SOIFDcth0; if (!here->B3SOIFDbodySquaresGiven) here->B3SOIFDbodySquares = 1.0; if (!here->B3SOIFDlGiven) here->B3SOIFDl = 5e-6; if (!here->B3SOIFDsourceAreaGiven) here->B3SOIFDsourceArea = 0; if (!here->B3SOIFDsourcePerimeterGiven) here->B3SOIFDsourcePerimeter = 0; if (!here->B3SOIFDsourceSquaresGiven) here->B3SOIFDsourceSquares = 1; if (!here->B3SOIFDwGiven) here->B3SOIFDw = 5e-6; if (!here->B3SOIFDmGiven) here->B3SOIFDm = 1; if (!here->B3SOIFDoffGiven) here->B3SOIFDoff = 0; /* process drain series resistance */ if ((model->B3SOIFDsheetResistance > 0.0) && (here->B3SOIFDdrainSquares > 0.0 ) && (here->B3SOIFDdNodePrime == 0)) { error = CKTmkVolt(ckt,&tmp,here->B3SOIFDname,"drain"); if(error) return(error); here->B3SOIFDdNodePrime = tmp->number; if (ckt->CKTcopyNodesets) { if (CKTinst2Node(ckt,here,1,&tmpNode,&tmpName)==OK) { if (tmpNode->nsGiven) { tmp->nodeset=tmpNode->nodeset; tmp->nsGiven=tmpNode->nsGiven; } } } } else { here->B3SOIFDdNodePrime = here->B3SOIFDdNode; } /* process source series resistance */ if ((model->B3SOIFDsheetResistance > 0.0) && (here->B3SOIFDsourceSquares > 0.0 ) && (here->B3SOIFDsNodePrime == 0)) { error = CKTmkVolt(ckt,&tmp,here->B3SOIFDname,"source"); if(error) return(error); here->B3SOIFDsNodePrime = tmp->number; if (ckt->CKTcopyNodesets) { if (CKTinst2Node(ckt,here,3,&tmpNode,&tmpName)==OK) { if (tmpNode->nsGiven) { tmp->nodeset=tmpNode->nodeset; tmp->nsGiven=tmpNode->nsGiven; } } } } else { here->B3SOIFDsNodePrime = here->B3SOIFDsNode; } /* process effective silicon film thickness */ model->B3SOIFDcbox = 3.453133e-11 / model->B3SOIFDtbox; model->B3SOIFDcsi = 1.03594e-10 / model->B3SOIFDtsi; Cboxt = model->B3SOIFDcbox * model->B3SOIFDcsi / (model->B3SOIFDcbox + model->B3SOIFDcsi); model->B3SOIFDqsi = Charge_q*model->B3SOIFDnpeak*1e6*model->B3SOIFDtsi; /* Tsieff */ tmp1 = 2.0 * EPSSI * model->B3SOIFDvbsa / Charge_q / (1e6*model->B3SOIFDnpeak); tmp2 = model->B3SOIFDtsi * model->B3SOIFDtsi; if (tmp2 < tmp1) { fprintf(stderr, "vbsa = %.3f is too large for this tsi = %.3e and is automatically set to zero\n", model->B3SOIFDvbsa, model->B3SOIFDtsi); model->B3SOIFDcsieff = model->B3SOIFDcsi; model->B3SOIFDqsieff = model->B3SOIFDqsi; } else { tmp1 = sqrt(model->B3SOIFDtsi * model->B3SOIFDtsi - 2.0 * EPSSI * model->B3SOIFDvbsa / Charge_q / (1e6*model->B3SOIFDnpeak)); model->B3SOIFDcsieff = 1.03594e-10 / tmp1; model->B3SOIFDqsieff = Charge_q*model->B3SOIFDnpeak*1e6*tmp1; } model->B3SOIFDcsit = 1/(1/model->B3SOIFDcox + 1/model->B3SOIFDcsieff); model->B3SOIFDcboxt = 1/(1/model->B3SOIFDcbox + 1/model->B3SOIFDcsieff); nfb0 = 1/(1 + model->B3SOIFDcbox / model->B3SOIFDcsit); model->B3SOIFDnfb = model->B3SOIFDkb3 * nfb0; model->B3SOIFDadice = model->B3SOIFDadice0 / ( 1 + Cboxt / model->B3SOIFDcox); here->B3SOIFDfloat = 0; if (here->B3SOIFDbNode == -1) /* no internal body node is needed for SPICE iteration */ { here->B3SOIFDbNode = here->B3SOIFDpNode = 0; here->B3SOIFDbodyMod = 0; } else /* body tied */ { if ((model->B3SOIFDrbody == 0.0) && (model->B3SOIFDrbsh == 0.0)) { /* ideal body tie */ here->B3SOIFDbodyMod = 2; /* pNode is not used in this case */ } else { error = CKTmkVolt(ckt, &tmp, here->B3SOIFDname, "Body"); if(error) return(error); here->B3SOIFDbodyMod = 1; here->B3SOIFDpNode = here->B3SOIFDbNode; here->B3SOIFDbNode = tmp->number; } } if ((model->B3SOIFDshMod == 1) && (here->B3SOIFDrth0!=0)) {
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -