function WUPSMPLE, x ;+ ; NAME: ; WUPSMPLE ; ; PURPOSE: ; This function performs an upsampling operation. ; ; CATEGORY: ; Wavelets ; ; CALLING SEQUENCE: ; y = WUPSMPLE(x) ; ; INPUTS: ; x: 1-d signal, of length n ; ; OUTPUTS: ; y: 1-d signal, of length 2*n with zeros ; interpolating alternate samples ; y(2*i-2) = x(i-1), i=1 ..n ; ; EXAMPLE: ; ; SEE ALSO: ; wdndydhi, wdndydlo, wupdydhi, wiwtpo, waconv ; ; MODIFICATION HISTORY: ; Written by: Amara Graps November, 1994 ;Translated from MatLab Wavelab routine: upsample.m ;- n = N_ELEMENTS(x)*2 y = FLTARR(n) ;use the IDL way to create an index array a = 1 & b = 2 & c = n-1 indx_arr = WMKIARRY( a, b, c) y(indx_arr)=x ; ; Algorithm Source: WaveLab Version 0.600 ; WaveLab WWW site: http://playfair.stanford.edu/ ; WaveLab Questions? e-mail wavelab@playfair.stanford.edu ; RETURN, y END ;***************************************************