re-enable CIDER with option sparse by setting CKTkluMODE

in new matrix to CKTkluMODE from current circuit.
This commit is contained in:
Holger Vogt 2020-09-01 21:31:26 +02:00
parent 98dd7da1c4
commit 3bb643c8f5
2 changed files with 10 additions and 4 deletions

View File

@ -22,6 +22,9 @@ Author: 1991 David A. Gates, U. C. Berkeley CAD Group
#include "../../maths/misc/norm.h"
#include "ngspice/ifsim.h"
#include "ngspice/cktdefs.h"
#include "ngspice/ftedefs.h"
extern IFfrontEnd *SPfrontEnd;
@ -591,7 +594,7 @@ ONEequilSolve(ONEdevice *pDevice)
pDevice->matrix = TMALLOC (SMPmatrix, 1) ;
#ifdef KLU
pDevice->matrix->CKTkluMODE = CKTkluON ; /* Francesco Lannutti - To be sustitued with a value coming from the uplevel */
pDevice->matrix->CKTkluMODE = ft_curckt->ci_ckt->CKTkluMODE ;
error = SMPnewMatrixKLUforCIDER (pDevice->matrix, pDevice->numEqns, KLUmatrixReal) ;
#else
error = SMPnewMatrixForCIDER (pDevice->matrix, pDevice->numEqns, 0) ;
@ -749,7 +752,7 @@ ONEbiasSolve(ONEdevice *pDevice, int iterationLimit,
pDevice->matrix = TMALLOC (SMPmatrix, 1) ;
#ifdef KLU
pDevice->matrix->CKTkluMODE = CKTkluON ; /* Francesco Lannutti - To be sustitued with a value coming from the uplevel */
pDevice->matrix->CKTkluMODE = ft_curckt->ci_ckt->CKTkluMODE ;
error = SMPnewMatrixKLUforCIDER (pDevice->matrix, pDevice->numEqns, KLUMatrixComplex) ;
#else
error = SMPnewMatrixForCIDER (pDevice->matrix, pDevice->numEqns, 1) ;

View File

@ -18,6 +18,9 @@ Author: 1991 David A. Gates, U. C. Berkeley CAD Group
#include "ngspice/twomesh.h"
#include "twoddefs.h"
#include "twodext.h"
#include "ngspice/cktdefs.h"
#include "ngspice/ftedefs.h"
extern IFfrontEnd *SPfrontEnd;
@ -504,7 +507,7 @@ int TWOequilSolve(TWOdevice *pDevice)
pDevice->matrix = TMALLOC (SMPmatrix, 1) ;
#ifdef KLU
pDevice->matrix->CKTkluMODE = CKTkluON ; /* Francesco Lannutti - To be sustitued with a value coming from the uplevel */
pDevice->matrix->CKTkluMODE = ft_curckt->ci_ckt->CKTkluMODE ;
error = SMPnewMatrixKLUforCIDER (pDevice->matrix, pDevice->numEqns, KLUmatrixReal) ;
#else
error = SMPnewMatrixForCIDER (pDevice->matrix, pDevice->numEqns, 0) ;
@ -663,7 +666,7 @@ TWObiasSolve(TWOdevice *pDevice, int iterationLimit, BOOLEAN tranAnalysis,
pDevice->matrix = TMALLOC (SMPmatrix, 1) ;
#ifdef KLU
pDevice->matrix->CKTkluMODE = CKTkluON ; /* Francesco Lannutti - To be sustitued with a value coming from the uplevel */
pDevice->matrix->CKTkluMODE = ft_curckt->ci_ckt->CKTkluMODE ;
error = SMPnewMatrixKLUforCIDER (pDevice->matrix, pDevice->numEqns, KLUMatrixComplex) ;
#else
error = SMPnewMatrixForCIDER (pDevice->matrix, pDevice->numEqns, 1) ;