On Wed, 2012-07-25 at 14:18 +0200, Frederic Parrenin wrote:
> 
> Is there a way to create a nxm matrix with only '1' numbers inside?
> (a bit like the munit(n) function)
> 

Hal's suggestion assumes that you want to store the matrix directly on
the sheet and the size is determined by the size of the selection.

If you want to create an 3 by 3 matrix of 1s for use in a formula
without storing it first on a sheet you can use
((munit(3)+1)-munit(3))

Non-square matrices are more difficult. I can get a 3 by 2 matrix via
(array(1,1,1)*transpose(array(1,1)))

If I want to create a large matrix, say 100 by 50 without listing a
block of 100 1s and another of 50 1s I would use:

=array(row(A1:A100)/row(A1:A100))*transpose(array(row(A1:A50)/row(A1:A50)))

I hope that helps

Andreas


-- 
Andreas J. Guelzow, PhD, FTICA
Concordia University College of Alberta

-- 
Andreas Guelzow <[email protected]>

_______________________________________________
gnumeric-list mailing list
[email protected]
https://mail.gnome.org/mailman/listinfo/gnumeric-list

Reply via email to