Tuesday, June 26, 2007

About nebula

Nebula is a sub-project of eclipse that produces custom SWT widgets.
I'm very interested in the grid, because it is supposed to have spreadsheet features like cells selection and row headers, which are very important in Matrex and I can just emulate in the SWT.Table widget.
Nebula Grid is still in alpha state but it should become final when Eclipse 3.3 is released.
I will check it (expecially with a big number of rows/columns) and possibly integrate it in Matrex in version 1.2 or 1.3.

Wednesday, June 20, 2007

Jython debugger?

You can write Matrex functions as Jython or JRuby scripts.

Jython is included in the Matrex setup, so you can just use it.

To debug these scripts you can use the log functionalities of Matrex.

But today I've found out that there is a better possibility. With PyDev your can remotely debug the script from Eclipse.

So, if a script is not working as it should you can put breakpoints, watch its variables until you don't find the problem.

I will test it myself and write the test results in an article in this blog.

Work started for version 1.2

Work started for version 1.2.

Version 1.2 will indicatively contain:

  • Export matrix view and presentation view to Excel file.
  • Import matrices from database tables (like the import from Excel files).
  • Import matrices from CSV files (like the import from Excel files).
  • Remove multiple items (matrices, functions...) from a project in one shot.
  • Print matrix view and presentation view.
  • The matrix source viewer.
  • More database functions templates (conditional query, update)
  • Use more JFreeChart features: composite charts, annotations, pie charts with exploded section, step charts.
With version 1.2 a first pre-alpha version of the Matrex server will be delivered.

1.2 will probably be released in september/october. If some of the new features are not ready for that time, they will be moved to version 1.3.

If you want to see in version 1.2 some feature that I did not consider, just add a comment to this article or send me a mail.

Powered by ScribeFire.

Saturday, June 09, 2007

The matrix source viewer

From a mathematical expression the expression parser generates matrices and functions in a Matrex project. This is a powerful functionality in Matrex.

Once the expression parser has generated matrices and functions, the original expression gets lost. This is usally not a problem, since in the project there are all the matrices and functions (final and intermediate) that calculate the expression.

But sometimes you want to see again the original expression, to:

  • see in one shot how a matrix has been calculated
  • know exactly which matrices and functions have been generated by the expression, for example because you want to replace the original expression with a new one and therefore you need to remove them

Fortunately the info window shows, among the rest:

  • for a matrix, the function that has it as result
  • for a function, the input matrices
So it is possible, from the expression's result matrix, to find out the original expression navigating to the source function, to the input matrices and so on.

But it is a lot of work to follow all the links among functions and matrices, expecially if the original expression is long.

To have a more valuable information, version 1.2 will contain a new functionality, called matrix source viewer.

The idea is to have a window that shows this information as a textual expression, with the same format used to enter an expression in the expression parser.

Suppose you entered the expression:

log(x + exp(y + z))

in the expression parser, and gave the name logres to the result matrix.

If you open the matrix source viewer on the logres matrix, you'll see a window containing a text like:

log ( logres.log )

Clicking on logres.log this part of the expression will be expanded and you'll have:

log (x + logres.exp )

Clicking on logres.exp this part of the expression will be expanded and you'll have:

log ( x + exp( y + z))

In this way with a limited number of clicks you'll have the original expression.

Also, a context menu on each item in the expression (excluded the parentheses) will open viewer or editor for that item.

Now the question is: why to see the original expression I need to click on links? Could it not appear as it was immediately?

The problem is that x, y and z could also be the result of other expressions and Matrex does not know which matrices are part of an expression and which are part of another.