Math in the Grid - Column Total in the Grid

I would like the column total to show in a cell of that column. After reading the documentation I have tried including the dhtmlxgrid_math.js file and designating the column type as math. Then using =c4 in the XML. This always results in zero.

How should I go about displaying a column total in the grid?

You should declare all summands of a sum in the needed cell.
For example: =[[1,4]]+[[2,4]]+[[3,4]]+[[4,4]]+[[5,4]] - in this cell will be a sum of values of first 5 rows in a fifth column (column indexes are zero-based).

Also check this sample:
http://www.dhtmlx.com/docs/products/dhtmlxGrid/samples/16_rows_columns_manipulations/17_pro_math.html

Thank you sematik, that works great!