## WeBWorK Problems

### Re: Matrix custom answer checker not returning Value->Error messages

by Alex Jordan -
Number of replies: 0
I got it, and thanks again. Once I could explore the elements of the custom answer checker by printing error messages, I tracked it down to our use of digits tolType (https://github.com/openwebwork/pg/pull/441). We've been using it as the default for Numeric since early 2020, so I'm unsure why it was only now that problems stopped working. But it could be that only some random seeds trigger to the issue.

As a consequence of using it as the default for Numeric, it was inherited by Matrix. And at some level when matrices are multiplied and then compared with other matrices, this tolType leads to declaring some things not equal when they should be declared equal.

In my situation, a matrix Formula was evaluated at random values for the variables, leading to a comparison of something with all zero entries with something else that *should* have had zero entries, but the decimal arithmetic and numerical matrix multiplication was making something with entries that were slightly off. Off by enough to get a comparison like "0 == 0.000000001" which returned false.

This reveals that this tolType needs to be amended to handle comparisons within the \$zeroLevel better.