Changes to incorporate the box_manager changes.
This commit is contained in:
parent
965bf28186
commit
525e0efda4
@ -38,7 +38,6 @@
|
||||
in the future, it needs to use the box manager instead of the neighbors
|
||||
structure */
|
||||
|
||||
#if 0
|
||||
|
||||
/*--------------------------------------------------------------------------
|
||||
* hypre_StructOverlapInnerProd
|
||||
@ -71,8 +70,11 @@ hypre_StructOverlapInnerProd( hypre_StructVector *x,
|
||||
|
||||
hypre_BoxArray *boxes;
|
||||
hypre_Box *boxi, *boxj, intersect_box;
|
||||
hypre_BoxNeighbors *neighbors= hypre_StructGridNeighbors(hypre_StructVectorGrid(y));
|
||||
int *neighbors_procs= hypre_BoxNeighborsProcs(neighbors);
|
||||
|
||||
hypre_StructGrid *grid= hypre_StructVectorGrid(y);
|
||||
hypre_BoxManager *boxman = hypre_StructGridBoxMan(grid);
|
||||
hypre_BoxArray *neighbor_boxes;
|
||||
int *neighbors_procs= NULL;
|
||||
hypre_BoxArray *selected_nboxes;
|
||||
hypre_BoxArray *tmp_box_array, *tmp2_box_array;
|
||||
|
||||
@ -192,7 +194,9 @@ hypre_StructOverlapInnerProd( hypre_StructVector *x,
|
||||
* with the lowest processor id. Therefore, on this processor, we need
|
||||
* to subtract only overlaps with boxes on processors with id < myid.
|
||||
*-----------------------------------------------------------------------*/
|
||||
boxes= hypre_BoxNeighborsBoxes(neighbors);
|
||||
neighbor_boxes = hypre_BoxArrayCreate(0);
|
||||
hypre_BoxManGetAllEntriesBoxesProcs( boxman, neighbor_boxes, neighbors_procs);
|
||||
|
||||
selected_nboxes= hypre_BoxArrayCreate(0);
|
||||
|
||||
/* extract only boxes on processors with ids < myid. */
|
||||
@ -200,9 +204,10 @@ hypre_StructOverlapInnerProd( hypre_StructVector *x,
|
||||
{
|
||||
if (neighbors_procs[i] < myid)
|
||||
{
|
||||
hypre_AppendBox(hypre_BoxArrayBox(boxes, i), selected_nboxes);
|
||||
hypre_AppendBox(hypre_BoxArrayBox(neighbor_boxes, i), selected_nboxes);
|
||||
}
|
||||
}
|
||||
hypre_BoxArrayDestroy(neighbor_boxes);
|
||||
|
||||
boxes= hypre_StructGridBoxes(hypre_StructVectorGrid(y));
|
||||
overlap_boxes= hypre_BoxArrayCreate(0);
|
||||
@ -311,11 +316,3 @@ hypre_StructOverlapInnerProd( hypre_StructVector *x,
|
||||
return final_innerprod_result;
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
double
|
||||
hypre_StructOverlapInnerProd( hypre_StructVector *x,
|
||||
hypre_StructVector *y )
|
||||
{}
|
||||
|
||||
#endif
|
||||
|
||||
Loading…
Reference in New Issue
Block a user