It does not work on my linux.
I typed: var e=eye0(4)+2;e.Nrows = 5;e
This is then shown:
java.lang.ArrayIndexOutOfBoundsException: 4
at scalaSci.Mat.apply(Mat.scala:54)
at scalaSci.scalaSciMatrix$class.toDoubleArray(scalaSciMatrix.scala:2204)
at scalaSci.Mat.toDoubleArray(Mat.scala:13)
[snip, see all in attached file, including starting messages of Scalalab]
I need to run scala code in Matlab, because I use EJML.Mat to accelerate matlab code.
I insert here some translations so that others are not totaly bored reading this thread:
// change function to def
// replace : by ::, except for matrix insertions for which insertIntoThis (should have been called updateIntoThis) is better. (chercher (.*,.*) puis ':' pour ratraper mes vieux outils.
// mat(:) should be translated to mat.T.toVec.T
// [mat,mat] should be translated to mat>>>mat
// [mat;mat] should be translated to mat>>mat
// mat' should be translated to mat.T
// ones/zeros/eye/diag should be translated to ones0/...
// temporary+mat should be translated to temporary++mat
// temporary-mat should be translated to temporary--mat
// use .CP/.RP and .CA/.RA for row/column prepend and append,
// .^2 should be translated to pow 2
// sum/min/max/mean/prod( ,1)/... should be translated to .sumR/minR/maxR/meanR/prodR ; sum( ,2) should be translated to .sum
// reshape(mat,a,b) should be translated to mat.T.reshape(b,a).T
// rank, trace, det should be translated to .rank, ...
// max(0,mat) should be translated to mat.filter(_>0)
// min(0,mat) should be translated to mat.filter(_<0)
permission granted to insert these in any rosetta site web.
To Stergios:
Is there anything producing standalone executables in .exe from scalalab ?