Skip to content

Commit 4f9dcd1

Browse files
committed
WIP: Deal with imag prom
1 parent 1de618d commit 4f9dcd1

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

palace/drivers/drivensolver.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,6 @@ ErrorIndicator DrivenSolver::SweepAdaptive(SpaceOperator &space_op, int n_step,
240240
space_op.GetWavePortOp().SetSuppressOutput(
241241
true); // Suppress wave port output for offline
242242

243-
244243
// Add ports to PROM if we do synthesis.
245244
if (iodata.solver.driven.adaptive_circuit_synthesis)
246245
{
@@ -493,22 +492,22 @@ void DrivenSolver::PrintPROMMatrices(const RomOperator &prom_op) const
493492
using VT = Units::ValueType;
494493

495494
// PROM matrices should be real.
496-
// TODO: Implications of periodic boundary conditions.
495+
// TODO: Implications of periodic boundary conditions. Just print re & im separate.
497496
auto unit_H = iodata.units.GetScaleFactor<VT::INDUCTANCE>();
498497
Eigen::MatrixXd m_Linv = (1.0 / unit_H * v_d) * Kr.real() * v_d;
499-
print_table(m_Linv, "prom-Linv.csv");
498+
print_table(m_Linv, "prom-Linv-re.csv");
500499

501500
auto unit_F = iodata.units.GetScaleFactor<VT::CAPACITANCE>();
502501
Eigen::MatrixXd m_C = (unit_F * v_d) * Mr.real() * v_d;
503-
print_table(m_C, "prom-C.csv");
502+
print_table(m_C, "prom-C-re.csv");
504503

505504
// Cr need not exist, if no dissipation. Currently, Cr always exists since we need
506505
// dissipative ports for a driven response, but this may change in the future.
507506
if (Cr.size() > 0)
508507
{
509508
auto unit_ohm = iodata.units.GetScaleFactor<VT::IMPEDANCE>();
510509
Eigen::MatrixXd m_Rinv = (1.0 / unit_ohm * v_d) * Cr.real() * v_d;
511-
print_table(m_Rinv, "prom-Rinv.csv");
510+
print_table(m_Rinv, "prom-Rinv-re.csv");
512511
}
513512
}
514513
} // namespace palace

0 commit comments

Comments
 (0)