# How to distort a signal (image) pattern using bilinear interpolation

I have a signal pattern $s$ that generated at time $t$ like this: $$s(x,y,t)=D(x,y)\sin(\omega t-0.56)$$

Where $D(x,y)$ is a mode shape, calculated by $$D(x,y)=a\left\{\left(\frac{x}{m}-0.55\right)x-\left(\frac{y}{n}-0.55\right)y\right\}$$ Where $m,n,a$ is the $m\times n$ size of image and excite amplitude respectivetly.

The image $i$ is multiplied by $s(x,y,t)$ to get the mode shape $f$ $$f(x,y,t)=s(x,y,t)\cdot i(x,y)$$

My question is, at every instance of time $t$, how do I distort the shape $f$ using bilinear interpolation?

Matlab function before the distortion:

function [ sim ] = simvib( inputimage, amplitude, T, normalizedto, pauses )

if ~exist('pauses', 'var'), pauses=0.5; end
omega = 1;
[m, n] = size(inputimage);
[x, y]=meshgrid(1:n,1:m);
D=amplitude.*(((x/m)-0.55).^2.*x-((y/n)-0.55).^2.*y);
sim=zeros(m,n,T);
for t=1:T
simulate=D.*sin(omega*t-0.56).*inputimage;
simulate=normalize_var(simulate, 0, normalizedto); %normalize max to normalizedto
sim(:,:,t) = simulate;
imagesc(sim(:,:,t)); %the mode shape
pause(pauses);
end

end


• The function above will produce the mode shape for time t:T, without any distortion, that means the mode shapes will be the same for time t:T. My idea was to produce a different mode shape at every instance of $t$. However I'm not clear with how can the pattern be distorted to produce a new pattern. I'm following the steps in this paper, section 5.2(last paragraph on that page). Edited the question! Thanks! – Gregor Isack Apr 6 '17 at 14:36