-
Login or Register
- Log in with
mata: real matrix function oar(real scalar rows) return(J(rows, 1, 1), (2::rows+1)) // or real matrix function dar(real scalar rows) return(diagonal(I(rows)), (2::rows+1)) oar(3) dar(3) end exit
mata r1=J(3,1,1) r2=J(1,1,J(3,1,1)) r1 r2 end
: r1=J(3,1,1) : r2=J(1,1,J(3,1,1)) : : r1 1 +-----+ 1 | 1 | 2 | 1 | 3 | 1 | +-----+ : r2 1 +-----+ 1 | 1 | 2 | 1 | 3 | 1 | +-----+
mata diagonal(I(3)), (2::4)
Leave a comment: