-
Notifications
You must be signed in to change notification settings - Fork 36
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
Assigning a symbolic expression to an element of a numerical matrix fails #191
Comments
Simpler example:
This works using octsympy on Matlab, so I think this is an Octave bug. Octave should try This is similar to |
AFAIK, nothing I can do about this, but I will comment on the upstream bug. |
The But I think the double thing is still a bug. Leaving open, will chase upstream. |
Filed new upstream bug: https://savannah.gnu.org/bugs/index.php?49267 |
Hi, |
Once again this is a piece of code that I wrote in MATLAB and failed to execute in Octave with the most recent octsympy. Assume the following code
If one assigns
y will become a symbolic variable, too. But the situation is different for numerical matrices. If you assign x to an arbitrary element of a numerical matrix, MATLAB automatically tries to convert the symbolic expression to a numerical value with the double function and throws an error if it fails ("Error in MuPAD command: DOUBLE cannot convert the input expression into a double array. If the input expression contains a symbolic variable, use the VPA function instead."). For instance
in MATLAB the next-to-last line works and y is still of type double, in Octave both assignments to y fail with
The text was updated successfully, but these errors were encountered: