filter_binomial_1D

PURPOSE ^

1D binomial filter (approximation to Gaussian filter)

SYNOPSIS ^

function f = filter_binomial_1D( r, show )

DESCRIPTION ^

 1D binomial filter (approximation to Gaussian filter)

 Creates a binomial filter of size 2*r+1 x 1.  This can be used to approximate the
 Gaussian distribution with sigma=sqrt((2*r+1)/4). For large r, should give same output
 as:
   g = fspecial( 'Gaussian', [2*r+1,1],sqrt((2*r+1)/4) );
 Given sigma, use r ~= 2*sigma^2.

 Use F = f*f' to get the equivalent 2d filter. 

 INPUTS
   r       - mask will have length 2r+1 and var=(2*r+1)/4
   show    - [optional] figure to use for display (no display if == 0)

 OUTPUTS
   f       - 1D binomial filter

 EXAMPLE
   r = 10;
   fbinom = filter_binomial_1D( r, 1 );
   fgauss = filter_gauss_1D( r, sqrt((2*r+1)/4), 2 );

 DATESTAMP
   11-Oct-2005  7:00pm
   
 See also FILTER_GAUSS_1D

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Wed 03-May-2006 23:48:50 by m2html © 2003