https://mooseframework.inl.gov
NeighborInfo.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
12 // Local includes
13 #include "RayTracingCommon.h"
14 
15 // MOOSE includes
16 #include "MooseTypes.h"
17 
18 // Forward declarations
19 namespace libMesh
20 {
21 class Elem;
22 }
23 
28 {
32  NeighborInfo(const Elem * const elem, const std::vector<unsigned short> & sides)
33  : _elem(elem),
34  _sides(sides),
36  _lower_bound(-1),
37  _upper_bound(-1),
38  _valid(true)
39  {
40  }
41 
45  NeighborInfo(const Elem * const elem,
46  const std::vector<unsigned short> & sides,
47  const Real lower_bound,
48  const Real upper_bound)
49  : _elem(elem),
50  _sides(sides),
52  _lower_bound(lower_bound),
53  _upper_bound(upper_bound),
54  _valid(true)
55  {
56  }
57 
59  const Elem * const _elem;
61  const std::vector<unsigned short> _sides;
63  std::vector<Point> _side_normals;
69  bool _valid;
70 };
NeighborInfo(const Elem *const elem, const std::vector< unsigned short > &sides)
Constructor without bounds (used for neighbors that exist only at a point)
Definition: NeighborInfo.h:32
bool _valid
Whether or not this neighbor is valid (needed for neighbors that span an edge)
Definition: NeighborInfo.h:69
The following methods are specializations for using the Parallel::packed_range_* routines for a vecto...
Struct for containing the necessary information about a cached neighbor for ray tracing.
Definition: NeighborInfo.h:27
const std::vector< unsigned short > _sides
The sides on the element that the neighboring portion is contained in.
Definition: NeighborInfo.h:61
std::vector< Point > _side_normals
The normals of each side in _sides.
Definition: NeighborInfo.h:63
char ** sides
const Elem *const _elem
The element.
Definition: NeighborInfo.h:59
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const Real _lower_bound
The lower bound (used for neighbors that span an edge)
Definition: NeighborInfo.h:65
const Real _upper_bound
The lower bound (used for neighbors that span an edge)
Definition: NeighborInfo.h:67
static const libMesh::Point invalid_point(invalid_distance, invalid_distance, invalid_distance)
Identifier for an invalid point.
NeighborInfo(const Elem *const elem, const std::vector< unsigned short > &sides, const Real lower_bound, const Real upper_bound)
Constructor with bounds (used for neighbors that span an edge)
Definition: NeighborInfo.h:45