Next: Nearest-neighbor interpolation Up: EXAMPLES OF LINEAR OPERATORS Previous: Internal convolution

## Causal and leaky integration

Causal integration in the continuous world is defined as
 (1)
A more general operator is leaky integration, defined as
 (2)
As , leaky integration becomes causal integration. An efficient numerical implementation of a simple causal integrator employs the fact that operator (1) solves the differential equation
 (3)
and operator (2) solves
 (4)
In the discrete world, equation (4) leads to the recursion scheme
 (5)
where for .The adjoint of (5) is the recursion
 (6)
which corresponds to anticausal leaky integration
 (7)
Module leakint implements causal and anticausal integration.

module leakint

real, private :: r = 1.

contains

subroutine leakint_init (rho)
real, intent (in) :: rho
r = rho
end subroutine leakint_init

integer              :: stat
real, dimension (:)  :: x, y

call integrate (y,size (y),1,x)
else
call integrate (x,1,size (x),y)
end if

stat = 0

contains

subroutine integrate (inp, nb, ne, out)
integer,             intent (in)  :: nb, ne
real, dimension (:), intent (in)  :: inp
real, dimension (:), intent (out) :: out

integer                           :: i
real                              :: t

t = 0.
do i = nb, ne, sign (1, ne - nb)
t = r * t + inp (i)
out (i) = out (i) + t
end do
end subroutine integrate

end function leakint_op

end module leakint


The operator function leakint_op contains and calls the helper subroutine integrate, which implements recusions (5) and (6). Figure 2 illustrates the program for .

 causint90 Figure 2 in1 is an input pulse. C in1 is its causal integral. C' in1 is the anticausal integral of the pulse. in2 is a separated doublet. Its causal integration is a box and its anticausal integration is the negative. CC in2 is the double causal integral of in2.

Next: Nearest-neighbor interpolation Up: EXAMPLES OF LINEAR OPERATORS Previous: Internal convolution
Stanford Exploration Project
11/11/1997