domanda 1:

Ad esempio:

codice:
Matrix = function(n, m)
{
	this.items = new Array(n);
	for(var i = 0; i < n; i++){
		this.items[i] = new Array(m);
	}
};

matrice = new Matrix(4, 3);
domanda 2:

E se la immaginassi così:

codice:
matrice=

[1 - 2 - 3]
[2 - 5 - 8]
[3 - 8 - 1]