3

I understand this is a weird question, but I think this could be a place in which I could find the answer.

I'm trying to reprodice this image: enter image description here

with a java applet. I know that this image is a grid-Fresnel zone plate" but unfortunately I don't know the reference.

I've measured the white square and this is the result (in pixels):

  • the bigger dot is 8 pixel
  • the second bigger is 6
  • the third is 2

Now i have 8, 6, 2... How can I get the generating function of these numbers?

I hope it's clear, sorry but english is not my first language.

Shog9
  • 101
nkint
  • 1,823
  • What do you mean "8 pixels"? You mean the area has 8 pixels? Or a side has length 8 pixels? Why can't you find all values of the pixels and "fit",using for instance Integer sequences? – Raskolnikov Apr 02 '11 at 09:21
  • The problem you have is that these numbers are not really integers. If you take a diagonal from the centre, you get something like 12 black, 1 grey, 6 white, 1 grey, 4 black, 1 grey, 3 white, 1 grey, 3 black, 1 grey, 2 white, 1 grey, 2 black, 1 grey, 2 white, 1 grey, etc. You are not going to be able to reproduce this using integer sequences. – Henry Apr 02 '11 at 11:08
  • @Henry: Yeah, never mind that. I found a solution anyway. – Raskolnikov Apr 02 '11 at 11:24

1 Answers1

5

EDIT2: After a bit of fiddling around, I found this one works best:

$$I(x,y)=\frac{(1-\mbox{sign}(\cos(kx^2)))(1-\mbox{sign}(\cos(ky^2)))}{4}$$

See the plot in Wolfram Alpha: plot.


Looking at the wikipage for zone plates, there is a formula for the opacity in the spherical case. But it is easy to adapt to other cases by changing $r=\sqrt{x^2+y^2}$ by another metric like $r=\max(|x|,|y|)$ or $r=|x|+|y|$. Then you just have to adjust the free parameter $k$.

So, you can try a formula of the following form:

$$I(x,y)=\frac{1\pm \mbox{sign}(\cos(k\max(x^2,y^2))}{2}$$

with $k$ a free parameter you can choose to try to fit what you have in your picture.

EDIT : Sorry, I made a mistake, since the function I propose you above gives concentric squares. The following formula should do the trick however:

$$I(x,y)=\frac{2+\mbox{sign}(\sin(kx^2))+\mbox{sign}(\sin(ky^2))}{2} \; .$$

Raeder
  • 1,469
Raskolnikov
  • 16,108
  • 1
    BON! SUPER BON! – awllower Apr 02 '11 at 10:45
  • wow! perffect, thanks! Two remained doubt (sorry for my poor math background): 1) why $sign(sin(x^2))$ give a square? 2) how can i achive parametric formulas $x = \dots$, $y=\dots$ ? – nkint Apr 02 '11 at 13:45
  • I think you better use the very first formula. The others were just trials. Anyway, are you asking why the end result gives squares or are you asking why I use $x^2$? The $x^2$ is giving the right decreasing behaviour for the size of the white pixel blocks. It follows from the laws of diffraction on the zone plate page. The squares in the figure follow from how I combine the functions. – Raskolnikov Apr 03 '11 at 08:43
  • thanks! sorry for the late, i'm asking why if i plot in wolframalpha $sign(sin(x^2))$ it plot a square wave.. – nkint Apr 04 '11 at 15:44
  • Well, the $\sin$ function is obviously a harmonic wave. The sign function just takes the sign of a number. Since $\sin$ oscillates between positive and negative values, the sign jumps from $+1$ to $-1$ and back, which results in a square wave or block wave. – Raskolnikov Apr 04 '11 at 21:39
  • 1
    Alternatively, you could use a construct like $(-1)^{\lfloor x\rfloor}$ for square waves... what to use depends on whether it's easier to compute a sine or a power in your environment... – J. M. ain't a mathematician Apr 07 '11 at 08:26