Mechanics of Defect Evolution Library
Loading...
Searching...
No Matches
include
Geometry
LineSegmentIntersection.h
Go to the documentation of this file.
1
/* This file is part of MoDELib, the Mechanics Of Defects Evolution Library.
2
*
3
*
4
* MoDELib is distributed without any warranty under the
5
* GNU General Public License (GPL) v2 <http://www.gnu.org/licenses/>.
6
*/
7
8
#ifndef model_LineSegmentIntersection_H_
9
#define model_LineSegmentIntersection_H_
10
11
#include <tuple>
12
#include <map>
13
#include <stdexcept>
14
#include <Eigen/Dense>
15
16
namespace
model
17
{
18
19
template
<
int
dim>
20
class
LineSegmentIntersection
21
{
22
23
public
:
24
enum
IntersectionType
{
PARALLEL
,
COINCIDENT
,
INCIDENT
,
SKEW
,
OUTSIDE
};
25
26
27
typedef
Eigen::Matrix<double,dim,1>
VectorDimD
;
28
typedef
std::tuple<IntersectionType,VectorDimD,VectorDimD,double,double>
SolutionType
;
29
30
private
:
31
const
SolutionType
sol;
32
33
/**********************************************************************/
34
static
SolutionType
findIntersections(
const
VectorDimD
& A0,
35
const
VectorDimD
& D0,
36
const
VectorDimD
& A1,
37
const
VectorDimD
& D1);
38
39
public
:
40
41
const
IntersectionType
&
type
;
42
const
VectorDimD
&
x0
;
43
const
VectorDimD
&
x1
;
44
const
double
&
u0
;
45
const
double
&
u1
;
46
47
/**********************************************************************/
48
LineSegmentIntersection
(
const
VectorDimD
& A0,
49
const
VectorDimD
& D0,
50
const
VectorDimD
& P0,
51
const
VectorDimD
& P1);
52
53
};
54
55
/******************************************************************/
56
/******************************************************************/
57
}
/* namespace model */
58
#endif
model::LineSegmentIntersection::LineSegmentIntersection
LineSegmentIntersection(const VectorDimD &A0, const VectorDimD &D0, const VectorDimD &P0, const VectorDimD &P1)
Definition
LineSegmentIntersection.cpp:96
model::LineSegmentIntersection::u0
const double & u0
Definition
LineSegmentIntersection.h:44
model::LineSegmentIntersection::x0
const VectorDimD & x0
Definition
LineSegmentIntersection.h:42
model::LineSegmentIntersection::VectorDimD
Eigen::Matrix< double, dim, 1 > VectorDimD
Definition
LineSegmentIntersection.h:27
model::LineSegmentIntersection::type
const IntersectionType & type
Definition
LineSegmentIntersection.h:41
model::LineSegmentIntersection::SolutionType
std::tuple< IntersectionType, VectorDimD, VectorDimD, double, double > SolutionType
Definition
LineSegmentIntersection.h:28
model::LineSegmentIntersection::IntersectionType
IntersectionType
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::OUTSIDE
@ OUTSIDE
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::PARALLEL
@ PARALLEL
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::SKEW
@ SKEW
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::INCIDENT
@ INCIDENT
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::COINCIDENT
@ COINCIDENT
Definition
LineSegmentIntersection.h:24
model::LineSegmentIntersection::u1
const double & u1
Definition
LineSegmentIntersection.h:45
model::LineSegmentIntersection::x1
const VectorDimD & x1
Definition
LineSegmentIntersection.h:43
model
Definition
DD_converter.dox:2
Generated by
1.15.0