Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
ogs-feliks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Feliks Kiszkurno
ogs-feliks
Commits
6afdb2be
Commit
6afdb2be
authored
10 years ago
by
Karsten Rink
Browse files
Options
Downloads
Patches
Plain Diff
initial implementation of radius-edge-metric
parent
3e7f467d
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
MeshLib/MeshQuality/RadiusEdgeRatioMetric.cpp
+45
-0
45 additions, 0 deletions
MeshLib/MeshQuality/RadiusEdgeRatioMetric.cpp
MeshLib/MeshQuality/RadiusEdgeRatioMetric.h
+36
-0
36 additions, 0 deletions
MeshLib/MeshQuality/RadiusEdgeRatioMetric.h
with
81 additions
and
0 deletions
MeshLib/MeshQuality/RadiusEdgeRatioMetric.cpp
0 → 100644
+
45
−
0
View file @
6afdb2be
/**
* \file RadiusEdgeRatioMetric.cpp
* \author Thomas Fischer
* \date 2014-09-02
* \brief Implementation of the RadiusEdgeRadioMetric class.
*
* \copyright
* Copyright (c) 2012-2014, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*/
#include
"RadiusEdgeRatioMetric.h"
#include
"Node.h"
#include
"MinimalBoundingSphere.h"
namespace
MeshLib
{
RadiusEdgeRatioMetric
::
RadiusEdgeRatioMetric
(
Mesh
const
*
const
mesh
)
:
ElementQualityMetric
(
mesh
)
{}
void
RadiusEdgeRatioMetric
::
calculateQuality
()
{
std
::
vector
<
MeshLib
::
Element
*>
const
&
elements
(
_mesh
.
getElements
());
size_t
const
nElements
(
_mesh
.
getNElements
());
for
(
size_t
k
(
0
);
k
<
nElements
;
k
++
)
{
Element
const
&
elem
(
*
elements
[
k
]);
std
::
size_t
const
n_nodes
(
elem
.
getNNodes
());
MeshLib
::
Node
*
const
*
const
nodes
=
elem
.
getNodes
();
std
::
vector
<
GeoLib
::
Point
*>
pnts
(
n_nodes
);
std
::
copy_n
(
elem
.
getNodes
(),
n_nodes
,
pnts
.
begin
());
GeoLib
::
MinimalBoundingSphere
const
s
(
pnts
);
double
min
,
max
;
elem
.
computeSqrEdgeLengthRange
(
min
,
max
);
_element_quality_metric
[
k
]
=
sqrt
(
min
)
/
(
2
*
s
.
getRadius
());
}
}
}
// end namespace MeshLib
This diff is collapsed.
Click to expand it.
MeshLib/MeshQuality/RadiusEdgeRatioMetric.h
0 → 100644
+
36
−
0
View file @
6afdb2be
/**
* \file RadiusEdgeRatioMetric.h
* \author Karsten Rink
* \date 2014-09-02
* \brief Definition of the RadiusEdgeRatioMetric class.
*
* \copyright
* Copyright (c) 2012-2014, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*/
#ifndef RADIUSEDGERATIOMETRIC_H_
#define RADIUSEDGERATIOMETRIC_H_
#include
"ElementQualityMetric.h"
namespace
MeshLib
{
/**
* Calculates the quality of mesh elements based on the EquiAngleSkew measure
*/
class
RadiusEdgeRatioMetric
:
public
ElementQualityMetric
{
public:
RadiusEdgeRatioMetric
(
Mesh
const
&
mesh
);
virtual
~
RadiusEdgeRatioMetric
()
{};
virtual
void
calculateQuality
();
};
}
#endif
/* RADIUSEDGERATIOMETRIC_H_ */
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment