From 9c15d17ced60858df2cada2c239648370fc4323b Mon Sep 17 00:00:00 2001 From: Joachim Schoeberl Date: Sun, 25 Jan 2009 18:23:46 +0000 Subject: [PATCH] parallelinterface --- config.h.in | 3 -- configure.ac | 8 ----- libsrc/include/Makefile.am | 2 +- libsrc/include/Makefile.in | 2 +- libsrc/include/parallelinterface.hpp | 52 ++++++++++++++++++++++++++++ libsrc/interface/Makefile.am | 1 - libsrc/interface/Makefile.in | 2 -- 7 files changed, 54 insertions(+), 16 deletions(-) create mode 100644 libsrc/include/parallelinterface.hpp diff --git a/config.h.in b/config.h.in index 381dfa34..d02434b5 100644 --- a/config.h.in +++ b/config.h.in @@ -18,9 +18,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H -/* Define to 1 if you have the `minabc' function. */ -#undef HAVE_MINABC - /* Define to 1 if you have the `pow' function. */ #undef HAVE_POW diff --git a/configure.ac b/configure.ac index ce4b678a..f2ed92ea 100644 --- a/configure.ac +++ b/configure.ac @@ -70,7 +70,6 @@ AC_DISABLE_STATIC AC_LANG([C++]) AC_PROG_CXX AC_PROG_LIBTOOL -# AC_PROG_RANLIB LT_INIT @@ -92,18 +91,11 @@ AC_CHECK_HEADER([limits.h],[OCCFLAGS="$OCCFLAGS -DHAVE_LIMITS_H"]) AC_CHECK_LIB(pthread, pthread_create) # AC_SEARCH_LIBS(Tcl_Init, [tcl8.5 tcl8.4]) -# AC_SEARCH_LIBS(Tk_Init, [tk8.5 tk8.4]) -# AC_SEARCH_LIBS(Togl_Init, Toglstub2.0 ) - -# TEA_TCL_LINK_LIBS -# AC_DEFINE(USE_TCL_STUBS) -# AC_DEFINE(USE_TK_STUBS) AC_CHECK_FUNCS([pow]) AC_CHECK_FUNCS([floor]) AC_CHECK_HEADERS([limits.h]) -AC_CHECK_FUNCS([minabc]) AC_CONFIG_FILES(Makefile libsrc/Makefile libsrc/csg/Makefile diff --git a/libsrc/include/Makefile.am b/libsrc/include/Makefile.am index 60cfbe60..c6e5e46d 100644 --- a/libsrc/include/Makefile.am +++ b/libsrc/include/Makefile.am @@ -3,7 +3,7 @@ stepgeom.hpp visual.hpp csg.hpp incvis.hpp myadt.hpp opti.hpp \ stepreader.hpp geometry2d.hpp linalg.hpp mydefs.hpp parallel.hpp \ stlgeom.hpp mystdlib.h -include_HEADERS = nginterface.h +include_HEADERS = nginterface.h parallelinterface.hpp AM_CPPFLAGS = METASOURCES = AUTO diff --git a/libsrc/include/Makefile.in b/libsrc/include/Makefile.in index 459f290d..20189918 100644 --- a/libsrc/include/Makefile.in +++ b/libsrc/include/Makefile.in @@ -220,7 +220,7 @@ stepgeom.hpp visual.hpp csg.hpp incvis.hpp myadt.hpp opti.hpp \ stepreader.hpp geometry2d.hpp linalg.hpp mydefs.hpp parallel.hpp \ stlgeom.hpp mystdlib.h -include_HEADERS = nginterface.h +include_HEADERS = nginterface.h parallelinterface.hpp AM_CPPFLAGS = METASOURCES = AUTO all: all-am diff --git a/libsrc/include/parallelinterface.hpp b/libsrc/include/parallelinterface.hpp new file mode 100644 index 00000000..ed262e6b --- /dev/null +++ b/libsrc/include/parallelinterface.hpp @@ -0,0 +1,52 @@ +#ifndef FILE_PARALLELINTERFACE +#define FILE_PARALLELINTERFACE + +#ifdef PARALLEL + +#ifdef __cplusplus +extern "C" { +#endif + + // this interface is 0-base !! + +// // these functions have O(N) complexity +// int NgPar_Glob2Loc_SurfEl ( int globnum ) ; +// int NgPar_Glob2Loc_VolEl ( int globnum ) ; +// int NgPar_Glob2Loc_Segm ( int globnum ) ; +// int NgPar_Glob2Loc_Vert ( int globnum ) ; + + + int NgPar_GetLoc2Glob_VolEl ( int locnum ); + + // int NgPar_GetDistantNodeNums ( int nt, int locnum, int * procs, int * distnum); + + // number on distant processor + + // gibt anzahl an distant pnums zurueck + // * pnums entspricht ARRAY + int NgPar_GetDistantNodeNums ( int nodetype, int locnum, int * pnums ); + int NgPar_GetNDistantNodeNums ( int nodetype, int locnum ); + + int NgPar_GetDistantPNum ( int proc, int locnum ) ; + int NgPar_GetDistantEdgeNum ( int proc, int locnum ) ; + int NgPar_GetDistantFaceNum ( int proc, int locnum ) ; + int NgPar_GetDistantElNum ( int proc, int locnum ); + + bool NgPar_IsExchangeFace ( int fnr ) ; + bool NgPar_IsExchangeVert ( int vnum ); + bool NgPar_IsExchangeEdge ( int ednum ); + bool NgPar_IsExchangeElement ( int elnum ); + + void NgPar_PrintParallelMeshTopology (); + bool NgPar_IsElementInPartition ( int elnum, int dest ); + + bool NgPar_IsGhostFace ( int facenum ); + bool NgPar_IsGhostEdge ( int edgenum ); + +#ifdef __cplusplus +} +#endif + +#endif + +#endif diff --git a/libsrc/interface/Makefile.am b/libsrc/interface/Makefile.am index 5da4d6c8..9ee9b199 100644 --- a/libsrc/interface/Makefile.am +++ b/libsrc/interface/Makefile.am @@ -1,4 +1,3 @@ -# include_HEADERS = nginterface.h noinst_HEADERS = writeuser.hpp AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include -I$(top_srcdir)/libsrc/interface $(TCL_INCLUDES) -DOPENGL diff --git a/libsrc/interface/Makefile.in b/libsrc/interface/Makefile.in index 18371b9b..00cf9db9 100644 --- a/libsrc/interface/Makefile.in +++ b/libsrc/interface/Makefile.in @@ -228,8 +228,6 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -# include_HEADERS = nginterface.h noinst_HEADERS = writeuser.hpp AM_CPPFLAGS = -I$(top_srcdir)/libsrc/include -I$(top_srcdir)/libsrc/interface $(TCL_INCLUDES) -DOPENGL METASOURCES = AUTO