Closed susilehtola closed 1 year ago
@wavefunction91 I've rebased to master, and implemented tests for Chebyshev1 and Chebyshev2 which pass.
If it would please you, please set your workstation to generating the Legendre and Lobatto rules. Maybe you can also think about ways to parallellize the generation? Generating the tests takes quite a long time... Fortunately it only needs to be done once, though.
Running now, re parallelization, should be easy enough, but I'm not great at python. Would definitely accept a PR on it. It should be done overnight though, not a huge priority.
NVM, figured out how to parallelize it. Will check this in and PR the new tests / parallel generator
After having a workstation work on this, in parallel, for over a few days. I think the requested test granularity is too fine. At n
over ~500, things start taking 5-10 hours to run
Generating test for GaussLegendre with 812 points ... (51311.454052632)
I fail to see the utility of testing to this granularity, I can see maybe testing every 100 - 200 after n = 500
. but even then, we should have a demonstrable need for why we should expect the code to break down to add it as a unit test.
Oh wow. Well, one can toy with the two parameters to get a good compromise between granularity and the total number of test cases.
I was mainly interested to see how far the rules stay accurate, since my benchmarks with https://github.com/JFurness1/AtomicOrbitals/ using SciPy's roots_legendre
show pretty poor results already with a hundred or so points.
@susilehtola Gauss-Lobatto is running now
@susilehtola is this g2g?
@susilehtola is this g2g?
I think so
Instead of checking all tests from 2 to 100 points, I decided to extend the range of checking the orders, while still keeping the time to generate the reference data at a reasonable amount and the number of test cases below the roof.
The key here is to include both odd and even numbered rules, since they tend to behave differently. This is easily achieved by using an odd increment: 1, 3, 5, 7, 9, ...
The Chebyshev tests are failing since #42 is not yet solved.