48 #include <Xyce_config.h>
65 #include <N_ERH_ErrorMgr.h>
67 #include <N_UTL_BreakPoint.h>
74 std::vector<Param> sourceFcnParamList;
76 sourceFcnParamList.resize(7);
77 sourceFcnParamList[0].set(
"V1", 0.0);
78 sourceFcnParamList[1].set(
"V2", 0.0);
79 sourceFcnParamList[2].set(
"TD", 0.0);
80 sourceFcnParamList[3].set(
"TR", 0.0);
81 sourceFcnParamList[4].set(
"TF", 0.0);
82 sourceFcnParamList[5].set(
"PW", 0.0);
83 sourceFcnParamList[6].set(
"PER", 0.0);
84 sourceFcnMap[
"PULSE" ] = sourceFcnParamList;
86 sourceFcnParamList.resize(6);
87 sourceFcnParamList[0].set(
"V0", 0.0);
88 sourceFcnParamList[1].set(
"VA", 0.0);
89 sourceFcnParamList[2].set(
"FREQ", 0.0);
90 sourceFcnParamList[3].set(
"TD", 0.0);
91 sourceFcnParamList[4].set(
"THETA", 0.0);
92 sourceFcnParamList[5].set(
"PHASE", 0.0);
93 sourceFcnMap[
"SIN" ] = sourceFcnParamList;
95 sourceFcnParamList.resize(6);
96 sourceFcnParamList[0].set(
"V1", 0.0);
97 sourceFcnParamList[1].set(
"V2", 0.0);
98 sourceFcnParamList[2].set(
"TD1", 0.0);
99 sourceFcnParamList[3].set(
"TAU1", 0.0);
100 sourceFcnParamList[4].set(
"TD2", 0.0);
101 sourceFcnParamList[5].set(
"TAU2", 0.0);
102 sourceFcnMap[
"EXP" ] = sourceFcnParamList;
103 sourceFcnParamList.resize(5);
104 sourceFcnParamList[0].set(
"V0", 0.0);
105 sourceFcnParamList[1].set(
"VA", 0.0);
106 sourceFcnParamList[2].set(
"FC", 0.0);
107 sourceFcnParamList[3].set(
"MDI", 0.0);
108 sourceFcnParamList[4].set(
"FS", 0.0);
109 sourceFcnMap[
"SFFM" ] = sourceFcnParamList;
113 sourceFcnParamList.clear();
114 sourceFcnMap[
"PWL" ] = sourceFcnParamList;
116 sourceFcnParamList.resize(8);
117 sourceFcnParamList[0].set(
"V1", 0.0);
118 sourceFcnParamList[1].set(
"V2", 0.0);
119 sourceFcnParamList[2].set(
"TD", 0.0);
120 sourceFcnParamList[3].set(
"TR", 0.0);
121 sourceFcnParamList[4].set(
"TF", 0.0);
122 sourceFcnParamList[5].set(
"PW", 0.0);
123 sourceFcnParamList[6].set(
"PER", 0.0);
124 sourceFcnParamList[7].set(
"SF", 0.0);
125 sourceFcnMap[
"SMOOTHPULSE" ] = sourceFcnParamList;
140 initializeFlag_(false),
147 defaultParamName_(
"") ,
148 fastTimeScaleFlag_(false),
161 : SourceValue (right.SourceValue),
162 initializeFlag_(right.initializeFlag_),
163 resetFlag_(right.resetFlag_),
164 solState_(right.solState_),
166 devOptions_(right.devOptions_),
167 typeName_(right.typeName_),
168 sourceName_(right.sourceName_),
169 defaultParamName_(right.defaultParamName_)
225 #ifdef Xyce_DEBUG_DEVICE
234 void SourceData::printOutParams()
263 double tmpTime = 0.0;
272 #ifdef Xyce_DEBUG_DEVICE
276 Xyce::dout() <<
"SourceData::getTime. time = ";
277 Xyce::dout() << tmpTime << std::endl;
278 Xyce::dout() <<
"SourceData::getTime. currFastTime = ";
280 Xyce::dout() <<
"SourceData::getTime. currTime = ";
306 V0given(right.V0given),
307 VAgiven(right.VAgiven),
308 FREQgiven(right.FREQgiven),
309 TDgiven(right.TDgiven),
310 THETAgiven(right.THETAgiven),
311 PHASEgiven(right.PHASEgiven)
329 #define FREQ (((here->VSRCfunctionOrder >=3) && (*(here->VSRCcoeffs+2)))? \
330 (*(here->VSRCcoeffs+2)):(1/ckt->CKTfinalTime))
350 std::vector<Param>::const_iterator iter = paramRef.begin();
351 std::vector<Param>::const_iterator last = paramRef.end();
353 for ( ; iter != last; ++iter)
355 const std::string & tmpname = iter->tag();
357 if (tmpname ==
"V0") {
V0 = iter->getImmutableValue<
double>();
V0given = iter->given();}
358 if (tmpname ==
"VA") {
VA = iter->getImmutableValue<
double>();
VAgiven = iter->given();}
359 if (tmpname ==
"FREQ") {
FREQ = iter->getImmutableValue<
double>();
FREQgiven = iter->given();}
360 if (tmpname ==
"TD") {
TD = iter->getImmutableValue<
double>();
TDgiven = iter->given();}
361 if (tmpname ==
"THETA") {
THETA = iter->getImmutableValue<
double>();
THETAgiven = iter->given();}
362 if (tmpname ==
"PHASE") {
PHASE = iter->getImmutableValue<
double>();
PHASEgiven = iter->given();}
366 Report::UserError() <<
"V0, VA and FREQ are required for the SIN source function";
408 #ifdef Xyce_DEBUG_DEVICE
418 void SinData::printOutParams()
421 Xyce::dout() <<
"SinData:\n";
422 Xyce::dout() <<
"V0 = " <<
V0 << std::endl;
423 Xyce::dout() <<
"VA = " <<
VA << std::endl;
424 Xyce::dout() <<
"FREQ = " <<
FREQ << std::endl;
425 Xyce::dout() <<
"TD = " <<
TD << std::endl;
426 Xyce::dout() <<
"THETA = " <<
THETA << std::endl;
427 Xyce::dout() <<
"PHASE = " <<
PHASE << std::endl;
451 bool bsuccess =
true;
527 if (
FREQ != params[3])
532 if (
THETA != params[4])
537 if (
PHASE != params[5])
566 V1given (right.V1given),
567 V2given (right.V2given),
568 TD1given (right.TD1given),
569 TAU1given (right.TAU1given),
570 TD2given (right.TD2given),
571 TAU2given (right.TAU2given)
600 std::vector<Param>::const_iterator iter = paramRef.begin();
601 std::vector<Param>::const_iterator last = paramRef.end();
603 for ( ; iter != last; ++iter)
605 const std::string & tmpname = iter->tag();
607 if (tmpname ==
"V1") {
V1 = iter->getImmutableValue<
double>();
V1given = iter->given();}
608 if (tmpname ==
"V2") {
V2 = iter->getImmutableValue<
double>();
V2given = iter->given();}
609 if (tmpname ==
"TD1") {
TD1 = iter->getImmutableValue<
double>();
TD1given = iter->given();}
610 if (tmpname ==
"TAU1") {
TAU1 = iter->getImmutableValue<
double>();
TAU1given = iter->given();}
611 if (tmpname ==
"TD2") {
TD2 = iter->getImmutableValue<
double>();
TD2given = iter->given();}
612 if (tmpname ==
"TAU2") {
TAU2 = iter->getImmutableValue<
double>();
TAU2given = iter->given();}
616 Report::UserError() <<
"V1 and V2 are required for the EXP source function";
637 #ifdef Xyce_DEBUG_DEVICE
646 void ExpData::printOutParams()
648 Xyce::dout() <<
"ExpData:\n";
650 Xyce::dout() <<
"V1 = " <<
V1 << std::endl;
651 Xyce::dout() <<
"V2 = " <<
V2 << std::endl;
653 Xyce::dout() <<
"TD1 = " <<
TD1 << std::endl;
654 Xyce::dout() <<
"TAU1 = " <<
TAU1 << std::endl;
656 Xyce::dout() <<
"TD2 = " <<
TD2 << std::endl;
657 Xyce::dout() <<
"TAU2 = " <<
TAU2 << std::endl;
705 bool bsuccess =
true;
776 if (
TD1 != params[2])
781 if (
TAU1 != params[3])
786 if (
TD2 != params[4])
791 if (
TAU2 != params[5])
820 V1given (right.V1given),
821 V2given (right.V2given),
822 TDgiven (right.TDgiven),
823 TRgiven (right.TRgiven),
824 TFgiven (right.TFgiven),
825 PWgiven (right.PWgiven),
826 PERgiven (right.PERgiven)
860 std::vector<Param>::const_iterator iter = paramRef.begin();
861 std::vector<Param>::const_iterator last = paramRef.end();
863 for ( ; iter != last; ++iter)
865 const std::string & tmpname = iter->tag();
867 if (tmpname ==
"V1") {
V1 = iter->getImmutableValue<
double>();
V1given = iter->given();}
868 if (tmpname ==
"V2") {
V2 = iter->getImmutableValue<
double>();
V2given = iter->given();}
869 if (tmpname ==
"TD") {
TD = iter->getImmutableValue<
double>();
TDgiven = iter->given();}
870 if (tmpname ==
"TR") {
TR = iter->getImmutableValue<
double>();
TRgiven = iter->given();}
871 if (tmpname ==
"TF") {
TF = iter->getImmutableValue<
double>();
TFgiven = iter->given();}
872 if (tmpname ==
"PW") {
PW = iter->getImmutableValue<
double>();
PWgiven = iter->given();}
873 if (tmpname ==
"PER") {
PER = iter->getImmutableValue<
double>();
PERgiven = iter->given();}
895 #ifdef Xyce_DEBUG_DEVICE
904 void PulseData::printOutParams()
906 Xyce::dout() << std::endl;
907 Xyce::dout() <<
" PulseData::printOutParams\n";
908 Xyce::dout() <<
" V1 = " <<
V1 << std::endl;
909 Xyce::dout() <<
" V2 = " <<
V2 << std::endl;
911 Xyce::dout() <<
" TD = " <<
TD << std::endl;
912 Xyce::dout() <<
" TR = " <<
TR << std::endl;
913 Xyce::dout() <<
" TF = " <<
TF << std::endl;
914 Xyce::dout() <<
" PW = " <<
PW << std::endl;
915 Xyce::dout() <<
" PER = " <<
PER << std::endl;
916 Xyce::dout() << std::endl;
960 bool bsuccess =
true;
966 #ifdef Xyce_DEBUG_DEVICE
969 Xyce::dout() <<
" PulseData::updateSources\n";
980 #ifdef Xyce_DEBUG_DEVICE
983 Xyce::dout() <<
" Time = " <<
time << std::endl;
1014 else if (
time > 0 &&
1038 #ifdef Xyce_DEBUG_DEVICE
1041 Xyce::dout() <<
" SourceValue = " <<
SourceValue << std::endl;
1082 if (
V1 != params[0])
1087 if (
V2 != params[1])
1092 if (
TD != params[2])
1097 if (
TR != params[3])
1102 if (
TF != params[4])
1107 if (
PW != params[5])
1112 if (
PER != params[6])
1139 (std::vector<N_UTL_BreakPoint> & breakPointTimes )
1141 bool bsuccess =
true;
1143 if (!initializeFlag_) bsuccess = initializeSource ();
1147 int currPeriodIndex = 0;
1150 double basetime = 0.0;
1153 time = getTime_() - TD;
1158 #ifdef Xyce_DEBUG_DEVICE
1159 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1161 Xyce::dout() << std::endl;
1162 Xyce::dout() <<
" In PulseData::getBreakPoints\n";
1163 Xyce::dout() <<
" time = " << time << std::endl;
1164 Xyce::dout() <<
" TD = " << TD << std::endl;
1165 Xyce::dout() <<
" PER = " << PER << std::endl;
1174 currPeriodIndex = (
static_cast<int> (floor(time/PER)));
1175 basetime = PER * (
static_cast<double> (currPeriodIndex));
1180 #ifdef Xyce_DEBUG_DEVICE
1181 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1183 Xyce::dout() <<
" time = " << time << std::endl;
1184 Xyce::dout() <<
" basetime = " << basetime << std::endl;
1185 Xyce::dout() <<
" currPeriodIndex = " << currPeriodIndex << std::endl;
1186 Xyce::dout() << std::endl;
1195 breakPointTimes.push_back(basetime+TD);
1196 breakPointTimes.push_back(basetime+TD+TR);
1197 breakPointTimes.push_back(basetime+TD+TR+PW);
1198 breakPointTimes.push_back(basetime+TD+TR+PW+TF);
1202 breakPointTimes.push_back(basetime+TD+PER);
1205 breakPointTimes.push_back(basetime+TD+PER+TR);
1206 breakPointTimes.push_back(basetime+TD+PER+TR+PW);
1207 breakPointTimes.push_back(basetime+TD+PER+TR+PW+TF);
1208 breakPointTimes.push_back(basetime+TD+PER+PER);
1233 if (
time <
TD) maxTimeStep = (0.1*
TD );
1234 else maxTimeStep = (0.1*
PER);
1236 #ifdef Xyce_DEBUG_DEVICE
1239 Xyce::dout() <<
"\nIn PulseData::getMaxTimeStepSize. ";
1240 Xyce::dout() <<
" maxTimeStep = "<< maxTimeStep;
1241 Xyce::dout() <<
" TD = " <<
TD <<
" PER = " <<
PER;
1242 Xyce::dout() <<
" time = "<<
time << std::endl;
1262 REPEAT(right.REPEAT),
1263 REPEATTIME(right.REPEATTIME),
1267 starttime_(right.starttime_)
1289 std::vector<Param>::const_iterator iter = paramRef.begin();
1290 std::vector<Param>::const_iterator last = paramRef.end();
1292 for ( ; iter != last; ++iter)
1294 const std::string & tmpname = iter->tag();
1295 const bool & tmpgiven = iter->given();
1297 if (tmpname ==
"NUM")
NUM = iter->getImmutableValue<
int>();
1298 if (tmpname ==
"R" && tmpgiven ==
true)
1301 REPEATTIME = iter->getImmutableValue<
double>();
1303 if (tmpname ==
"TD")
TD = iter->getImmutableValue<
double>();
1305 if ( tmpname ==
"T" && iter->given() )
1307 time = iter->getImmutableValue<
double>();
1310 TVVEC.push_back(std::pair<double,double>(
time, iter->getImmutableValue<
double>()));
1315 Report::UserError() <<
"At least one voltage/time pair must be specified for the PWL source function";
1316 if (REPEATTIME < 0 || REPEATTIME >=
TVVEC[
NUM-1].first)
1317 Report::UserError() <<
"PWL source's repeat value (R) must be >= 0 and < last value in Time-Voltage list";
1334 #ifdef Xyce_DEBUG_DEVICE
1343 void PWLinData::printOutParams()
1345 Xyce::dout() << std::endl;
1346 Xyce::dout() <<
" NUM = " <<
NUM << std::endl;
1347 Xyce::dout() <<
" REPEAT = " <<
REPEAT << std::endl;
1348 Xyce::dout() <<
" REPEATTIME = " <<
REPEATTIME << std::endl;
1349 Xyce::dout() <<
" TD = " <<
TD << std::endl;
1350 Xyce::dout() <<
" loc_ = " <<
loc_ << std::endl;
1351 Xyce::dout() <<
" starttime_ = " <<
starttime_ << std::endl;
1353 Xyce::dout() <<
" Time Voltage" << std::endl;
1354 for(
int i = 0; i <
NUM; ++i )
1355 Xyce::dout() <<
" " <<
TVVEC[i].first <<
" " <<
TVVEC[i].second << std::endl;
1357 Xyce::dout() << std::endl;
1374 bool bsuccess =
true;
1378 #ifdef Xyce_DEBUG_DEVICE
1381 Xyce::dout() << std::endl;
1382 Xyce::dout() <<
" PWLinData::updateSource\n";
1393 #ifdef Xyce_DEBUG_DEVICE
1396 Xyce::dout() << Xyce::section_divider << std::endl;
1397 Xyce::dout() <<
" Time = " <<
time << std::endl;
1401 double time1, time2, voltage1, voltage2;
1402 double simtime =
time;
1410 for(
int i = 0; i <
NUM; ++i )
1433 voltage1 = voltage2 =
TVVEC[NUM-1].second;
1439 time -= looptime * floor(
time / looptime);
1442 for(
int i = 0; i <
NUM; ++i )
1450 voltage1 = voltage2 =
TVVEC[NUM-1].second;
1457 voltage1 =
TVVEC[NUM-1].second;
1470 if( time1 == time2 )
1474 double length = time2 - time1;
1479 #ifdef Xyce_DEBUG_DEVICE
1482 Xyce::dout() <<
"time: " <<
time << std::endl;
1483 Xyce::dout() <<
"time1: " << time1 << std::endl;
1484 Xyce::dout() <<
"time2: " << time2 << std::endl;
1485 Xyce::dout() <<
"voltage1: " << voltage1 << std::endl;
1486 Xyce::dout() <<
"voltage2: " << voltage2 << std::endl;
1487 Xyce::dout() <<
"Src: " <<
SourceValue << std::endl;
1488 Xyce::dout() << Xyce::section_divider << std::endl;
1513 (std::vector<N_UTL_BreakPoint> & breakPointTimes )
1515 bool bsuccess =
true;
1517 #ifdef Xyce_DEBUG_DEVICE
1518 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1520 Xyce::dout() <<
" In PWLinData::getBreakPoints\n";
1524 if (!initializeFlag_) bsuccess = initializeSource ();
1526 time = solState_.currTime;
1531 if (REPEAT && time >= TVVEC[NUM - 1].first)
1533 double loopBaseTime = 0.0;
1536 double looptime = TVVEC[NUM-1].first - REPEATTIME;
1537 loopBaseTime = looptime * (1.0 + floor((time - TVVEC[NUM - 1].first) / looptime));
1538 #ifdef Xyce_DEBUG_DEVICE
1539 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1541 Xyce::dout() <<
"loopBaseTime: " << loopBaseTime << std::endl;
1542 Xyce::dout() <<
"floor function: " << floor((time - TVVEC[NUM - 1].first) / (TVVEC[NUM - 1].first - REPEATTIME)) << std::endl;
1546 for (
int i = 0; i < NUM; ++i)
1548 bp_time = TVVEC[i].first;
1549 if (bp_time >= REPEATTIME)
1551 breakPointTimes.push_back(bp_time + loopBaseTime + TD);
1552 #ifdef Xyce_DEBUG_DEVICE
1553 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1555 Xyce::dout() <<
"bp_time + loopBaseTime + TD: " << bp_time + loopBaseTime + TD << std::endl;
1563 for (
int i = 0; i < NUM; ++i)
1565 double bp_time = TVVEC[i].first;
1566 breakPointTimes.push_back(bp_time+TD);
1567 #ifdef Xyce_DEBUG_DEVICE
1568 if (devOptions_.debugLevel > 0 && solState_.debugTimeFlag)
1570 Xyce::dout() <<
"bp_time + TD: " << bp_time + TD << std::endl;
1599 V0given (right.V0given),
1600 VAgiven (right.VAgiven),
1601 FCgiven (right.FCgiven),
1602 MDIgiven (right.MDIgiven),
1603 FSgiven (right.FSgiven)
1631 std::vector<Param>::const_iterator iter = paramRef.begin();
1632 std::vector<Param>::const_iterator last = paramRef.end();
1634 for ( ; iter != last; ++iter)
1636 const std::string & tmpname = iter->tag();
1638 if (tmpname ==
"V0") {
V0 = iter->getImmutableValue<
double>();
V0given = iter->given(); }
1639 if (tmpname ==
"VA") {
VA = iter->getImmutableValue<
double>();
VAgiven = iter->given(); }
1640 if (tmpname ==
"FC") {
FC = iter->getImmutableValue<
double>();
FCgiven = iter->given(); }
1641 if (tmpname ==
"MDI") {
MDI = iter->getImmutableValue<
double>();
MDIgiven = iter->given(); }
1642 if (tmpname ==
"FS") {
FS = iter->getImmutableValue<
double>();
FSgiven = iter->given(); }
1646 Report::UserError() <<
"V0 and VA are required for the SFFM source function";
1667 #ifdef Xyce_DEBUG_DEVICE
1677 void SFFMData::printOutParams()
1679 Xyce::dout() <<
"SFFMData:\n";
1680 Xyce::dout() <<
"V0 = " <<
V0 << std::endl;
1681 Xyce::dout() <<
"VA = " <<
VA << std::endl;
1682 Xyce::dout() <<
"FC = " <<
FC << std::endl;
1683 Xyce::dout() <<
"MDI = " <<
MDI << std::endl;
1684 Xyce::dout() <<
"FS = " <<
FS << std::endl;
1728 bool bsuccess =
true;
1740 MDI * sin (2 * mpi *
FS * time));
1777 if (
V0 != params[0])
1782 if (
VA != params[1])
1787 if (
FC != params[2])
1792 if (
MDI != params[3])
1797 if (
FS != params[4])
1820 ACPHASE(right.ACPHASE),
1821 ACMAGgiven(right.ACMAGgiven),
1822 ACPHASEgiven(right.ACPHASEgiven)
1846 std::vector<Param>::const_iterator iter = paramRef.begin();
1847 std::vector<Param>::const_iterator last = paramRef.end();
1849 for ( ; iter != last; ++iter)
1851 const std::string & tmpname = iter->tag();
1853 if (tmpname ==
"ACMAG") {
ACMAG = iter->getImmutableValue<
double>();
ACMAGgiven = iter->given();}
1854 if (tmpname ==
"ACPHASE") {
ACPHASE = iter->getImmutableValue<
double>();
ACPHASEgiven = iter->given();}
1873 #ifdef Xyce_DEBUG_DEVICE
1883 void ACData::printOutParams()
1886 Xyce::dout() <<
"ACData:\n";
1887 Xyce::dout() <<
"ACMAG = " <<
ACMAG << std::endl;
1888 Xyce::dout() <<
"ACPHASE = " <<
ACPHASE << std::endl;
1904 bool bsuccess =
true;
1919 #ifdef Xyce_DEBUG_DEVICE
1922 Xyce::dout() <<
" SourceValue = " <<
SourceValue << std::endl;
1957 if (
ACMAG!= params[0])
2004 std::vector<Param>::const_iterator iter = paramRef.begin();
2005 std::vector<Param>::const_iterator last = paramRef.end();
2007 for ( ; iter != last; ++iter)
2009 const std::string & tmpname = iter->tag();
2010 if (tmpname ==
"DCV0")
2012 V0 = iter->getImmutableValue<
double>();
2034 #ifdef Xyce_DEBUG_DEVICE
2044 void ConstData::printOutParams()
2047 Xyce::dout() <<
"ConstData:\n";
2048 Xyce::dout() <<
"V0: " <<
V0 << std::endl;
2069 bool bsuccess =
true;
2106 if (
V0 != params[0])
2134 riseScaleFactor_(right.riseScaleFactor_),
2135 fallScaleFactor_(right.fallScaleFactor_),
2136 functionScaleFactor_(right.functionScaleFactor_),
2137 V1given (right.V1given),
2138 V2given (right.V2given),
2139 TDgiven (right.TDgiven),
2140 TRgiven (right.TRgiven),
2141 TFgiven (right.TFgiven),
2142 PWgiven (right.PWgiven),
2143 PERgiven (right.PERgiven),
2144 functionScaleFactorGiven_(right.functionScaleFactorGiven_)
2169 riseScaleFactor_(0.0),
2170 fallScaleFactor_(0.0),
2171 functionScaleFactor_(20.0),
2179 functionScaleFactorGiven_(false)
2183 std::vector<Param>::const_iterator iter = paramRef.begin();
2184 std::vector<Param>::const_iterator last = paramRef.end();
2186 for ( ; iter != last; ++iter)
2188 const std::string & tmpname = iter->tag();
2190 if (tmpname ==
"V1") {
V1 = iter->getImmutableValue<
double>();
V1given = iter->given();}
2191 if (tmpname ==
"V2") {
V2 = iter->getImmutableValue<
double>();
V2given = iter->given();}
2192 if (tmpname ==
"TD") {
TD = iter->getImmutableValue<
double>();
TDgiven = iter->given();}
2193 if (tmpname ==
"TR") {
TR = iter->getImmutableValue<
double>();
TRgiven = iter->given();}
2194 if (tmpname ==
"TF") {
TF = iter->getImmutableValue<
double>();
TFgiven = iter->given();}
2195 if (tmpname ==
"PW") {
PW = iter->getImmutableValue<
double>();
PWgiven = iter->given();}
2196 if (tmpname ==
"PER") {
PER = iter->getImmutableValue<
double>();
PERgiven = iter->given();}
2220 #ifdef Xyce_DEBUG_DEVICE
2230 void SmoothPulseData::printOutParams()
2233 Xyce::dout() << std::endl;
2234 Xyce::dout() <<
" SmoothPulseData::printOutParams\n";
2235 Xyce::dout() <<
" V1 = " <<
V1 << std::endl;
2236 Xyce::dout() <<
" V2 = " <<
V2 << std::endl;
2238 Xyce::dout() <<
" TD = " <<
TD << std::endl;
2239 Xyce::dout() <<
" TR = " <<
TR << std::endl;
2240 Xyce::dout() <<
" TF = " <<
TF << std::endl;
2241 Xyce::dout() <<
" PW = " <<
PW << std::endl;
2242 Xyce::dout() <<
" PER = " <<
PER << std::endl;
2244 Xyce::dout() << std::endl;
2292 bool bsuccess =
true;
2296 double basetime = 0;
2298 #ifdef Xyce_DEBUG_DEVICE
2301 Xyce::dout() <<
" SmoothPulseData::updateSources\n";
2308 #ifdef Xyce_DEBUG_DEVICE
2311 Xyce::dout() <<
" Time = " <<
time << std::endl;
2342 else if (
time > 0 &&
2360 #ifdef Xyce_DEBUG_DEVICE
2363 Xyce::dout() <<
" SourceValue = " <<
SourceValue << std::endl;
2404 if (
V1 != params[0])
2409 if (
V2 != params[1])
2414 if (
TD != params[2])
2419 if (
TR != params[3])
2424 if (
TF != params[4])
2429 if (
PW != params[5])
2434 if (
PER != params[6])
2459 (std::vector<N_UTL_BreakPoint> & breakPointTimes )
2461 bool bsuccess =
true;
2463 if (!initializeFlag_) bsuccess = initializeSource ();
2483 if (
time <
TD) maxTimeStep = (0.1*
TD );
2484 else maxTimeStep = (0.1*
PER);
2486 #ifdef Xyce_DEBUG_DEVICE
2489 Xyce::dout() <<
"\nIn SmoothPulseData::getMaxTimeStepSize. ";
2490 Xyce::dout() <<
" maxTimeStep = "<< maxTimeStep;
2491 Xyce::dout() <<
" TD = " <<
TD <<
" PER = " <<
PER;
2492 Xyce::dout() <<
" time = "<<
time << std::endl;