Playing with 2D fourier transforms and interferometry

First task is to make a "fake" map, which I did in photoshop with the brush , blur, noise, and smudge tools.  Then I saved it as "raw data" (8 bits = 1 byte per pixel, 64 x 64 bytes.)

Then I read this into matheematica.

SetDirectory["barrachois:Users:mahoney:docs:mathematica:radioDemo"]

Directory[]

FileNames["*.*"]

mymap  =  ReadList["map3.raw", Byte];

Dimensions[mymap]

data  =  Partition[mymap, 64];

Dimensions[data]

ListDensityPlot[data]

ListPlot[data[[20]]]

data  =  256.0 - data;

ListPlot3D[data, PlotRange -> {0, 256}]

Now,  your turn :

(1) Read in "map3.raw", as shown here, 64 x 64 array
         of numbers 0 -> 255
(2) Suppose this is a map of the sky
        largest spacing = A
        smallest = A/N = A/64  here
(3) If this map was made with an interferometer with 
        lambda = 21 cm,  and longest spacing = 300 meters,
       how big a patch of sky is this?  (In other words, find dk and kmax from dx and xmax).
		
(4) Assume that this map is the _true_ sky.  We're going
      to find the "dirty" map before cleaning.


(5) First, we need to find the beam pattern.  Assume
that you have 6 telescopes in a Y pattern, i.e.
 (r cos(theta), r(sin(theta))  with
 r = (50 m, 150 m),  theta = ( 0, 2pi/3, 4pi/3).
 Construct a 64 x 64 map that is zero everywhere 
 except at the 36 points corresponding to each pair of telescope positions, where the map is 1.0.  Fourier transform this map to get  the beam pattern.
		
(6) Convolve this beam with the map3.raw image to   get the "dirty" image.  (yuch.)  
		
(7) Here's another way to think of the same thing:

Fourier transform the clean map to find the true intensities that pairs of telescopes on the ground would measure.  (Make sure you can state the units correctly on each plot!)

Sample these intensities at the points where there would actually be data (that is, where you have a pair of telescopes to measure that fourier component); set the other points to zero.  Transform back into the image (sky) plane to see what you've got.  
		
(8) With only 36 data points to represent 64*64 = 4096 map points, the beam is going to be pretty crude.  Optionally, allow the pattern to rotate, generating more points - this mimics the earth's rotation and collection more data over time.  Or, add more telescopes and hence more pairs.
		
		
(9) The main point of all this is to see roughly the relation between the image plane and ground (fourier) plane for interferometry, including the telescope ground positions and beam pattern.