next up previous contents
Next: Function: plot_chirp_templates Up: GRASP Routines: Template Bank Previous: Function: get_chirp_grid   Contents


Function: get_chirp_templates

int get_chirp_templates(struct chirp_space *space);
This routine computes the positions of a mesh of chirp templates on a parameter space, using the generic tiling routine tiling_2d(). See section [*] for documentation of this routine. The function get_chirp_templates() passes to tiling_2d() the boundary polygon defined by (*space).x_bound, (*space).y_bound, and (*space).n_bound, as well as the template space metric function chirp_metric(), then converts the returned list of templates into the array (*space).templates. The chirp_metric() routine requires the parameter space to be passed to it as a global static variable named global_space; this variable is set equal to *space. The routine get_chirp_templates() itself returns the error code generated by the call to tiling_2d(); see the documentation of that routine. If a fatal error occurs before tiling_2d() is even called, get_chirp_templates() returns an error code of 3, (*space).n_templates is set to 0 and (*space).templates to NULL. Otherwise, memory for the template array will be allocated; to free this memory, call free((*space).templates).

The argument is:

space: Input/Output. The data structure of the parameter space being filled with templates. This routine uses as input the fields n_bound, x_bound, y_bound, and grid, and assigns the fields n_templates and templates.

Author: Teviet Creighton, teviet@tapir.caltech.edu


next up previous contents
Next: Function: plot_chirp_templates Up: GRASP Routines: Template Bank Previous: Function: get_chirp_grid   Contents
Bruce Allen 2000-11-19