I did not give the patch a full test, but the logic in the patch looks very reasonable to me.
About performance (50% slower?), do you think it is acceptable? Most time spent on Kernel should be in "linearSearch". And since Kernel doesn't have order, I wonder if it is possible to using some kind of hashtable to store all cached kernels. - Qian On 8/24/21 8:48 PM, Waldek Hebisch wrote:
It was already discussed that there is no consisent and reasonably computable order on kernels. Example by Kurt Pagani from February 2 2017 shows that this may lead to user-visible troubles. Recently Qian reported that this leads to bugs during integration. Core of the problem is that due to failure of order our kernel machinery may consider two kernels as unequal, even though they should be equal. Attached patch modifies KERNEL so that it does not depend on order for kernel equality. It still uses order to find positions in kernel cache. With the patch all test pass but testsuite takes almost two times longer than current version. More visible slowdown is on formal derivatives: f := operator 'f D(f(x), x, 655) currently takes 8.22 sec on my machine. After kernel patch it was much longer (I did not wait long enough to know how much longer). The patch fixes problem reported by Kurt and hopefully should fix some integration problems (of course there are several problem with integration and most are not coused by wrong handling of kernels). ATM I am testing this patch, I particular I am looking for possible troubles. This patch passed testsuite, but earlier version failed, at least one of failures in earlier version looks like unwarrented assumption in algebra, so it is possible that this version also causes trouble in some obscure cases. Of course, I would like to avoid slowdown, but ATM is is not clear how much can be done in kernel code. Probably most of work on avoiding slowdown should be outside kernel...
-- You received this message because you are subscribed to the Google Groups "FriCAS - computer algebra system" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/fricas-devel/da7d1ac9-dc95-e20f-7b96-8ea006368c9c%40gmail.com.
