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

is_valid_struct

(./FEM/is_valid_struct.m)


Function Synopsis

errflag=is_valid_struct(fem_grid_struct)

Help text

 IS_VALID_STRUCT - Determine if the input structure is "valid"

     IS_VALID_STRUCT determines whether or not the input
     structure is valid or invalid according to the 
     description of FEM_GRID_STRUCT.  A valid FEM_GRID_STRUCT
     contains (atleast) the following (NOT EMPTY) fields:

       .name - the domain name of the FEM grid
       .e    - node connectivity list (linear, triangular) [ne x 3 double]
       .x    - x-horizontal node coordinates               [nn x 1 double]
       .y    - y-horizontal node coordinates               [nn x 1 double]
       .z    - bathymetry list                             [nn x 1 double]
       .bnd  - boundary segment list                       [nb x 2 double]

     As a (not very rigorous) check, the maximum node number in the 
     element and boundary lists must not exceed the length of the node
     list, and the node list ane bathymetry lists must be the same length.

     There is no way to guarantee that the data in the fields actually
     all came from the same domain (mesh).  However, if the 
     FEM_GRID_STRUCT was output from LOADGRID or LOADG, then it is guaranteed.

 CALL: errflag=is_valid_struct(fem_grid_struct)
       
 Written by : Brian O. Blanton
 Summer 1997


Cross-Reference Information

This function is called by

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