[Index for ./FEM] [Return to Master Index]

which_elem

(./FEM/which_elem.m)


Function Synopsis

j=which_elem(fem_grid_struct,xylist)

Help text

 WHICH_ELEM determine bounding finite element in given domain
    WHICH_ELEM finds the element number for the
    current mouse position.  WHICH_ELEM prompts
    the user to click on the current axes and returns
    the element for the "click-on" position, or NaN
    if the click is outside the domain.

    Alternatively, a list of horizontal points can
    be passed in and a list of element numbers, one for
    each input point will be returned.

    In determining which element has been selected,
    WHICH_ELEM needs elemental areas and shape functions.
    The routines BELINT and EL_AREAS compute these arrays
    and add them to a previously created fem_grid_struct.
    These two functions MUST be run before WHICH_ELEM will
    run.
    BELINT is run as:
      >> new_struct=belint(fem_grid_struct); 
    EL_AREAS is run as:
      >> [new_struct,ineg]=el_areas(fem_grid_struct); 

  INPUT : fem_grid_struct - (from LOADGRID, see FEM_GRID_STRUCT)     
          xylist          - points to find elements for [n x 2 double] 
           
 OUTPUT : an element number(s)
 
   CALL : >> j=which_elem(fem_grid_struct)   for interactive
    or
          >> j=which_elem(fem_grid_struct,xylist)        

 Written by : Brian O. Blanton 
 Summer 1997


Cross-Reference Information

This function calls

Produced by mat2html on Tue Feb 2 16:15:45 EST 1999
Cross-Directory links are: OFF