TheBoussinesqModel  3.2.1
 All Data Structures Files Functions Variables Typedefs Macros Pages
geometry2.h File Reference

Go to the source code of this file.

Data Structures

struct  DOUBLE_GRID
 

Functions

POINTnew_point_from_point (POINT *point)
 
LINEnew_line_from_line (LINE *line)
 
LINEVECTORnew_linevector_from_linevector (LINEVECTOR *lines)
 
POLYGONnew_polygon_from_polygon (POLYGON *polygon)
 
POLYGONVECTORnew_polygonvector_from_polygonvector (POLYGONVECTOR *polygons)
 
polygon_connection_attributesnew_connection_from_connection (polygon_connection_attributes *pc)
 
polygon_connection_attribute_arraynew_connection_array_from_connection_array (polygon_connection_attribute_array *pca)
 
GRIDnew_grid_from_grid (GRID *grid)
 
LONGBINnew_longbin_from_doublematrix_array (LONGMATRIX_VECTOR *lmv)
 
LONGBINnew_longbin_from_longbin (LONGBIN *lb)
 
DOUBLE_GRIDnew_double_grid_from_doublesquare_grid (DOUBLESQUARE_GRID *dsq)
 
void free_DOUBLE_GRID (DOUBLE_GRID *dgrid)
 
LONGBINnew_longbin_from_longbin_cleaning_novalues (LONGBIN *lb)
 
long bubble_sort_eleveation (long *cell_index, long nh, DOUBLEVECTOR *elevation)
 
int bubble_sort_elevation_in_longbin (LONGBIN *lb, DOUBLEVECTOR *elevation)
 

Function Documentation

int bubble_sort_elevation_in_longbin ( LONGBIN lb,
DOUBLEVECTOR elevation 
)
Author
Emanuele Cordano
Date
April 2010

Definition at line 520 of file geometry2.c.

References bubble_sort_eleveation(), LONGBIN::index, NL, and LONGVECTOR::nl.

Referenced by main().

long bubble_sort_eleveation ( long *  cell_index,
long  nh,
DOUBLEVECTOR elevation 
)
Author
Emanuele Cordano
Date
April 2001
Parameters
-(long*) cell_index : index of the cells
-(long) number of the cells in the rows
(DOUBLEVECTOR*) - map of elevation

sort the cell_indexes according with the increase of elevation.

swap cell_index[i] and cell_index[i+1]

swap cell_index[i] and cell_index[i+1]

Definition at line 451 of file geometry2.c.

References DOUBLEVECTOR::nh, and DOUBLEVECTOR::nl.

Referenced by bubble_sort_elevation_in_longbin().

void free_DOUBLE_GRID ( DOUBLE_GRID dgrid)
Parameters
\authorEmanuele Cordano
Date
April 2010

Definition at line 350 of file geometry2.c.

References DOUBLE_GRID::coarse, DOUBLE_GRID::fine, free_grid(), free_longbin(), DOUBLE_GRID::small_line_content, and DOUBLE_GRID::small_polygon_content.

Referenced by main().

polygon_connection_attribute_array* new_connection_array_from_connection_array ( polygon_connection_attribute_array pca)
LINE* new_line_from_line ( LINE line)
Parameters
(LINE*) line
Author
Emanuele Cordano
Date
April 2010

Definition at line 31 of file geometry2.c.

References LINE::begin, LINE::end, LINE::index, and new_line_from_points().

Referenced by new_linevector_from_linevector().

LINEVECTOR* new_linevector_from_linevector ( LINEVECTOR lines)
Parameters
(LINEVECTOR*) line
Author
Emanuele Cordano
Date
April 2010

Definition at line 55 of file geometry2.c.

References LINEVECTOR::element, new_line_from_line(), new_linevector(), LINEVECTOR::nh, and LINEVECTOR::nl.

Referenced by new_grid_from_grid().

LONGBIN* new_longbin_from_doublematrix_array ( LONGMATRIX_VECTOR lmv)

The following functions transforms a DOUBLESQUARE_GRID into a DOUBLEGRID

Parameters
(LONGMATRIX_VECTOR* ) - lmv
(long)- novalue
Author
Emanuele Cordano

Definition at line 232 of file geometry2.c.

References LONGMATRIX_VECTOR::element, free_longvector(), LONGBIN::index, LONGMATRIX::ncl, new_longbin(), new_longvector(), LONGMATRIX_VECTOR::nh, LONGVECTOR::nh, LONGMATRIX_VECTOR::nl, NL, LONGVECTOR::nl, and LONGMATRIX::nrl.

Referenced by new_double_grid_from_doublesquare_grid().

LONGBIN* new_longbin_from_longbin ( LONGBIN lb)
Parameters
(LONGBIN*) - lb
Author
Emanuele Cordano
Date
April 2010

Definition at line 296 of file geometry2.c.

References LONGBIN::index, new_longbin(), NL, and LONGVECTOR::nl.

LONGBIN* new_longbin_from_longbin_cleaning_novalues ( LONGBIN lb)
Parameters
(LONGBIN*) - lb
Author
Emanuele Cordano
Date
April 2010

Definition at line 369 of file geometry2.c.

References free_longvector(), LONGBIN::index, new_longbin(), new_longvector(), LONGVECTOR::nh, NL, LONGVECTOR::nl, and stop_execution().

Referenced by new_double_grid_from_doublesquare_grid().

POINT* new_point_from_point ( POINT point)
Parameters
(POINT*) point
Author
Emanuele Cordano
Date
April 2010

Definition at line 15 of file geometry2.c.

References POINT::index, new_point(), POINT::x, POINT::y, and POINT::z.

Referenced by new_polygon_from_polygon().

POLYGON* new_polygon_from_polygon ( POLYGON polygon)
Parameters
(POLYGON*) polygon;
Author
Emanuele Cordano

Definition at line 78 of file geometry2.c.

References POLYGON::area2D, POLYGON::centroid, POLYGON::edge_indices, POLYGON::index, new_longvector(), new_point_from_point(), LONGVECTOR::nh, and LONGVECTOR::nl.

Referenced by new_polygonvector_from_polygonvector().

POLYGONVECTOR* new_polygonvector_from_polygonvector ( POLYGONVECTOR polygons)
Parameters
(POLYGONVECTOR*) - polygons
Author
Emanuele Cordano
Date
April 2010

Definition at line 107 of file geometry2.c.

References POLYGONVECTOR::element, new_polygon_from_polygon(), new_polygonvector(), POLYGONVECTOR::nh, and POLYGONVECTOR::nl.

Referenced by new_grid_from_grid().