38 #include <Xyce_config.h>
50 #include <N_LOA_Loader.h>
51 #include <N_MPDE_Manager.h>
52 #include <N_IO_CmdParse.h>
67 #ifdef Xyce_DEBUG_ANALYSIS
70 Xyce::dout() << std::endl << section_divider << std::endl;
71 Xyce::dout() <<
"DCSweep::setDCAnalysisParams" << std::endl;
75 std::list<N_UTL_Param>::const_iterator it_tp;
76 std::list<N_UTL_Param>::const_iterator it_param;
77 std::list<N_UTL_Param>::const_iterator it_type;
78 std::list<N_UTL_Param>::const_iterator first = paramsBlock.getParams().begin();
79 std::list<N_UTL_Param>::const_iterator last = paramsBlock.getParams().end();
84 #ifdef Xyce_DEBUG_ANALYSIS
87 for (it_tp = first; it_tp != last; ++it_tp)
89 Xyce::dout() << it_tp->uTag() ;
91 if (it_tp->uTag() ==
"PARAM" || it_tp->uTag() ==
"TYPE")
93 Xyce::dout() << it_tp->stringValue();
97 Xyce::dout() << it_tp->getImmutableValue<
double>();
99 Xyce::dout() << std::endl;
104 for (it_tp = first; it_tp != last; ++it_tp)
106 if (it_tp->uTag() ==
"TYPE")
109 sp.
type = it_tp->stringValue();
112 if (it_tp->uTag() ==
"PARAM")
115 sp.
name = it_tp->stringValue();
121 if (sp.
type ==
"LIN")
123 sp.
startVal = it_tp->getImmutableValue<
double>(); ++it_tp;
124 sp.
stopVal = it_tp->getImmutableValue<
double>(); ++it_tp;
125 sp.
stepVal = it_tp->getImmutableValue<
double>(); ++it_tp;
127 else if (sp.
type ==
"DEC" || sp.
type ==
"OCT")
129 sp.
startVal = it_tp->getImmutableValue<
double>(); ++it_tp;
130 sp.
stopVal = it_tp->getImmutableValue<
double>(); ++it_tp;
131 sp.
numSteps = it_tp->getImmutableValue<
int>(); ++it_tp;
133 else if (sp.
type ==
"LIST")
135 for (;it_tp!=last;++it_tp)
137 sp.
valList.push_back(it_tp->getImmutableValue<
double>());
142 msg =
"DCSweep::setDCParams: ";
143 msg +=
" unsupported DC type\n";
144 N_ERH_ErrorMgr::report(N_ERH_ErrorMgr::DEV_FATAL_0, msg);
148 (*dcParamVec_).push_back(sp);
175 os <<
"\tFailed DC sweep steps:\t\t" << std::endl;
179 os <<
"\t\tDC Step # " << *iter << std::endl;
198 bool bsuccess =
true;
215 bool bsuccess =
true;
228 #ifdef Xyce_DEBUG_ANALYSIS
231 Xyce::dout() << std::endl << std::endl
232 << Xyce::subsection_divider << std::endl
233 <<
"DCSweep::run()" << std::endl;
298 bool bsuccess =
true;
303 while (currentStep < finalStep)
307 #ifdef Xyce_VERBOSE_TIME
353 bool bsuccess =
true;
378 #ifdef Xyce_DEBUG_ANALYSIS
379 #ifdef Xyce_DEBUG_TIME
409 secRCPtr_->numberSuccessiveFailures += 1;
424 bool bsuccess =
true;
426 #ifdef Xyce_DEBUG_ANALYSIS
427 Xyce::dout() <<
"Calling DCSweep::finish() outputs!" << std::endl;
541 std::vector<double> timePoints, freqPoints;
542 Teuchos::RefCountPtr<N_LAS_BlockVector> timeDomainSolnVec;
543 Teuchos::RefCountPtr<N_LAS_BlockVector> freqDomainSolnVecReal;
544 Teuchos::RefCountPtr<N_LAS_BlockVector> freqDomainSolnVecImaginary;
545 Teuchos::RefCountPtr<N_LAS_BlockVector> timeDomainStoreVec;
546 Teuchos::RefCountPtr<N_LAS_BlockVector> freqDomainStoreVecReal;
547 Teuchos::RefCountPtr<N_LAS_BlockVector> freqDomainStoreVecImaginary;
550 Teuchos::RCP<const AnalysisBase> analysisObject
553 Teuchos::rcp_dynamic_cast<
const HB>( analysisObject )->prepareHBOutput(
558 freqDomainSolnVecReal,
559 freqDomainSolnVecImaginary,
561 freqDomainStoreVecReal,
562 freqDomainStoreVecImaginary
569 *freqDomainSolnVecReal,
570 *freqDomainSolnVecImaginary,
572 *freqDomainStoreVecReal,
573 *freqDomainStoreVecImaginary
590 #ifdef Xyce_VERBOSE_TIME
591 lout() << std::endl << std::endl
592 <<
"***** "<< (DEBUG_ANALYSIS ?
commandLine_.getArgumentValue(
"netlist") :
"") <<
" Start of DCOP STEP # " <<
stepNumber+1
593 << std::endl << std::endl;
607 if (start == 0 && finish == 0)