Re: bandmatrix
- To: mathgroup at smc.vnet.net
- Subject: [mg100609] Re: bandmatrix
- From: "Sjoerd C. de Vries" <sjoerd.c.devries at gmail.com>
- Date: Tue, 9 Jun 2009 03:55:47 -0400 (EDT)
- References: <h0id72$lkq$1@smc.vnet.net>
Looks like homework. Do yourself a favor and try to solve it yourself. You will learn much more in the process. Cheers -- Sjoerd On Jun 8, 9:05 am, Prado <josepradom... at yahoo.com.br> wrote: > Hello, I am a newbie in Mathematica. I need help in the problem: > reduce the band of a sparse matrix (100 x 100 ) with 10% approximately > of ones. > I known that Mathematica has a implementation to do this.(see the > code) > Needs["GraphUtilities`"] > ma=Table[ If[n==m,1,If[RandomInteger[100]<90,0,1]],{n,1,100},{m, > 1,100}]; > {r,c}=MinimumBandwidthOrdering[ma,Method->"RCM"]; > (* Show Matrices *) > MatrixPlot[ma,ColorFunction->"Monochrome"] > MatrixPlot[ma[[r,c]],ColorFunction->"Monochrome"] > But the problem is: reduce the band of a sparse matrix (about 10% of > ones) using "simulated annealing" process, without using RCM method or > Sloam method. > Implement a program using Mathematica. > Can someone help me?