Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Interpolating matrix

  • To: mathgroup at
  • Subject: [mg45529] Re: Interpolating matrix
  • From: Paul Abbott <paul at>
  • Date: Mon, 12 Jan 2004 02:15:39 -0500 (EST)
  • Organization: The University of Western Australia
  • References: <btndag$37$>
  • Sender: owner-wri-mathgroup at

In article <btndag$37$1 at>,
 Zsolt Regaly <rezso at> wrote:

> Hi
> Could anybody help me to find out how can I interpolate a matrix?
> Let'us have a 10x10 matrix and I'd like to make a DensityPlot by
> resolution of 100x100 for example. 

Use Interpolation. Here is some (indexed) data:

  Table[{x, y, Cos[x y]}, {x, 0, 1, 0.2}, {y, 0, 1, 0.2}]

Interpolate (after converting to a one-dimensional data list),

  cosint=Interpolation[Flatten[%, 1]]

and then plot:

 DensityPlot[cosint[x,y],{x,0,1},{y,0,1},PlotPoints->100, Mesh-> False]; 


Paul Abbott                                   Phone: +61 8 9380 2734
School of Physics, M013                         Fax: +61 8 9380 1014
The University of Western Australia      (CRICOS Provider No 00126G)         
35 Stirling Highway
Crawley WA 6009                      mailto:paul at 

  • Prev by Date: Re: Wishart Distribution
  • Next by Date: Re: Convert automatic objects to literal
  • Previous by thread: Interpolating matrix
  • Next by thread: finding eigenvalues