close Warning: Can't synchronize with repository "(default)" (/var/svn/tolp does not appear to be a Subversion repository.). Look in the Trac log for more information.

Opened 18 years ago

Closed 18 years ago

Last modified 18 years ago

#445 closed defect (fixed)

Errors in addition in matrix

Reported by: César Pérez Álvarez Owned by: Víctor de Buen Remiro
Priority: high Milestone:
Component: Math Version: 1.1.4
Severity: critical Keywords:
Cc:

Description

If we run this code

Matrix a = Rand(1,1,1,1);
Matrix b = Rand(1,2,2,1);
Matrix c = a+b;

We obtain a massage like this:

Imposible sumar dos matrices de dimensiones (1,1) y (1,2).

However the matrix c is a (1,1) matrix with MatDat(c, 1, 1) = 1.

I think that matrix must not be created.

Change History (6)

comment:1 Changed 18 years ago by Víctor de Buen Remiro

Owner: changed from danirus to Víctor de Buen Remiro

We are working about thid bug
Thanks to report it

comment:2 Changed 18 years ago by Víctor de Buen Remiro

You want that an algebraic fail cause a syntax effect and that is quite debatable.

Afterwords, the change that you propose supposes to lose compatibility backwards and it is not easy to know the consequences that could have. It is necessary to put under it the analysis of the developers of tol-project.

I propose to return the unknown matrix.

comment:3 Changed 18 years ago by César Pérez Álvarez

Return the unknown matrix it's ok for me. And put a warning it will be better too.

comment:4 Changed 18 years ago by danirus

I'm agree with the final decision.
It's a syntactically well formed Tol sentence, and must be accepted without errors. The result must be arranged by Matrix Algebra.

Daniel

comment:5 Changed 18 years ago by Víctor de Buen Remiro

Resolution: fixed
Status: newclosed

Problem has been fixed in CVS

When a forbidden matrix operation is detected the Unknown Matrix 0x0 will be returned

A new test has been added to tol_tests/tol/Bugzilla/bug_000445

Thanks to report it

comment:6 Changed 18 years ago by Víctor de Buen Remiro

bug_file_loc: http://cvs.tol-project.org/viewcvs.cgi/tol_tests/tol/Bugzilla/bug_000445
Note: See TracTickets for help on using tickets.