From 92bd33824bde6b6b21bfc7e30953092a74d3cce5 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Thu, 7 May 2020 22:13:33 +0200 Subject: Another overhaul of analytical solutions Still in preparation for analytical solutions of coupled models --- tests/testthat/test_SFORB.R | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'tests/testthat/test_SFORB.R') diff --git a/tests/testthat/test_SFORB.R b/tests/testthat/test_SFORB.R index ad9881a8..4fb736ec 100644 --- a/tests/testthat/test_SFORB.R +++ b/tests/testthat/test_SFORB.R @@ -14,17 +14,21 @@ test_that("Fitting the SFORB model is equivalent to fitting DFOP", { M1 = mkinsub("SFO"), use_of_ff = "max", quiet = TRUE) SFORB_SFO <- mkinmod(parent = mkinsub("SFORB", "M1"), + M1 = mkinsub("SFO"), + use_of_ff = "min", quiet = TRUE) + SFORB_SFO_ff <- mkinmod(parent = mkinsub("SFORB", "M1"), M1 = mkinsub("SFO"), use_of_ff = "max", quiet = TRUE) - SFORB_SFO$coefmat - f_dfop_sfo <- mkinfit(DFOP_SFO, DFOP_par_c, quiet = TRUE) f_sforb_sfo <- mkinfit(SFORB_SFO, DFOP_par_c, quiet = TRUE) + f_sforb_sfo_ff <- mkinfit(SFORB_SFO_ff, DFOP_par_c, quiet = TRUE) f_sforb_sfo_eigen <- mkinfit(SFORB_SFO, DFOP_par_c, solution_type = "eigen", quiet = TRUE) expect_equivalent(endpoints(f_sforb_sfo)$distimes, endpoints(f_dfop_sfo)$distimes, tolerance = 1e-6) + expect_equivalent(endpoints(f_sforb_sfo_ff)$distimes, endpoints(f_dfop_sfo)$distimes, + tolerance = 1e-6) expect_equivalent(endpoints(f_sforb_sfo_eigen)$distimes, endpoints(f_dfop_sfo)$distimes, tolerance = 1e-6) }) -- cgit v1.2.3