1
$\begingroup$

I am trying to solve an optimization problem where I need to take as few data points as possible to recreate a field. I know the field will have a shape similar to a 2-d Gaussian with a known center point. However, there may be some directional imperfections in the field (one side might have a steeper slope than the other).Therefore, I've come to the conclusion that an xy scan would provide adequate information to recreate the 2d shape, however I'm having trouble determining how to do this.

I'm working in python and using a linear interpolation function which will not construct the field properly given only x and y axes. One idea I am considering is converting to a polar coordinate system to do the interpolation then converting back. Converting to this coordinate system would force the xy points to be plotted on a grid which might help the interpolation function.

It feels like this will work, but I don't know enough about the math behind different kinds of interpolation methods (or the conversion for that matter) to prove to myself that it will work. Is this the appropriate way to do the interpolation or is there another method I'm not aware of?

Thanks!

  • 0
    Is it correct that you have sites $(x_1,y_1), \dotsc, (x_n,y_n)$ and values $z_1,\dotsc, z_n$, and you want to find a function $f$ by interpolation such that $$ f(x_i,y_i) = z_i$$ for $i=1,\dotsc, n$?2017-02-08
  • 0
    Not quite, I have points on the axes. So, $f(x_i, y_0)=z_i$ and $f(x_0, y_j)=z_j$ for $i=0,...,n$. I am looking for a function $f$ such that $f(x_i,y_j)=z_{ij}$.2017-02-09
  • 0
    what are the $z_{i,j}$'s?2017-02-09
  • 0
    They are interpolated from the given data, with the knowledge that the data is fairly radially symmetric.2017-02-09
  • 0
    I am confused. What are the data given and what are you looking for?2017-02-09
  • 0
    Sorry if I'm explaining this poorly, I don't have the best mathematical background. I have discrete measured data along the lines x = 0 and y = 0. I want to fill in the surface using this measured data. I also have the knowledge that the surface is fairly radially isotropic (only slight variations for a given magnitude $x^2 + y^2$.2017-02-09

1 Answers 1

0

Assume that $x_1,\dotsc,x_m$, $y_1,\dotsc,y_n$, and $u_1,\dotsc,u_m$, $v_1,\dotsc,v_n$ are given. Assume that there is a function $f:\mathbb R^2 \to \mathbb R$ with $$ f(x_i,0) = u_i $$ and $$ f(0,y_j) = v_j. $$ Further, assume there is a function $g:[0,\infty)\to\mathbb R$ with $$f(x,y) = g(x^2 + y^2).$$

Now, "find" $g$:

Since you said the field looks "gaussian", let us assume $$ g(t^2) = b \exp(a t^2). $$ That is, we have $$ \log(f(x_i,0)) = \log(g(x_i^2)) = \log(b) + a x_i^2 = \log(u_i) $$ and $$ \log(f(0,y_j)) = \log(g(y_j^2)) = \log(b) + a y_j^2 = \log(v_j), $$ or as matrix equation $$ \underbrace{\begin{bmatrix}1 & x_1^2 \\ \vdots \\ 1 & x_m^2 \\ 1 & y_1^2 \\ \vdots \\ 1 & y_n^2 \end{bmatrix}}_{A} \underbrace{\begin{bmatrix}\log(b) \\ a \end{bmatrix}}_{\beta} = \underbrace{\begin{bmatrix}\log u_1 \\ \vdots \\ \log u_m \\ \log v_1 \\ \vdots \\ \log v_n \end{bmatrix}}_{w}. $$ Taking a least squares approach yield the estimator $$ \hat\beta = (A^T A)^{-1} A w. $$

  • 0
    This is great! Thanks for the detailed explanation.2017-02-09