/[escript]/trunk/finley/src/Mesh_optimizeNodeLabeling.c
ViewVC logotype

Annotation of /trunk/finley/src/Mesh_optimizeNodeLabeling.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1163 - (hide annotations)
Wed May 23 23:56:39 2007 UTC (14 years, 2 months ago) by gross
File MIME type: text/plain
File size: 2202 byte(s)
import of DISPLAY environment variable into scons ENV added. This is required to run pyvisi tests under XGL
1 gross 1156 /*
2     ************************************************************
3     * Copyright 2006, 2007 by ACcESS MNRF *
4     * *
5     * http://www.access.edu.au *
6     * Primary Business: Queensland, Australia *
7     * Licensed under the Open Software License version 3.0 *
8     * http://www.opensource.org/licenses/osl-3.0.php *
9     * *
10     ************************************************************
11     */
12    
13     /**************************************************************/
14    
15     /* Finley: Mesh : optimizes the labeling of nodes */
16    
17     /**************************************************************/
18    
19     /* Author: gross@access.edu.au */
20     /* Version: $Id:$ */
21    
22     /**************************************************************/
23    
24     #include "Mesh.h"
25    
26     /**************************************************************/
27    
28     void Finley_Mesh_optimizeNodeLabeling(Finley_Mesh* mesh_p) {
29    
30     index_t *DOF_permutation=NULL, i;
31     /*
32     Paso_SystemMatrixPattern* pattern_p=NULL;
33 gross 1163 pattern_p=Finley_getPattern(mesh_p,FALSE,FALSE);
34 gross 1156 if no error {
35 gross 1163 XXX=pattern_p. ;
36     DOF_permutation=MEMALLOC(XXX, index_t);
37     availbale=MEMALLOC(XXX, index_t);
38     #pragma omp for private(i)
39     for (i=0;i< ;++i) {
40 gross 1156 DOF_permutation[i]=i;
41 gross 1163 }
42     first_available_node=0;
43     while (first_available_node <= XXX) {
44     // get an available node with minimum number of naighbours
45     max_level_size=XXX;
46     root=...
47     // get the leveling string from root
48     num_levels_tmp=1;
49     num_nodes_in_level_tmp[0]=0;
50     levels_tmp[];
51     // get maximum level size
52     max_level_size_tmp=MAX(num_nodes_in_level_tmp[i+1]-num_nodes_in_level_tmp[i], max_level_size_tmp);
53     // use new leveling if
54     if (max_level_size_tmp<max_level_size) {
55     max_level_size=max_level_size_tmp;
56     num_levels=num_levels_tmp;
57     num_nodes_in_level=num_nodes_in_level_tmp;
58     }
59    
60    
61 gross 1156
62 gross 1163 }
63 gross 1156 }
64     */
65     }

  ViewVC Help
Powered by ViewVC 1.1.26