Fixed a structure initailisation problem in the VBIC device that occurs when cider is enabled. Also fixed lots of warning within ciderlib related to unused variables.

This commit is contained in:
sjborley 2005-05-21 12:37:23 +00:00
parent 1a26f2218d
commit 5c08bf1576
31 changed files with 116 additions and 107 deletions

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
Modifed: 2001 Paolo Nenzi
$Id$
**********/
#include "ngspice.h"
@ -13,6 +14,7 @@ Modifed: 2001 Paolo Nenzi
#include "gendev.h"
#include "sperror.h"
#include "suffix.h"
#include "cidersupt.h"
extern int DOPnewCard(void**,void*);
extern int DOPparam(int,IFvalue*,void*);

View File

@ -2,6 +2,7 @@
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
Modified: 2001 Paolo Nenzi
$Id$
**********/
#include "ngspice.h"
@ -12,7 +13,7 @@ Modified: 2001 Paolo Nenzi
#include "material.h"
#include "sperror.h"
#include "suffix.h"
#include "cidersupt.h"
extern int MATLcheck( MATLcard * );
extern int MATLsetup( MATLcard *, MaterialInfo ** );

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
Modified: 2001 Paolo Nenzi
$Id$
**********/
/**********
Mesh Setup & Query Routines.
@ -906,10 +907,10 @@ twoSideSpacing(double width, double hStart, double hEnd, double rWanted,
double remaining; /* Length of span between hs and he */
double rTempS, rTempE; /* For temporarily calc'ed ratios */
double hsLast, heLast; /* Used to ensure ratio is valid */
double rConnect, rMin, rMax; /* " */
double rConnect; /* " */
double hMax, hMin; /* Max and min between hStart and hEnd */
double tmp;
int i,j; /* Indices for searching for best ratio */
int i; /* Indices for searching for best ratio */
int solnFound; /* For partial search termination */
int solnError; /* For partial search termination */
int nSaveS = 0; /* Saves best solution so far */
@ -1180,7 +1181,7 @@ maxLimSpacing(double width, double hStart, double hMax, double rWanted,
double rSaveS = 0.0; /* Saves best solution so far */
int nSaveS = 0; /* " */
int nSaveM = 0; /* " */
int i, j; /* Searching indices */
int i; /* Searching indices */
int solnFound; /* For partial search termination */
int solnError; /* For partial search termination */
char errBuf[80];

View File

@ -2,6 +2,7 @@
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
Modified: 2001 Paolo Nenzi
$Id$
**********/
#include "ngspice.h"
@ -24,10 +25,8 @@ extern int MODLsetup( MODLcard * );
int
MODLcheck(MODLcard *cardList)
{
MODLcard *card, *card2;
int cardNum = 0, cardNum2;
int error = OK;
char ebuf[512]; /* error message buffer */
MODLcard *card;
int cardNum = 0;
for ( card = cardList; card != NIL(MODLcard); card = card->MODLnextCard ) {
cardNum++;

View File

@ -2,6 +2,7 @@
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
Modified: 2001 Paolo Nenzi
$Id$
**********/
#include "ngspice.h"
@ -26,10 +27,8 @@ extern int OUTPsetup( OUTPcard * );
int
OUTPcheck(OUTPcard *cardList)
{
OUTPcard *card, *card2;
int cardNum = 0, cardNum2;
int error = OK;
char ebuf[512]; /* error message buffer */
OUTPcard *card;
int cardNum = 0;
for ( card = cardList; card != NIL(OUTPcard); card = card->OUTPnextCard ) {
cardNum++;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
/* Functions to compute device conductances and currents */
@ -171,10 +172,8 @@ NUMDcurrent(ONEdevice *pDevice, BOOLEAN tranAnalysis, double *intCoeff,
ONEnode *pNode;
ONEelem *pElem;
ONEedge *pEdge;
int index;
double *delta = pDevice->dcDeltaSolution;
double dPsi, dN, dP, *solution;
double dPsi, dN, dP;
*id = 0.0;
@ -203,7 +202,6 @@ NBJTcurrent(ONEdevice *pDevice, BOOLEAN tranAnalysis, double *intCoeff,
ONEnode *pNode;
ONEelem *pElem;
ONEedge *pEdge;
int index;
double dPsi, dN, dP;
double *solution;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -30,7 +31,7 @@ ONE_jacBuild(ONEdevice *pDevice)
{
char *matrix = pDevice->matrix;
ONEelem *pElem;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
int index, eIndex;
int psiEqn, nEqn, pEqn; /* scratch for deref'd eqn numbers */
int psiEqnL=0, nEqnL=0, pEqnL=0;
@ -112,12 +113,12 @@ ONE_sysLoad(ONEdevice *pDevice, BOOLEAN tranAnalysis,
ONEtranInfo *info)
{
ONEelem *pElem;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
ONEedge *pEdge;
int index, eIndex;
double *pRhs = pDevice->rhs;
double dx, rDx, dPsi;
double rhsN, rhsP, generation;
double generation;
double perTime = 0.0;
double fNd, fNa, fdNd, fdNa;
double netConc, dNd, dNa, psi, nConc, pConc;
@ -271,9 +272,9 @@ ONE_jacLoad(ONEdevice *pDevice)
ONEedge *pEdge;
int index, eIndex;
double dx, rDx, dPsi;
double rhsN, rhsP, generation;
double generation;
double fNd, fNa, fdNd, fdNa;
double netConc, dNd, dNa, psi, nConc, pConc;
double dNd, dNa, psi, nConc, pConc;
/* first compute the currents and their derivatives */
@ -385,12 +386,12 @@ ONE_rhsLoad(ONEdevice *pDevice, BOOLEAN tranAnalysis,
ONEtranInfo *info)
{
ONEelem *pElem;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
ONEedge *pEdge;
int index, eIndex;
double *pRhs = pDevice->rhs;
double dx, rDx, dPsi;
double rhsN, rhsP, generation;
double generation;
double perTime;
double fNd, fNa, fdNd, fdNa;
double netConc, dNd, dNa, psi, nConc, pConc;
@ -500,13 +501,13 @@ ONE_commonTerms(ONEdevice *pDevice, BOOLEAN currentOnly,
{
ONEelem *pElem;
ONEedge *pEdge;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
int index, eIndex;
double psi1, psi2, psi, nConc=0.0, pConc=0.0, nC, pC, nP1, pP1;
double dPsiN, dPsiP;
double bPsiN, dbPsiN, bMPsiN, dbMPsiN;
double bPsiP, dbPsiP, bMPsiP, dbMPsiP;
double mun, dMun, mup, dMup, rDx;
double mun, dMun, mup, dMup;
double conc1, conc2;
double cnAug, cpAug;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -14,7 +15,7 @@ Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
/* Forward Declarations */
static void ONEresetEvalFlag(ONEdevice *);
/* static void ONEresetEvalFlag(ONEdevice *); sjb - not used */
void
ONEbuildMesh(ONEdevice *pDevice, ONEcoord *pCoord, ONEdomain *pDomain,
@ -24,7 +25,7 @@ ONEbuildMesh(ONEdevice *pDevice, ONEcoord *pCoord, ONEdomain *pDomain,
int elemType;
double xPos;
ONEcoord *pC;
ONEnode *pNode, *pNextNode;
ONEnode *pNode;
ONEdomain *pD;
ONEelem *pElem;
ONEmaterial *pM;
@ -314,7 +315,6 @@ ONEprnMesh(ONEdevice *pDevice)
int eIndex, index;
ONEelem *pElem;
ONEnode *pNode;
ONEedge *pEdge;
char *name;
@ -354,6 +354,7 @@ ONEprnMesh(ONEdevice *pDevice)
}
}
/* sjb - not used
static void
ONEresetEvalFlag(ONEdevice *pDevice)
{
@ -369,3 +370,4 @@ ONEresetEvalFlag(ONEdevice *pDevice)
pElem->pEdge->evaluated = FALSE;
}
}
*/

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -45,7 +46,7 @@ void
ONEQsysLoad(ONEdevice *pDevice)
{
ONEelem *pElem;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
int index, i;
double *pRhs = pDevice->rhs;
double rDx, dPsi;
@ -154,7 +155,7 @@ ONEQcommonTerms(ONEdevice *pDevice)
{
ONEelem *pElem;
ONEedge *pEdge;
ONEnode *pNode, *pNode1;
ONEnode *pNode;
int i, index;
double psi1, psi2, refPsi;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -224,7 +225,6 @@ NUMDupdate(ONEdevice *pDevice, double delV, BOOLEAN updateBoundary)
{
ONEelem *pElem = pDevice->elemArray[pDevice->numNodes - 1];
ONEnode *pNode;
ONEedge *pEdge;
double delPsi, delN, delP;
int i, index;
@ -322,9 +322,9 @@ NBJTsetBCs(ONEdevice *pDevice, double vce, double vbe)
{
ONEelem *pLastElem = pDevice->elemArray[pDevice->numNodes - 1];
ONEelem *pBaseElem = pDevice->elemArray[pDevice->baseIndex - 1];
ONEnode *pNode;
/* ONEnode *pNode;
double psi, conc, sign, absConc;
double nie, ni, pi;
double nie, ni, pi; */
/* normalize the voltages */
vce = vce / VNorm;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/*
@ -29,7 +30,6 @@ ONEreadState(ONEdevice *pDevice, char *fileName, int numVolts,
ONEnode **nodeArray=NULL;
ONEnode *pNode;
ONEelem *pElem;
ONEmaterial *info;
double refPsi = 0.0;
double *psiData, *nData, *pData;
double *vData[2];

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/**********
@ -27,7 +28,6 @@ ONEsetup(ONEdevice *pDevice)
double temp1, deltaEg, avgConc, totalConc, absNetConc;
double ncv0, dBand, dNie, psiBand[2];
int index, eIndex;
int numContactNodes;
ONEnode *pNode;
ONEelem *pElem;
ONEedge *pEdge;
@ -120,7 +120,7 @@ ONEcopyBCinfo(ONEdevice *pDevice, ONEelem *pElem, BDRYcard *bdry, int index)
{
ONEnode *pNode;
ONEelem *pNElem;
int eIndex, nIndex;
int eIndex;
double length;
@ -154,13 +154,10 @@ void
ONEsetBCparams(ONEdevice *pDevice, BDRYcard *bdryList, CONTcard *contList)
{
int index, xIndex;
ONEnode *pNode;
ONEelem *pElem, *pNElem;
BDRYcard *bdry;
CONTcard *cont;
for (bdry = bdryList; bdry != NIL(BDRYcard); bdry = bdry->BDRYnextCard) {
for (xIndex = bdry->BDRYixLow; xIndex < bdry->BDRYixHigh; xIndex++) {
pElem = pDevice->elemArray[xIndex];

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/*
@ -51,7 +52,7 @@ ONEdcSolve(ONEdevice *pDevice, int iterationLimit, BOOLEAN newSolver,
BOOLEAN quitLoop;
BOOLEAN debug = FALSE;
double *rhs = pDevice->rhs;
double *intermediate = pDevice->copiedSolution;
/* double *intermediate = pDevice->copiedSolution; */
double *solution = pDevice->dcSolution;
double *delta = pDevice->dcDeltaSolution;
double poissNorm, contNorm;
@ -928,7 +929,7 @@ ONEtrunc(ONEdevice *pDevice, ONEtranInfo *info, double delta)
int nIndex, eIndex;
ONEelem *pElem;
ONEnode *pNode;
double tolN, tolP, lte, relError, temp, relLTE;
double tolN, tolP, lte, relError, temp;
double lteCoeff = info->lteCoeff;
double mult = 10.0;
double reltol;
@ -1010,11 +1011,6 @@ ONEsaveState(ONEdevice *pDevice)
double
ONEnuNorm(ONEdevice *pDevice)
{
double norm = 0.0;
double temp;
int index;
/* The LU Decomposed matrix is available. Use it to calculate x. */
spSolve(pDevice->matrix, pDevice->rhs, pDevice->rhsImag,
NIL(spREAL), NIL(spREAL));

View File

@ -1,6 +1,7 @@
/**********
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -92,7 +93,7 @@ void
computePredCoeff(int method, int order, double *predCoeff, double *delta)
{
int i, j, k;
double num, denom, prod, temp;
double num, denom, prod;
if( method == TRAPEZOIDAL && order > 2 ) {
printf("\n computePredCoeff: order > 2 for trapezoidal");

View File

@ -2,18 +2,20 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/* Functions to read SUPREM (Binary or Ascii) & ASCII input files */
#include "ngspice.h"
#include "profile.h"
#include "cidersupt.h"
void
readAsciiData( char *fileName, int impType, DOPtable **ppTable )
{
FILE *fpAscii;
int index, i;
int index;
double x, y;
int numPoints;
DOPtable *tmpTable;
@ -45,7 +47,7 @@ readAsciiData( char *fileName, int impType, DOPtable **ppTable )
profileData[0][0] = numPoints;
for( index = 1; index <= numPoints; index++ ) {
fscanf( fpAscii, "%f %f ", &x, &y );
fscanf( fpAscii, "%lf %lf ", &x, &y );
profileData[ 0 ][ index ] = x;
profileData[ 1 ][ index ] = sign * ABS(y);
}
@ -117,11 +119,10 @@ DOPtable **ppTable;
#define MAX_GRID 500
float x[ MAX_GRID ], conc[ MAX_GRID ];
int index, i, j;
int index;
DOPtable *tmpTable;
double **profileData;
int numNodes;
char *colon, *impName;
/* read the Suprem data file */
if ( fileType == 0 ) { /* BINARY FILE */

View File

@ -1,6 +1,7 @@
/**********
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
/* Functions to compute the ac admittances of a device. */
@ -346,7 +347,7 @@ NUMOSadmittance(TWOdevice *pDevice, double omega, struct mosAdmittances *yAc)
TWOcontact *pDContact = pDevice->pFirstContact;
TWOcontact *pGContact = pDevice->pFirstContact->next;
TWOcontact *pSContact = pDevice->pFirstContact->next->next;
TWOcontact *pBContact = pDevice->pLastContact;
/* TWOcontact *pBContact = pDevice->pLastContact; */
TWOnode *pNode;
TWOelem *pElem;
int index, eIndex;
@ -762,7 +763,6 @@ contactAdmittance(TWOdevice *pDevice, TWOcontact *pContact, BOOLEAN delVContact,
TWOelem *pElem;
SPcomplex psiAc, nAc, pAc;
SPcomplex prod1, prod2, sum;
double yReal, yImag;
double temp;
CMPLX_ASSIGN_VALUE(yTotal, 0.0, 0.0);
@ -961,9 +961,8 @@ oxideAdmittance(TWOdevice *pDevice, TWOcontact *pContact, BOOLEAN delVContact,
TWOedge *pHEdge, *pVEdge;
int index, i, indexPsi, numContactNodes;
TWOelem *pElem;
SPcomplex psiAc, nAc, pAc;
SPcomplex prod1, prod2, sum;
double yReal, yImag;
SPcomplex psiAc;
SPcomplex prod1, prod2;
CMPLX_ASSIGN_VALUE(yTotal, 0.0, 0.0);
@ -1205,7 +1204,7 @@ NUMOSys(TWOdevice *pDevice, SPcomplex *s, struct mosAdmittances *yAc)
TWOcontact *pDContact = pDevice->pFirstContact;
TWOcontact *pGContact = pDevice->pFirstContact->next;
TWOcontact *pSContact = pDevice->pFirstContact->next->next;
TWOcontact *pBContact = pDevice->pLastContact;
/* TWOcontact *pBContact = pDevice->pLastContact; */
TWOnode *pNode;
TWOelem *pElem;
int index, eIndex;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
$Id$
**********/
/* Functions to compute terminal conductances & currents. */
@ -21,7 +22,6 @@ void
double *intCoeff, double *gd)
{
TWOcontact *pContact = pDevice->pFirstContact;
int index;
double *incVpn;
BOOLEAN deltaVContact = FALSE;
@ -47,7 +47,6 @@ void
TWOcontact *pEmitContact = pDevice->pLastContact;
TWOcontact *pColContact = pDevice->pFirstContact;
TWOcontact *pBaseContact = pDevice->pFirstContact->next;
int index;
double width = pDevice->width;
double *incVce, *incVbe;
@ -86,8 +85,6 @@ void
TWOcontact *pDContact = pDevice->pFirstContact;
TWOcontact *pGContact = pDevice->pFirstContact->next;
TWOcontact *pSContact = pDevice->pFirstContact->next->next;
TWOcontact *pBContact = pDevice->pLastContact;
int index;
double width = pDevice->width;
double *incVdb, *incVsb, *incVgb;
@ -433,7 +430,7 @@ double
int index, i, numContactNodes;
TWOnode *pNode, *pHNode = NULL, *pVNode = NULL;
TWOelem *pElem;
double dPsiDv, dnDv, dpDv;
double dPsiDv;
double gTotal = 0.0;
if ( !tranAnalysis ) {
@ -499,10 +496,9 @@ void
double *intCoeff, double *id)
{
TWOcontact *pPContact = pDevice->pFirstContact;
TWOcontact *pNContact = pDevice->pLastContact;
int index;
/* TWOcontact *pNContact = pDevice->pLastContact; */
double ip, ipPrime, *solution;
double in;
/* double in;*/
BOOLEAN deltaVContact = FALSE;
solution = pDevice->dcDeltaSolution;
@ -532,9 +528,9 @@ void
{
TWOcontact *pEmitContact = pDevice->pLastContact;
TWOcontact *pColContact = pDevice->pFirstContact;
TWOcontact *pBaseContact = pDevice->pFirstContact->next;
/* TWOcontact *pBaseContact = pDevice->pFirstContact->next; */
double *solution, iePrime, icPrime;
double ib;
/* double ib; */
solution = pDevice->dcDeltaSolution;
@ -567,9 +563,9 @@ void
TWOcontact *pDContact = pDevice->pFirstContact;
TWOcontact *pGContact = pDevice->pFirstContact->next;
TWOcontact *pSContact = pDevice->pFirstContact->next->next;
TWOcontact *pBContact = pDevice->pLastContact;
/* TWOcontact *pBContact = pDevice->pLastContact; */
double *solution, idPrime, isPrime, igPrime;
double ib;
/* double ib; */
solution = pDevice->dcDeltaSolution;

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -669,7 +670,6 @@ void
TWOnode *pNode;
TWOedge *pHEdge, *pVEdge;
TWOedge *pTEdge, *pBEdge, *pLEdge, *pREdge;
TWOchannel *pCh;
int index, eIndex;
double *pRhs = pDevice->rhs;
double dx, dy, dxdy, dyOverDx, dxOverDy;
@ -797,7 +797,7 @@ void
TWO_commonTerms(TWOdevice *pDevice, BOOLEAN currentOnly,
BOOLEAN tranAnalysis, TWOtranInfo *info)
{
TWOelem *pElem, *pElem1;
TWOelem *pElem;
TWOedge *pEdge;
TWOnode *pNode;
int index, eIndex;

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -26,7 +27,6 @@ TWObuildMesh(TWOdevice *pDevice, TWOdomain *pDomain,
{
int xIndex, yIndex, eIndex, index;
int elemType;
TWOcoord *pX, *pY;
TWOelem *pElem, *pElem1;
TWOnode *pNode, *pNode1, *pNextHNode, *pNextVNode, *pNextDNode;
TWOnode ***nodeArray = NULL;
@ -35,14 +35,15 @@ TWObuildMesh(TWOdevice *pDevice, TWOdomain *pDomain,
TWOdomain *pD;
TWOelectrode *pE;
TWOmaterial *pM;
BOOLEAN error = FALSE;
BOOLEAN interiorNode;
int poiEqn, numEqn, numElem, numNodes, numEdges;
int numXNodes = pDevice->numXNodes;
int numYNodes = pDevice->numYNodes;
double *xScale = pDevice->xScale;
double *yScale = pDevice->yScale;
#ifdef NOTDEF
FILE *meshFile;
#endif
/* Generate work arrays. */
XCALLOC(nodeArray, TWOnode **, 1 + numXNodes);

View File

@ -1,6 +1,7 @@
/**********
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1990 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -25,7 +26,7 @@ MOBsurfElec(TWOmaterial *info, TWOelem *pElem, double ex, double ey,
double thetaB = info->thetaB[ELEC];
double eL, eN, eD, e0, mun;
double temp1, temp2, temp3, temp4, temp5;
double temp6, temp7, temp8, temp9, temp10;
double temp6, temp7, temp8, temp9;
double sgnN, sgnL;
double dMunDEs; /* Surface Field Derivative */
double dMunDEn; /* (Local) Normal Field Derivative */
@ -225,7 +226,7 @@ MOBsurfHole(TWOmaterial *info, TWOelem *pElem, double ex, double ey,
double thetaB = info->thetaB[HOLE];
double eL, eN, eD, mup;
double temp1, temp2, temp3, temp4, temp5;
double temp6, temp7, temp8, temp9, temp10;
double temp6, temp7, temp8, temp9;
double sgnN, sgnL;
double dMupDEs; /* Surface Field Derivative */
double dMupDEn; /* (Local) Normal Field Derivative */

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -556,7 +557,6 @@ void
TWOnode *pNode;
TWOedge *pHEdge, *pVEdge;
TWOedge *pTEdge, *pBEdge, *pLEdge, *pREdge;
TWOchannel *pCh;
int index, eIndex;
double *pRhs = pDevice->rhs;
double dx, dy, dxdy, dyOverDx, dxOverDy;
@ -670,7 +670,7 @@ void
TWONcommonTerms(TWOdevice *pDevice, BOOLEAN currentOnly,
BOOLEAN tranAnalysis, TWOtranInfo *info)
{
TWOelem *pElem, *pElem1;
TWOelem *pElem;
TWOedge *pEdge;
TWOnode *pNode;
int index, eIndex;

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -554,7 +555,6 @@ void
TWOnode *pNode;
TWOedge *pHEdge, *pVEdge;
TWOedge *pTEdge, *pBEdge, *pLEdge, *pREdge;
TWOchannel *pCh;
int index, eIndex;
double *pRhs = pDevice->rhs;
double dx, dy, dxdy, dyOverDx, dxOverDy;
@ -668,7 +668,7 @@ void
TWOPcommonTerms(TWOdevice *pDevice, BOOLEAN currentOnly,
BOOLEAN tranAnalysis, TWOtranInfo *info)
{
TWOelem *pElem, *pElem1;
TWOelem *pElem;
TWOedge *pEdge;
TWOnode *pNode;
int index, eIndex;

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -95,7 +96,7 @@ void
TWOQsysLoad(TWOdevice *pDevice)
{
TWOelem *pElem;
TWOnode *pNode, *pNode1;
TWOnode *pNode;
TWOedge *pHEdge, *pVEdge;
int index, eIndex;
double *pRhs = pDevice->rhs;
@ -175,7 +176,7 @@ void
TWOQrhsLoad(TWOdevice *pDevice)
{
TWOelem *pElem;
TWOnode *pNode, *pNode1;
TWOnode *pNode;
TWOedge *pHEdge, *pVEdge;
int index, eIndex;
double *pRhs = pDevice->rhs;
@ -240,7 +241,7 @@ TWOQcommonTerms(TWOdevice *pDevice)
{
TWOelem *pElem;
TWOedge *pEdge;
TWOnode *pNode, *pNode1;
TWOnode *pNode;
int index, eIndex;
double psi1, psi2, refPsi;

View File

@ -2,6 +2,7 @@
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -19,11 +20,11 @@ Author: 1992 David A. Gates, U. C. Berkeley CAD Group
void
TWOprnSolution(FILE *file, TWOdevice *pDevice, OUTPcard *output)
{
int i, index, xIndex, yIndex;
int index, xIndex, yIndex;
int numVars = 0;
TWOnode ***nodeArray = NULL;
TWOnode *pNode;
TWOelem *pElem, *pNextElem;
TWOelem *pElem;
TWOmaterial *info;
double data[50];
double ex, ey, refPsi = 0.0, eGap, dGap;
@ -344,7 +345,7 @@ void
TWOmemStats(FILE *file, TWOdevice *pDevice)
{
static char *memFormat = "%-20s%10d%10d\n";
static char *sumFormat = "%20s %-10d\n";
/* static char *sumFormat = "%20s %-10d\n"; */
unsigned int size;
unsigned int memory;
TWOmaterial *pMaterial;

View File

@ -1,6 +1,7 @@
/**********
Copyright 1992 Regents of the University of California. All rights reserved.
Author: 1992 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/*
@ -30,7 +31,6 @@ TWOreadState(TWOdevice *pDevice, char *fileName, int numVolts, double *pV1,
TWOnode ***nodeArray = NULL;
TWOnode *pNode;
TWOelem *pElem;
TWOmaterial *info;
double refPsi = 0.0;
double *psiData, *nData, *pData;
double *vData[3];

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
/**********
@ -252,9 +253,7 @@ static void TWOcopyBCinfo( pDevice, pElem, card, index )
void TWOsetBCparams(TWOdevice *pDevice, BDRYcard *cardList)
{
int index, xIndex, yIndex; /* Need to access in X/Y order. */
TWOnode *pNode;
TWOelem *pElem, *pNElem;
TWOedge *pEdge;
BDRYcard *card;
for ( card = cardList; card != NIL(BDRYcard); card = card->BDRYnextCard ) {

View File

@ -2,6 +2,7 @@
Copyright 1991 Regents of the University of California. All rights reserved.
Author: 1987 Kartikeya Mayaram, U. C. Berkeley CAD Group
Author: 1991 David A. Gates, U. C. Berkeley CAD Group
$Id$
**********/
#include "ngspice.h"
@ -805,7 +806,7 @@ int
TWOnewDelta(TWOdevice *pDevice, BOOLEAN tranAnalysis, TWOtranInfo *info)
{
int index, iterNum = 0;
double newNorm, origNorm;
double newNorm;
double fib, lambda, fibn, fibp;
BOOLEAN acceptable = FALSE, error = FALSE;
@ -940,7 +941,7 @@ TWOtrunc(TWOdevice *pDevice, TWOtranInfo *info, double delta)
int nIndex, eIndex;
TWOelem *pElem;
TWOnode *pNode;
double tolN, tolP, lte, relError, temp, relLTE;
double tolN, tolP, lte, relError, temp;
double lteCoeff = info->lteCoeff;
double mult = 10.0;
double reltol;

View File

@ -2,11 +2,16 @@
* cidersupt.h
*
* CIDER support library header
* $Id$
*/
#ifndef _CIDERSUPT_H
#define _CIDERSUPT_H
#include "numglobs.h"
#include "material.h"
#include "gendev.h"
#include "profile.h"
/* externals for database.c */
extern struct plot* DBread( char *);

View File

@ -39,6 +39,7 @@
#endif
#include <stdio.h>
#include <string.h>
/* Comment out all this code if we are using the GNU C Library, and are not
actually compiling the library itself. This code is part of the GNU C

View File

@ -1,3 +1,10 @@
/*
* vbicinit.c
*
* $Id$
*/
#include "config.h"
#include "devdefs.h"
@ -67,7 +74,10 @@ SPICEdev VBICinfo = {
NULL, /* DEVsenTrunc */
NULL, /* DEVdisto */
VBICnoise, /* DEVnoise */
#ifdef CIDER
NULL, /* DEVdump */
NULL, /* DEVacct */
#endif
&VBICiSize, /* DEVinstSize */
&VBICmSize /* DEVmodSize */

View File

@ -2,6 +2,7 @@
Copyright 1990 Regents of the University of California. All rights reserved.
Author: 1985 Thomas L. Quarles, 1991 David A. Gates
Modified: 2001 Paolo Nenzi (Cider Integration)
$Id$
**********/
#include "ngspice.h"
@ -24,6 +25,10 @@ extern int INPnumCards;
#define E_MISSING -1
#define E_AMBIGUOUS -2
static int INPparseNumMod( void* ckt, INPmodel *model, INPtables *tab, char **errMessage );
static int INPfindCard( char *name, IFcardInfo *table[], int numCards );
static int INPfindParm( char *name, IFparm *table, int numParms );
/* end Cider Integration */
#endif /* CIDER */
@ -189,12 +194,8 @@ char *INPgetMod(void *ckt, char *name, INPmodel ** model, INPtables * tab)
* '+' = continue previous card
* other = new card
*/
int
INPparseNumMod( ckt, model, tab, errMessage )
void* ckt;
INPmodel *model;
INPtables *tab;
char **errMessage;
static int
INPparseNumMod( void* ckt, INPmodel *model, INPtables *tab, char **errMessage )
{
card *txtCard; /* Text description of a card */
GENcard *tmpCard; /* Processed description of a card */
@ -344,11 +345,8 @@ INPparseNumMod( ckt, model, tab, errMessage )
/*
* Locate the best match to a card name in an IFcardInfo table
*/
int
INPfindCard( name, table, numCards )
char *name;
IFcardInfo *table[];
int numCards;
static int
INPfindCard( char *name, IFcardInfo *table[], int numCards )
{
int test;
int match, bestMatch;
@ -375,11 +373,8 @@ INPfindCard( name, table, numCards )
/*
* Locate the best match to a parameter name in an IFparm table
*/
int
INPfindParm( name, table, numParms )
char *name;
IFparm *table;
int numParms;
static int
INPfindParm( char *name, IFparm *table, int numParms )
{
int test, best;
int match, bestMatch;