Skip to content
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

Symmetric matrix are not recognized using fromMatrixMarket #295

Open
LsKoder opened this issue Aug 13, 2018 · 2 comments
Open

Symmetric matrix are not recognized using fromMatrixMarket #295

LsKoder opened this issue Aug 13, 2018 · 2 comments

Comments

@LsKoder
Copy link

LsKoder commented Aug 13, 2018

There is any reason for this part of code?

String symmetry = header.nextToken();
if (!symmetry.equals("general")) {
    throw new IllegalArgumentException("Unknown symmetry type: " + symmetry + ".");
}

It generates this error, loading the following matrix:
https://sparse.tamu.edu/Janna/Flan_1565

Exception in thread "main" java.lang.IllegalArgumentException: Unknown symmetry type: symmetric.
	at org.la4j.Matrix.fromMatrixMarket(Matrix.java:232)
	at org.la4j.matrix.SparseMatrix.fromMatrixMarket(SparseMatrix.java:134)
	at Main.main(Main.java:22)
@vkostyukov
Copy link
Owner

Thanks for the ticket @LsKoder! Is symmetric a part of the MatrixMarket format spec? Also, maybe you want to work on a fix?

@LsKoder
Copy link
Author

LsKoder commented Oct 7, 2018

Thanks for the ticket @LsKoder! Is symmetric a part of the MatrixMarket format spec? Also, maybe you want to work on a fix?

About symmetric type, I catched that exception from these files:
https://sparse.tamu.edu/Janna/Flan_1565
https://sparse.tamu.edu/MaxPlanck/shallow_water1

Btw, the MM documentation describes the format as following:
"As an example of the type field, RSA denotes that the matrix is real, symmetric, and assembled"
Link: https://math.nist.gov/MatrixMarket/formats.html
But continuing to read the document, it describes the third line as "3 chars".
So, I think that the "Symmetric" string could be an error into "sparse.tamu.edu" files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants