Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Aspect_Metric_3 Class Reference

3D Aspect Ratios Metric Class More...

#include <Geometric_Metrics_3.h>

Inheritance diagram for Aspect_Metric_3:
Collaboration diagram for Aspect_Metric_3:

Public Member Functions

 Aspect_Metric_3 ()
 Initialize a 3D Aspect Metric. More...
 
virtual void compute (double atts[]) const
 Calculate the metric value on this element. More...
 
double maxValue () const
 Get the maximum value for this metric. More...
 
double minValue () const
 Get the minimum value for this metric. More...
 
void getAspects (double &R, double &r, double &l)
 Get the geometric aspects. More...
 
- Public Member Functions inherited from Geo_Metric_Base_3
 Geo_Metric_Base_3 ()
 
virtual ~Geo_Metric_Base_3 ()
 
virtual void initialize (Vector_3< double > n[], int type)
 Initialize a 3D Geometric Metric by nodal coords and element type. More...
 
virtual void initialize (Element_node_enumerator &ene)
 Initialize a 3D Geometric Metric by Element_node_enumerator. More...
 
- Public Member Functions inherited from Metric
 Metric ()
 
virtual ~Metric ()
 

Additional Inherited Members

- Protected Member Functions inherited from Geo_Metric_Base_3
void compute_angles (double &min, double &max) const
 Compute min and max dihedral angles. More...
 
void compute_aspects (double &R, double &r, double &l) const
 Compute circumradius, inradius, and shortest edge length. More...
 
- Protected Attributes inherited from Geo_Metric_Base_3
std::vector< Vector_3< double > > v
 
int _type
 
const COM::Pane * _ene_pane
 
int _ene_i
 

Detailed Description

3D Aspect Ratios Metric Class

Definition at line 107 of file Geometric_Metrics_3.h.

Constructor & Destructor Documentation

Aspect_Metric_3 ( )
inline

Initialize a 3D Aspect Metric.

Definition at line 111 of file Geometric_Metrics_3.h.

111 {}

Member Function Documentation

void compute ( double  atts[]) const
virtual

Calculate the metric value on this element.

Parameters
atts[]Computed value(s) placed here.

Note that R/r and R/l are only implemented for simplical elements. This method will return -1 for both metrics if used on a hexahedron.

Implements Metric.

Definition at line 261 of file Geometric_Metrics_3.C.

Referenced by main().

261  {
262  if (_type == COM::Connectivity::HEX8) {
263  atts[0] = -1;
264  atts[1] = -1;
265  }
266  else{
267  double R, r, l;
268  compute_aspects(R,r,l);
269  atts[0] = (r/R)*3.0;
270  atts[1] = (l/R)*.61237243569579447;
271  if(atts[0] > 1.0)
272  atts[0] = 1.0;
273  if(atts[1] > 1.0)
274  atts[0] = 1.0;
275  }
276 }
void compute_aspects(double &R, double &r, double &l) const
Compute circumradius, inradius, and shortest edge length.

Here is the caller graph for this function:

void getAspects ( double &  R,
double &  r,
double &  l 
)
inline

Get the geometric aspects.

Definition at line 130 of file Geometric_Metrics_3.h.

References Geo_Metric_Base_3::compute_aspects().

Referenced by Rocmop::add_aspect_ratios().

130  {
131  compute_aspects(R,r,l);
132  }
void compute_aspects(double &R, double &r, double &l) const
Compute circumradius, inradius, and shortest edge length.

Here is the call graph for this function:

Here is the caller graph for this function:

double maxValue ( ) const
virtual

Get the maximum value for this metric.

Reimplemented from Geo_Metric_Base_3.

Definition at line 278 of file Geometric_Metrics_3.C.

Referenced by main().

278  {
279  if (_type == COM::Connectivity::TET4) {
280  return 1.0;
281  }
282  else { return -1.0; }
283 }

Here is the caller graph for this function:

double minValue ( ) const
virtual

Get the minimum value for this metric.

Reimplemented from Geo_Metric_Base_3.

Definition at line 285 of file Geometric_Metrics_3.C.

Referenced by main().

285  {
286  if (_type == COM::Connectivity::TET4) {
287  return 0.0;
288  }
289  else { return -1.0; }
290 }

Here is the caller graph for this function:


The documentation for this class was generated from the following files: