WeBWorK Problems

ijk vector formula checking

Re: ijk vector formula checking

by Davide Cervone -
Number of replies: 0

Sorry I've been off-line for so long (my work on MathJax has kept me away from WeBWorK for a while).

The real issue here is that the Operands for '+' must be of the same type that you get is a bug, and represents an error in the differentiation code. It turns out that this is due to an error in handling named constants (like i, j, and k); they were replaced by a scalar 0 rather than a zero vector, and so the differentiation formula ended up adding a vector and a scaler.

I have prepared a fix which is available in the differentiation branch of my fork of pg-dev. It modifies two files, which you can simply download and replace the current versions.

I also added differentiation rules for dot products and cross products, so not only should be able to use your original checker with these changes, but you could also use the $sVec . i approach to obtain the coordinate functions for the student's answer and differentiate them (though this is effectively the same as $sVec->D('t') . i).

I will write more about why $sVec->value doesn't do what you want later.