void SCVdepSource::GetAuxEquations ( JPtrArray<JString>* lhsList, JPtrArray<JString>* rhsList, JPtrArray<JString>* varList ) const { SCDepSource::GetAuxEquations(lhsList, rhsList, varList); SCCircuit* theCircuit = GetCircuit(); JString* lhs = new JString(GetValueSymbol()); assert( lhs != NULL ); lhsList->Append(lhs); JString* rhs = new JString("("); assert( rhs != NULL ); *rhs += GetCoeffSymbol(); *rhs += ") * ("; *rhs += theCircuit->GetNodeName(itsPosDepNode); *rhs += " - "; *rhs += theCircuit->GetNodeName(itsNegDepNode); *rhs += ")"; rhsList->Append(rhs); }
void SCVdepVSource::GetAuxEquations ( JPtrArray<JString>* lhsList, JPtrArray<JString>* rhsList, JPtrArray<JString>* varList ) const { SCVdepSource::GetAuxEquations(lhsList, rhsList, varList); SCCircuit* theCircuit = GetCircuit(); JString* lhs = new JString; assert( lhs != NULL ); *lhs = theCircuit->GetNodeName(GetPositiveNode()); *lhs += " - "; *lhs += theCircuit->GetNodeName(GetNegativeNode()); lhsList->Append(lhs); JString* rhs = new JString(GetValueSymbol()); assert( rhs != NULL ); rhsList->Append(rhs); JString* var = new JString(GetValueSymbol()); assert( var != NULL ); varList->Append(var); }
void SCLinearComp::PrintToNetlist ( ostream& output ) const { SCCircuit* theCircuit = GetCircuit(); SCComponent::PrintToNetlist(output); output << '\t' << theCircuit->GetNodeIndexForNetlist(itsPosNode); output << '\t' << theCircuit->GetNodeIndexForNetlist(itsNegNode); }
void SCVdepSource::PrintToNetlist ( std::ostream& output ) const { SCCircuit* theCircuit = GetCircuit(); SCDepSource::PrintToNetlist(output); output << '\t' << theCircuit->GetNodeIndexForNetlist(itsPosDepNode); output << '\t' << theCircuit->GetNodeIndexForNetlist(itsNegDepNode); output << '\t' << GetCoeffValue(); }