Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A hybrid algorithm for InnerProduct and Norm of Poisson series #2770

Merged
merged 10 commits into from
Oct 25, 2020

Conversation

pleroy
Copy link
Member

@pleroy pleroy commented Oct 24, 2020

Comparison between the various methods, 5+3 periods, 10 frequencies. The hybrid algorithm has about the same accuracy as Clenshaw-Curtis and about the same speed as formal integration.

Hybrid algorithm:

I1024 18:22:01.925325 16632 analytical_series_test.cpp:174] ---------- Io
I1024 18:22:11.196252 16632 analytical_series_test.cpp:88] step=11
I1024 18:22:11.205253 16632 analytical_series_test.cpp:126] max_residual=+1.33499009696820690e+03 m
I1024 18:22:11.206254 16632 analytical_series_test.cpp:174] ---------- Moon
I1024 18:22:14.385571 16632 analytical_series_test.cpp:88] step=10
I1024 18:22:14.393573 16632 analytical_series_test.cpp:100] max_residual=+1.23781079255599155e-01 m
I1024 18:22:14.394572 16632 analytical_series_test.cpp:174] ---------- Phobos
I1024 18:22:23.911525 16632 analytical_series_test.cpp:88] step=11
I1024 18:22:23.921525 16632 analytical_series_test.cpp:126] max_residual=+5.15349912304207081e+01 m

Integrate

I1024 18:37:24.786705  1544 analytical_series_test.cpp:174] ---------- Io
I1024 18:37:34.269654  1544 analytical_series_test.cpp:88] step=11
I1024 18:37:34.278654  1544 analytical_series_test.cpp:126] max_residual=+1.33499005397217024e+03 m
I1024 18:37:34.280654  1544 analytical_series_test.cpp:174] ---------- Moon
I1024 18:37:38.397066  1544 analytical_series_test.cpp:88] step=9
I1024 18:37:38.404067  1544 analytical_series_test.cpp:100] max_residual=+1.01789552467699218e+03 m --> NaN
I1024 18:37:40.153241  1544 analytical_series_test.cpp:174] ---------- Phobos
I1024 18:37:49.503176  1544 analytical_series_test.cpp:88] step=11
I1024 18:37:49.513177  1544 analytical_series_test.cpp:126] max_residual=+5.24372119753315360e+01 m

AutomaticClenshawCurtis

I1024 18:41:07.357960 11388 analytical_series_test.cpp:174] ---------- Io
I1024 18:41:19.392163 11388 analytical_series_test.cpp:88] step=11
I1024 18:41:19.401165 11388 analytical_series_test.cpp:126] max_residual=+1.33499006499700317e+03 m
I1024 18:41:19.403164 11388 analytical_series_test.cpp:174] ---------- Moon
I1024 18:41:22.505329 11388 analytical_series_test.cpp:88] step=10
I1024 18:41:22.513198 11388 analytical_series_test.cpp:100] max_residual=+1.23781079255599155e-01 m
I1024 18:41:22.515166 11388 analytical_series_test.cpp:174] ---------- Phobos
I1024 18:42:10.387265 11388 analytical_series_test.cpp:88] step=11
I1024 18:42:10.397266 11388 analytical_series_test.cpp:126] max_residual=+5.15351699608013476e+01 m

Should help with #2400.

@eggrobin eggrobin added the LGTM label Oct 25, 2020
@pleroy pleroy merged commit 6c66f2f into mockingbirdnest:master Oct 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants