we defined linear interpolation
as the extraction of values from between mesh points.
In a typical setup (occasionally the role of data and model are swapped),
a model is given on a uniform mesh
and we solve the easy problem of extracting values
between the mesh points with subroutine lint1()
.
The genuine problem is the inverse problem, which we attack here.
Data values are sprinkled all around,
and we wish to find a function on a uniform mesh
from which we can extract that data by linear interpolation.
The adjoint operator for subroutine lint1()
simply piles data back into its proper location in model space
without regard to how many data values land in each region.
Thus some model values may have many data points added
to them while other model values get none.
We could interpolate by minimizing the energy in the model gradient,
or that in the second derivative of the model,
or that in the output of any other roughening filter
applied to the model.
Formalizing now our wish
that data
be extractable by linear interpolation
,from a model
,and our wish that application of a roughening filter
with an operator
have minimum energy, we write the fitting goals:
| |
(18) |
![]() |
(19) |
The residual vector has two parts,
a data part
on top
and a model part
on the bottom.
The data residual
should vanish except where contradictory data values
happen to lie in the same place.
The model residual is the roughened model.
Two fitting goals (18) are so common in practice
that it is convenient to adopt our least-square fitting
subroutine solver
accordingly.
The modification
is shown in module reg_solver
.
In addition to specifying the ``data fitting'' operator
(parameter oper),
we need to pass the ``model regularization'' operator
(parameter reg) and the
size of its output (parameter nreg) for proper memory allocation.
Figure 13 shows an example for a (1,-2,1) filter with .The continuous curve representing the model
passes through the data points.
Because the models are computed with transient convolution end-effects,
the models tend to damp linearly to zero outside the region where
signal samples are given.
|
im1-2+190
Figure 13 Sample points and estimation of a continuous function through them. | ![]() |
To show an example where the result is clearly a theoretical answer, I prepared another figure with the simpler filter (1,-1). When we minimize energy in the first derivative of the waveform, the residual distributes itself uniformly between data points so the solution there is a straight line. Theoretically it should be a straight line because a straight line has a vanishing second derivative, and that condition arises by differentiating by ,the minimized quadratic form , and getting .(By this logic, the curves between data points in Figure 13 must be cubics.) The (1,-1) result is shown in Figure 14.
|
im1-1a90
Figure 14 The same data samples and a function through them that minimizes the energy in the first derivative. | ![]() |
The example of Figure 14 has been a useful test case for me. You'll see it again in later chapters. What I would like to show you here is a movie showing the convergence to Figure 14. Convergence occurs rapidly where data points are close together. The large gaps, however, fill at a rate of one point per iteration.