Skip to content

Commit

Permalink
rebased to resolve conflict.
Browse files Browse the repository at this point in the history
  • Loading branch information
dreamer2368 committed Feb 21, 2024
1 parent 7e96db6 commit 3d957bc
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 17 deletions.
2 changes: 1 addition & 1 deletion examples/prom/de_parametric_maxwell_greedy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ double simulation()
// 19. take and write snapshot for ROM
if (offline)
{
bool addSample = generator->takeSample(X.GetData(), 0.0, 0.01);
bool addSample = generator->takeSample(X.GetData());
generator->writeSnapshot();
basisIdentifiers.push_back(saveBasisName);
delete generator;
Expand Down
2 changes: 1 addition & 1 deletion examples/prom/grad_div_global_rom.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ int main(int argc, char *argv[])
// 18. take and write snapshot for ROM
if (offline)
{
generator->takeSample(X.GetData(), 0.0, 0.01);
generator->takeSample(X.GetData());
generator->writeSnapshot();
delete generator;
delete options;
Expand Down
2 changes: 1 addition & 1 deletion examples/prom/maxwell_local_rom_greedy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ int main(int argc, char *argv[])
// 19. take and write snapshot for ROM
if (offline)
{
bool addSample = generator->takeSample(X.GetData(), 0.0, 0.01);
bool addSample = generator->takeSample(X.GetData());
generator->writeSnapshot();
basisIdentifiers.push_back(saveBasisName);
delete generator;
Expand Down
14 changes: 0 additions & 14 deletions unit_tests/test_SVD.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -212,20 +212,6 @@ TEST(SVDSerialTest, Test_getBasisIntervalStartTime)
EXPECT_DOUBLE_EQ(svd.getBasisIntervalStartTime(2), 2);
}


TEST(SVDSerialTest, Test_increaseTimeInterval)
{
FakeSVD svd(CAROM::Options(5, 2, 2));

ASSERT_NO_THROW(svd.takeSample(NULL, 0, true));
ASSERT_NO_THROW(svd.takeSample(NULL, 0.5, true));
ASSERT_NO_THROW(svd.takeSample(NULL, 1, true));
ASSERT_NO_THROW(svd.takeSample(NULL, 1.5, true));

/* The maximum number of time intervals is surpassed */
EXPECT_DEATH(svd.takeSample(NULL, 2, true), ".*");
}

int main(int argc, char* argv[])
{
::testing::InitGoogleTest(&argc, argv);
Expand Down

0 comments on commit 3d957bc

Please sign in to comment.