swallow permanently #define'ed `MUTUAL'
This commit is contained in:
parent
34f16236a4
commit
4b94193a20
|
|
@ -63,7 +63,6 @@ int INDmPTSize = NUMELEMS(INDmPTable);
|
|||
int INDiSize = sizeof(INDinstance);
|
||||
int INDmSize = sizeof(INDmodel);
|
||||
|
||||
#ifdef MUTUAL
|
||||
|
||||
IFparm MUTpTable[] = { /* parameters */
|
||||
IOPAP( "k", MUT_COEFF, IF_REAL , "Mutual inductance"),
|
||||
|
|
@ -86,5 +85,3 @@ int MUTpTSize = NUMELEMS(MUTpTable);
|
|||
int MUTmPTSize = 0;
|
||||
int MUTiSize = sizeof(INDinstance);
|
||||
int MUTmSize = sizeof(INDmodel);
|
||||
|
||||
#endif /*MUTUAL*/
|
||||
|
|
|
|||
|
|
@ -6,10 +6,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#ifndef IND
|
||||
#define IND
|
||||
|
||||
|
||||
/* turn on mutual inductor code */
|
||||
#define MUTUAL
|
||||
|
||||
#include "ngspice/ifsim.h"
|
||||
#include "ngspice/complex.h"
|
||||
#include "ngspice/gendefs.h"
|
||||
|
|
@ -106,7 +102,6 @@ typedef struct sINDmodel { /* model structure for an inductor */
|
|||
} INDmodel;
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
|
||||
/* structures used to describe mutual inductors */
|
||||
|
||||
|
|
@ -149,7 +144,6 @@ IFuid MUTmodName; /* pointer to character string naming this model */
|
|||
|
||||
} MUTmodel;
|
||||
|
||||
#endif /*MUTUAL*/
|
||||
|
||||
/* device parameters */
|
||||
#define IND_IND 1
|
||||
|
|
@ -186,7 +180,6 @@ IFuid MUTmodName; /* pointer to character string naming this model */
|
|||
#define IND_QUEST_SENS_CPLX 205
|
||||
#define IND_QUEST_SENS_DC 206
|
||||
|
||||
#ifdef MUTUAL
|
||||
/* device parameters */
|
||||
#define MUT_COEFF 401
|
||||
#define MUT_IND1 402
|
||||
|
|
@ -203,7 +196,6 @@ IFuid MUTmodName; /* pointer to character string naming this model */
|
|||
#define MUT_QUEST_SENS_CPLX 605
|
||||
#define MUT_QUEST_SENS_DC 606
|
||||
|
||||
#endif /*MUTUAL*/
|
||||
|
||||
#include "indext.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -24,12 +24,10 @@ INDload(GENmodel *inModel, CKTcircuit *ckt)
|
|||
double m;
|
||||
int error;
|
||||
|
||||
#ifdef MUTUAL
|
||||
MUTinstance *muthere;
|
||||
MUTmodel *mutmodel;
|
||||
int ktype;
|
||||
int itype;
|
||||
#endif
|
||||
|
||||
/* loop through all the inductor models */
|
||||
for( ; model != NULL; model = model->INDnextModel ) {
|
||||
|
|
@ -49,7 +47,6 @@ INDload(GENmodel *inModel, CKTcircuit *ckt)
|
|||
*(ckt->CKTrhsOld + here->INDbrEq);
|
||||
}
|
||||
}
|
||||
#ifdef MUTUAL
|
||||
}
|
||||
}
|
||||
ktype = CKTtypelook("mutual");
|
||||
|
|
@ -84,7 +81,6 @@ INDload(GENmodel *inModel, CKTcircuit *ckt)
|
|||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
|
||||
#endif /*MUTUAL*/
|
||||
if(ckt->CKTmode & MODEDC) {
|
||||
req = 0.0;
|
||||
veq = 0.0;
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@ INDsAcLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
INDmodel *model = (INDmodel*)inModel;
|
||||
INDinstance *here;
|
||||
double cind,icind,val,ival;
|
||||
#ifdef MUTUAL
|
||||
MUTinstance *muthere;
|
||||
MUTmodel *mutmodel;
|
||||
double cind1;
|
||||
|
|
@ -48,7 +47,6 @@ INDsAcLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
double k2;
|
||||
int ktype;
|
||||
int itype;
|
||||
#endif
|
||||
SENstruct *info;
|
||||
|
||||
info = ckt->CKTsenInfo;
|
||||
|
|
@ -59,7 +57,6 @@ INDsAcLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
|
||||
#ifdef MUTUAL
|
||||
}
|
||||
}
|
||||
ktype = CKTtypelook("mutual");
|
||||
|
|
@ -142,7 +139,6 @@ INDsAcLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
/* loop through all the instances of the model */
|
||||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
#endif /* MUTUAL */
|
||||
if(here->INDsenParmNo){
|
||||
cind = *(ckt->CKTrhsOld + here->INDbrEq);
|
||||
icind = *(ckt->CKTirhsOld + here->INDbrEq);
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ INDsLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
double tag1;
|
||||
SENstruct *info;
|
||||
|
||||
#ifdef MUTUAL
|
||||
MUTinstance *muthere;
|
||||
MUTmodel *mutmodel;
|
||||
double cind1;
|
||||
|
|
@ -39,7 +38,6 @@ INDsLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
int itype;
|
||||
int IND1_brEq;
|
||||
int IND2_brEq;
|
||||
#endif
|
||||
|
||||
info = ckt->CKTsenInfo;
|
||||
|
||||
|
|
@ -65,7 +63,6 @@ INDsLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
|
||||
#ifdef MUTUAL
|
||||
}
|
||||
}
|
||||
ktype = CKTtypelook("mutual");
|
||||
|
|
@ -122,7 +119,6 @@ INDsLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
|
||||
#endif /* MUTUAL */
|
||||
cind = *(ckt->CKTrhsOld + here->INDbrEq);
|
||||
#ifdef SENSDEBUG
|
||||
fprintf(stdout,"\n cind=%.5e\n",cind);
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ INDsUpdate(GENmodel *inModel, CKTcircuit *ckt)
|
|||
double dummy1;
|
||||
double dummy2;
|
||||
SENstruct *info;
|
||||
#ifdef MUTUAL
|
||||
MUTinstance *muthere;
|
||||
MUTmodel *mutmodel;
|
||||
double sxp1;
|
||||
|
|
@ -37,7 +36,6 @@ INDsUpdate(GENmodel *inModel, CKTcircuit *ckt)
|
|||
double rootl1,rootl2;
|
||||
int ktype;
|
||||
int itype;
|
||||
#endif
|
||||
|
||||
info = ckt->CKTsenInfo;
|
||||
if(ckt->CKTmode & MODEINITTRAN) return(OK);
|
||||
|
|
@ -65,9 +63,6 @@ INDsUpdate(GENmodel *inModel, CKTcircuit *ckt)
|
|||
|
||||
*(ckt->CKTstate0 + here->INDsensxp + 2 * (iparmno - 1)) = sxp;
|
||||
}
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
}
|
||||
}
|
||||
ktype = CKTtypelook("mutual");
|
||||
|
|
@ -128,7 +123,6 @@ INDsUpdate(GENmodel *inModel, CKTcircuit *ckt)
|
|||
/* loop through all the instances of the model */
|
||||
for (here = model->INDinstances; here != NULL ;
|
||||
here=here->INDnextInstance) {
|
||||
#endif /* MUTUAL */
|
||||
for(iparmno = 1;iparmno<=info->SENparms;iparmno++){
|
||||
|
||||
if(ckt->CKTmode&MODETRANOP){
|
||||
|
|
|
|||
|
|
@ -11,8 +11,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
int
|
||||
MUTacLoad(GENmodel *inModel, CKTcircuit *ckt)
|
||||
{
|
||||
|
|
@ -32,4 +30,3 @@ MUTacLoad(GENmodel *inModel, CKTcircuit *ckt)
|
|||
return(OK);
|
||||
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#ifdef MUTUAL
|
||||
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
|
|
@ -98,4 +97,3 @@ MUTask(CKTcircuit *ckt, GENinstance *inst, int which, IFvalue *value,
|
|||
}
|
||||
/* NOTREACHED */
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
int
|
||||
MUTdelete(GENmodel *inModel, IFuid name, GENinstance **kill)
|
||||
{
|
||||
|
|
@ -33,4 +32,3 @@ MUTdelete(GENmodel *inModel, IFuid name, GENinstance **kill)
|
|||
}
|
||||
return(E_NODEV);
|
||||
}
|
||||
#endif /*MUTUAL*/
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
void
|
||||
MUTdestroy(GENmodel **inModel)
|
||||
{
|
||||
|
|
@ -33,4 +32,3 @@ MUTdestroy(GENmodel **inModel)
|
|||
if(oldmod) FREE(oldmod);
|
||||
*model = NULL;
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -10,8 +10,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
int
|
||||
MUTmDelete(GENmodel **inModel, IFuid modname, GENmodel *kill)
|
||||
{
|
||||
|
|
@ -39,4 +37,3 @@ delgot:
|
|||
return(OK);
|
||||
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
/* ARGSUSED */
|
||||
int
|
||||
MUTparam(int param, IFvalue *value, GENinstance *inst, IFvalue *select)
|
||||
|
|
@ -40,4 +39,3 @@ MUTparam(int param, IFvalue *value, GENinstance *inst, IFvalue *select)
|
|||
}
|
||||
return(OK);
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
/* ARGSUSED */
|
||||
int
|
||||
MUTpzLoad(GENmodel *inModel, CKTcircuit *ckt, SPcomplex *s)
|
||||
|
|
@ -38,4 +37,3 @@ MUTpzLoad(GENmodel *inModel, CKTcircuit *ckt, SPcomplex *s)
|
|||
return(OK);
|
||||
|
||||
}
|
||||
#endif /*MUTUAL*/
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ Author: 1985 Thomas L. Quarles
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
MUTsetup(SMPmatrix *matrix, GENmodel *inModel, CKTcircuit *ckt, int *states)
|
||||
|
|
@ -69,4 +68,3 @@ do { if((here->ptr = SMPmakeElt(matrix, here->first, here->second)) == NULL){\
|
|||
}
|
||||
return(OK);
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ This function is obsolete (was used by an old sensitivity analysis)
|
|||
#include "ngspice/suffix.h"
|
||||
|
||||
|
||||
#ifdef MUTUAL
|
||||
/* ARGSUSED */
|
||||
void
|
||||
MUTsPrint(GENmodel *inModel, CKTcircuit* ckt)
|
||||
|
|
@ -48,4 +47,3 @@ MUTsPrint(GENmodel *inModel, CKTcircuit* ckt)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ This function is obsolete (was used by an old sensitivity analysis)
|
|||
#include "ngspice/sperror.h"
|
||||
#include "ngspice/suffix.h"
|
||||
|
||||
#ifdef MUTUAL
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
MUTsSetup(SENstruct *info, GENmodel *inModel)
|
||||
|
|
@ -41,4 +40,3 @@ MUTsSetup(SENstruct *info, GENmodel *inModel)
|
|||
}
|
||||
return(OK);
|
||||
}
|
||||
#endif /* MUTUAL */
|
||||
|
|
|
|||
Loading…
Reference in New Issue