face.c
Go to the documentation of this file.
00001 /*    make the pointers among new edges on the new hyperplane */
00002 
00003 #include "arith.h"
00004 
00005 face(linetab,mi,m,r,n)
00006 LINE linetab[MAXEDGE];
00007 int mi,m,r,n;
00008 {
00009     register int i,j,k,l,count;
00010     register unsigned int planework;
00011 
00012     /* check all combination of two new edges on hyperplane(i) */
00013     for(i=mi; i<m; i++){
00014         l=1;
00015         for(j=mi; j<m; j++){
00016             if(i != j){
00017                 planework= linetab[i].plane & linetab[j].plane;
00018                 count=0;
00019                 for(k=0; k<n; k++){
00020                     if((planework & (1<<k)) != 0)
00021                         count += 1;
00022                 }
00023                 /* when (r-2) hyperplanes are common, make face pointer */
00024                 if(count == (r-2)){
00025                     linetab[i].face[l]=j;
00026                     l += 1;
00027                 }
00028             }
00029         }
00030         /* make a mark indicating there is no futher face pointer */
00031         linetab[i].face[l]=EMPTY;
00032     }
00033 }
00034 


euslisp
Author(s): Toshihiro Matsui
autogenerated on Thu Jun 6 2019 18:05:53