Re: diagonal matrix
- To: mathgroup at smc.vnet.net
- Subject: [mg29120] Re: [mg29095] diagonal matrix
- From: Andrzej Kozlowski <andrzej at tuins.ac.jp>
- Date: Wed, 30 May 2001 05:50:35 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
on 01.5.29 3:57 PM, Su Su Win at susuwin at post.kek.jp wrote: > Hello, > It's me again. > How can I make diagonal matrix (1153x1153) with 1 at diagonal? > Thank you very much in advance. > Regards, Win > > > The answer is simple, e.g: In[1]:= t=DiagonalMatrix[Array[1&,{1153}]]; However, I would not wish to find out what happens if one tries to display this. You can however manipulate it without displaying it: In[2]:= Dimensions[t] Out[2]= {1153,1153} In[4]:= Tr[t] Out[4]= 1153 In[5]:= Det[t] Out[5]= 1 Though of course you do not really need a computer for any of this... -- Andrzej Kozlowski Toyama International University JAPAN http://platon.c.u-tokyo.ac.jp/andrzej/ http://sigma.tuins.ac.jp/~andrzej/