#$=head1 NAME #$ #$createnhelix - create non stationary helix filter #$ #$ #$=head1 SYNOPSIS #$ #$C #$ #$=head1 INPUT PARAMETERS #$ #$=over 4 #$ #$=item nd - C #$ #$ size of data #$ #$=item center - C #$ #$ location of the 1 of the filter within na box #$ #$=item gap - C #$ #$ distance along each axis before filter coef #$ #$=item na - C #$ #$ size of box arround filter #$ #$=item patch - C #$ #$ what model point a given filter will act on #$ #$=back #$ #$=head1 RETURN VALUE #$ #$=over 4 #$ #$=item aa - C #$ #$ Helix filter #$ #$=back #$ #$=head1 DESCRIPTION #$ #$Create a non-stationary helix filter #$ #$=head1 SEE ALSO #$ #$L,L,L #$ #$=head1 LIBRARY #$ #$B #$ #$=cut module createnhelixmod { # Create non-stationary helix filter lags and mis use createhelixmod use nhelix use nbound contains function createnhelix( nd, center, gap, na, pch) result (nsaa) { type( nfilter) :: nsaa # needed by nhelicon integer, dimension(:), intent(in) :: nd, na # data and filter axes integer, dimension(:), intent(in) :: center # normally (na1/2,na2/2,...,1) integer, dimension(:), intent(in) :: gap # normally ( 0, 0, 0,...,0) integer, dimension(:), intent(in) :: pch # (prod(nd)) patching type( filter) :: aa integer :: n123, np, ip integer, dimension(:), allocatable :: nh aa = createhelix( nd, center, gap, na) n123 = product( nd); np = maxval(pch) allocate (nh (np)); nh = size (aa%lag) call nallocate( nsaa, nh, pch) do ip = 1, np nsaa%hlx( ip)%lag = aa%lag call deallocatehelix (aa) call nboundn( nd, na, nsaa) } }