FEAT 3
Finite Element Analysis Toolbox
Loading...
Searching...
No Matches
FEAT Namespace Reference

FEAT namespace. More...

Namespaces

namespace  Adjacency
 Adjacency namespace.
 
namespace  Analytic
 Analytic namespace.
 
namespace  Assembly
 Assembly namespace.
 
namespace  Control
 Control namespace.
 
namespace  Cubature
 Cubature namespace.
 
namespace  Dist
 Distributed Communication namespace.
 
namespace  Geometry
 Geometry namespace.
 
namespace  Global
 Global linear algebra namespace.
 
namespace  LAFEM
 LAFEM namespace.
 
namespace  Math
 FEAT Math namespace.
 
namespace  Meshopt
 Namespace for everything mesh optimizer related.
 
namespace  MetaMath
 Template Meta-Program Math namespace.
 
namespace  Pack
 Data Array Pack namespace.
 
namespace  Shape
 Shape namespace.
 
namespace  Solver
 Solver namespace.
 
namespace  Space
 Finite Element Space namespace.
 
namespace  TestSystem
 TestSystem namespace.
 
namespace  Tiny
 Tiny namespace.
 
namespace  Trafo
 Transformation namespace.
 
namespace  Type
 Type namespace.
 
namespace  VoxelAssembly
 Namespace for different voxel based assembly methods.
 
namespace  VoxelAssemblyPolicies
 Provides different policies for the voxel assembly kernels.
 
namespace  Windows
 Windows OS utility namespace.
 
namespace  Xml
 Xml namespace.
 

Classes

class  Backend
 Backend support class. More...
 
class  BinaryStream
 Binary Stream class. More...
 
class  DistFileIO
 Distributed File Input/Output class. More...
 
class  Exception
 Base exception class. More...
 
class  FileError
 Base class for file related errors. More...
 
class  FileNotCreated
 File-Not-Created exception. More...
 
class  FileNotFound
 File-Not-Found exception. More...
 
class  Hash
 
class  InternalError
 exception that is thrown if something that is never supposed to happen happens More...
 
class  KahanAccumulator
 Kahan Summation accumulator class template. More...
 
class  MemoryPool
 Memory management. More...
 
class  MemoryUsage
 Memory usage info object. More...
 
class  mutable_priority_queue
 
class  ParseError
 Class for parser related errors. More...
 
class  PropertyMap
 A class organizing a tree of key-value pairs. More...
 
class  Random
 Pseudo-Random Number Generator. More...
 
class  Runtime
 FEAT Runtime management class. More...
 
class  SimpleArgParser
 Simple argument parser implementation. More...
 
class  Statistics
 Statistics collection class. More...
 
class  StopWatch
 Stop-Watch class. More...
 
class  String
 String class implementation. More...
 
class  StringMapped
 String-Mapped class template. More...
 
class  SyntaxError
 Syntax Error exception class. More...
 
class  ThreadFence
 Thread fence synchronization utility class. More...
 
class  TimeStamp
 Time stamp class. More...
 

Typedefs

typedef __half Half
 Half data type. More...
 
typedef std::uint64_t Index
 Index data type. More...
 
typedef double Real
 Real data type. More...
 

Enumerations

enum class  PreferredBackend { generic = 0 , mkl , cuda }
 The backend that shall be used in all compute heavy calculations. More...
 
enum class  SpaceTags {
  none = 0 , value = 0x0001 , grad = 0x0002 , hess = 0x0004 ,
  ref_value = 0x0008 , ref_grad = 0x0010 , ref_hess = 0x0020
}
 Space configuration tags enum. More...
 
enum class  TimeFormat {
  h_m_s_m , h_m_s , m_s_m , m_s ,
  s_m
}
 
enum class  TrafoTags {
  none = 0 , dom_point = 0x0001 , img_point = 0x0002 , jac_mat = 0x0004 ,
  jac_inv = 0x0008 , jac_det = 0x0010 , hess_ten = 0x0020 , hess_inv = 0x0040 ,
  normal = 0x0080
}
 Trafo configuration tags enum. More...
 

Functions

PropertyMap_add_sections (PropertyMap *out, const std::deque< String > &deq)
 
void _treeify (PropertyMap *out, const PropertyMap *in)
 
CUDA_HOST_DEVICE void abortion (const char *const func, const char *const file, const int line, const char *const msg)
 Abortion function. More...
 
CUDA_HOST void abortion (const char *const func, const char *const file, const int line, const std::string &msg)
 
CUDA_HOST_DEVICE void assertion (bool expr, const char *const expr_str, const char *const func, const char *const file, const int line, const char *const msg=nullptr)
 Assertion function. More...
 
CUDA_HOST void assertion (bool expr, const char *const expr_str, const char *const func, const char *const file, const int line, const std::string &msg)
 
template<typename T_ >
void feat_omp_ex_scan (std::size_t n, const T_ x[], T_ y[])
 Computes an OpenMP-parallel exclusive scan a.k.a. a prefix sum of an array, i.e. More...
 
template<typename T_ >
void feat_omp_in_scan (std::size_t n, const T_ x[], T_ y[])
 Computes an OpenMP-parallel inclusive scan a.k.a. a prefix sum of an array, i.e. More...
 
static constexpr SpaceTags operator& (SpaceTags a, SpaceTags b)
 Binary AND operator for SpaceTags values. More...
 
static constexpr TrafoTags operator& (TrafoTags a, TrafoTags b)
 Binary AND operator for TrafoTags values. More...
 
static constexpr bool operator* (SpaceTags a)
 bool conversion operator More...
 
static constexpr bool operator* (TrafoTags a)
 bool conversion operator More...
 
std::ostream & operator<< (std::ostream &left, PreferredBackend value)
 
static constexpr SpaceTags operator| (SpaceTags a, SpaceTags b)
 Binary OR operator for SpaceTags values. More...
 
static constexpr TrafoTags operator| (TrafoTags a, TrafoTags b)
 Binary OR operator for TrafoTags values. More...
 
template<typename ValueType_ >
StringMapped< ValueType_ > string_mapped (ValueType_ &value, const std::map< String, ValueType_ > &value_map)
 Creates a StringMapped object. More...
 
template<typename ValueType_ >
bool string_mapped_lookup (ValueType_ &value, const std::map< String, ValueType_ > &value_map, const String &str)
 Looks up a StringMapped value. More...
 
template<typename T_ >
String stringify (const T_ &item)
 Converts an item into a String. More...
 
String stringify_bytes (std::uint64_t bytes, int precision=3, int width=7)
 Prints a byte size to a string using the common units Bytes, KiB, MiB, Gib, TiB or PiB. More...
 
template<typename DataType_ >
String stringify_fp_fix (DataType_ value, int precision=0, int width=0, bool sign=false)
 Prints a floating point value to a string in fixed-point notation. More...
 
template<typename DataType_ >
String stringify_fp_sci (DataType_ value, int precision=0, int width=0, bool sign=false)
 Prints a floating point value to a string in scientific notation. More...
 
template<typename Container_ >
String stringify_join (const Container_ &container, const String &delimiter="")
 Joins a sequence of strings. More...
 
template<typename Iterator_ >
String stringify_join (Iterator_ first, Iterator_ last, const String &delimiter="")
 Joins a sequence of strings. More...
 

Variables

static const std::uint32_t hash_crc32_table []
 
static constexpr int version_major = 3
 FEAT major version number. More...
 
static constexpr int version_minor = 2025
 FEAT minor version number. More...
 
static constexpr int version_patch = 10
 FEAT patch version number. More...
 

Detailed Description

FEAT namespace.

Typedef Documentation

◆ Half

typedef __half FEAT::Half

Half data type.

Half data type derived from nvidias cuda __half data type.

Todo:
add overloads/specializations in math.hpp for this type
Author
Dirk Ribbrock

Definition at line 25 of file half.hpp.

◆ Index

typedef std::uint64_t FEAT::Index

Index data type.

Definition at line 122 of file base_header.hpp.

◆ Real

typedef double FEAT::Real

Real data type.

Definition at line 128 of file base_header.hpp.

Enumeration Type Documentation

◆ PreferredBackend

enum class FEAT::PreferredBackend
strong

The backend that shall be used in all compute heavy calculations.

Enumerator
generic 

generic c++ code

mkl 

intel mkl blas library

cuda 

nvidia cuda gpgpu support

Definition at line 123 of file backend.hpp.

◆ SpaceTags

enum class FEAT::SpaceTags
strong

Space configuration tags enum.

This enumeration is used to specify the evaluation requirements for space evaluators. For this enumeration, the "binary" AND and OR operators are overloaded, so that the single enumeration values can be combined and masked using these operators.

Enumerator
value 

specifies whether the space should supply basis function values

grad 

specifies whether the space should supply basis function gradients

hess 

specifies whether the space should supply basis function hessians

ref_value 

specifies whether the space should supply reference basis function values

ref_grad 

specifies whether the space should supply reference basis function gradients

ref_hess 

specifies whether the space should supply reference basis function hessians

Definition at line 96 of file eval_tags.hpp.

◆ TimeFormat

enum class FEAT::TimeFormat
strong

Supported time string formatting.

Enumerator
h_m_s_m 

h:mm:ss.mmm

h_m_s 

h:mm:ss

m_s_m 

m:ss.mmm

m_s 

m:ss

s_m 

s.mmm

Definition at line 30 of file time_stamp.hpp.

◆ TrafoTags

enum class FEAT::TrafoTags
strong

Trafo configuration tags enum.

This enumeration is used to specify the evaluation requirements for transformation evaluators. For this enumeration, the "binary" AND and OR operators are overloaded, so that the single enumeration values can be combined and masked using these operators.

Enumerator
dom_point 

specifies whether the trafo should supply domain point coordinates

img_point 

specifies whether the trafo should supply image point coordinates

jac_mat 

specifies whether the trafo should supply jacobian matrices

jac_inv 

specifies whether the trafo should supply inverse jacobian matrices

jac_det 

specifies whether the trafo should supply jacobian determinants

hess_ten 

specifies whether the trafo should supply hessian tensors

hess_inv 

specifies whether the trafo should supply inverse hessian tensors

normal 

specifies whether the trafo should supply outer normal vectors note: The normal vector is always automatically defined by the Assembly::TraceAssembler class and does not have to be specifies explicitly

Definition at line 21 of file eval_tags.hpp.

Function Documentation

◆ _add_sections()

PropertyMap * FEAT::_add_sections ( PropertyMap out,
const std::deque< String > &  deq 
)

Definition at line 495 of file property_map.cpp.

◆ _treeify()

void FEAT::_treeify ( PropertyMap out,
const PropertyMap in 
)

Definition at line 504 of file property_map.cpp.

◆ abortion() [1/2]

CUDA_HOST_DEVICE void FEAT::abortion ( const char *const  func,
const char *const  file,
const int  line,
const char *const  msg 
)
inline

Abortion function.

This function implements the actual abortion that is called by the XABORTM macro, which prints an informative error message to stderr and calls Runtime::abort to terminate the process.

Parameters
[in]funcThe name of the function that contains the abortion, usually func.
[in]fileThe name of the source/header file that contains the abortion, usually FILE.
[in]lineThe line number of the abortion in the source/header file, usually LINE.
[in]msgA custom error message to be displayed in addition to the standard information.

Definition at line 38 of file assertion.hpp.

References FEAT::Runtime::abort().

◆ abortion() [2/2]

CUDA_HOST void FEAT::abortion ( const char *const  func,
const char *const  file,
const int  line,
const std::string &  msg 
)
inline

Definition at line 79 of file assertion.hpp.

◆ assertion() [1/2]

CUDA_HOST_DEVICE void FEAT::assertion ( bool  expr,
const char *const  expr_str,
const char *const  func,
const char *const  file,
const int  line,
const char *const  msg = nullptr 
)
inline

Assertion function.

This function implements the actual assertion that is called by the ASSERT, ASSERTM, XASSERT and XASSERTM macros.

The behavior of this function is as follows:

  • If expr evaluates to true, then this function does nothing.
  • If expr evaluates to false, then this function prints an informative error message to stderr and calls Runtime::abort to terminate the process.
Parameters
[in]exprThe expression that is asserted.
[in]expr_strThe stringified expression, usually #expr.
[in]funcThe name of the function that contains the assertion, usually func.
[in]fileThe name of the source/header file that contains the assertion, usually FILE.
[in]lineThe line number of the assertion in the source/header file, usually LINE.
[in]msgA custom error message to be displayed in addition to the standard information. May be nullptr if no additional information is available for the assertion.

Definition at line 114 of file assertion.hpp.

References FEAT::Runtime::abort().

◆ assertion() [2/2]

CUDA_HOST void FEAT::assertion ( bool  expr,
const char *const  expr_str,
const char *const  func,
const char *const  file,
const int  line,
const std::string &  msg 
)
inline

Definition at line 163 of file assertion.hpp.

◆ feat_omp_ex_scan()

template<typename T_ >
void FEAT::feat_omp_ex_scan ( std::size_t  n,
const T_  x[],
T_  y[] 
)

Computes an OpenMP-parallel exclusive scan a.k.a. a prefix sum of an array, i.e.

\[ y_k := \sum_{i=0}^{k-1} x_i \]

Note
The temporary memory requirement of this function is O(P), where P is the number of threads.
Parameters
[in]nThe length of x and y, respectively.
[in]xThe array whose exclusive scan / prefix sums are to be computed; may be identical to y.
[out]yThe array that should receive the exclusive scan / prefix sums of x; may be identical to x.

Definition at line 125 of file omp_util.hpp.

References XASSERT.

◆ feat_omp_in_scan()

template<typename T_ >
void FEAT::feat_omp_in_scan ( std::size_t  n,
const T_  x[],
T_  y[] 
)

Computes an OpenMP-parallel inclusive scan a.k.a. a prefix sum of an array, i.e.

\[ y_k := \sum_{i=0}^k x_i \]

Note
The temporary memory requirement of this function is O(P), where P is the number of threads.
Parameters
[in]nThe length of x and y, respectively.
[in]xThe array whose inclusive scan / prefix sums are to be computed; may be identical to y.
[out]yThe array that should receive the inclusive scan / prefix sums of x; may be identical to x.

Definition at line 35 of file omp_util.hpp.

References XASSERT.

Referenced by FEAT::Space::DofMappingRenderer::render().

◆ operator&() [1/2]

static constexpr SpaceTags FEAT::operator& ( SpaceTags  a,
SpaceTags  b 
)
inlinestaticconstexpr

Binary AND operator for SpaceTags values.

Parameters
[in]a,bThe two SpaceTags values that are to be AND'ed.
Returns
The masked tags of a and b.

Definition at line 136 of file eval_tags.hpp.

◆ operator&() [2/2]

static constexpr TrafoTags FEAT::operator& ( TrafoTags  a,
TrafoTags  b 
)
inlinestaticconstexpr

Binary AND operator for TrafoTags values.

Parameters
[in]a,bThe two TrafoTags values that are to be AND'ed.
Returns
The masked tags of a and b.

Definition at line 67 of file eval_tags.hpp.

◆ operator*() [1/2]

static constexpr bool FEAT::operator* ( SpaceTags  a)
inlinestaticconstexpr

bool conversion operator

Parameters
[in]aThe SpaceTags value that is to be checked.
Returns
false, if a is SpaceTags::none, otherwise true.

Definition at line 150 of file eval_tags.hpp.

◆ operator*() [2/2]

static constexpr bool FEAT::operator* ( TrafoTags  a)
inlinestaticconstexpr

bool conversion operator

Parameters
[in]aThe TrafoTags value that is to be checked.
Returns
false, if a is TrafoTags::none, otherwise true.

Definition at line 81 of file eval_tags.hpp.

◆ operator<<()

std::ostream & FEAT::operator<< ( std::ostream &  left,
PreferredBackend  value 
)

Definition at line 32 of file backend.cpp.

◆ operator|() [1/2]

static constexpr SpaceTags FEAT::operator| ( SpaceTags  a,
SpaceTags  b 
)
inlinestaticconstexpr

Binary OR operator for SpaceTags values.

Parameters
[in]a,bThe two SpaceTags values that are to be OR'ed.
Returns
The combined tags of a and b.

Definition at line 122 of file eval_tags.hpp.

◆ operator|() [2/2]

static constexpr TrafoTags FEAT::operator| ( TrafoTags  a,
TrafoTags  b 
)
inlinestaticconstexpr

Binary OR operator for TrafoTags values.

Parameters
[in]a,bThe two TrafoTags values that are to be OR'ed.
Returns
The combined tags of a and b.

Definition at line 53 of file eval_tags.hpp.

◆ string_mapped()

template<typename ValueType_ >
StringMapped< ValueType_ > FEAT::string_mapped ( ValueType_ &  value,
const std::map< String, ValueType_ > &  value_map 
)
inline

Creates a StringMapped object.

Parameters
[in]valueA reference to the value to be looked up.
[in]value_mapA const reference to the value map to be used for lookup.
Returns
A StringMapped<ValueType_> object.

Definition at line 162 of file string_mapped.hpp.

References value.

Referenced by string_mapped_lookup().

◆ string_mapped_lookup()

template<typename ValueType_ >
bool FEAT::string_mapped_lookup ( ValueType_ &  value,
const std::map< String, ValueType_ > &  value_map,
const String str 
)
inline

Looks up a StringMapped value.

Parameters
[in]valueA reference to the value to be looked up.
[in]value_mapA const reference to the value map to be used for lookup.
[in]strThe string to be looked up.
Returns
true, if str was found in the value map, otherwise false.

Definition at line 183 of file string_mapped.hpp.

References string_mapped(), and value.

◆ stringify()

template<typename T_ >
String FEAT::stringify ( const T_ &  item)
inline

Converts an item into a String.

Template Parameters
T_The type of the item to be converted.
Parameters
[in]itemA transient reference to the item that is to be converted.
Returns
A String representation of the item.

Definition at line 944 of file string.hpp.

Referenced by FEAT::Solver::BiCGStabL< Matrix_, Filter_ >::BiCGStabL(), FEAT::Solver::Descent< Matrix_, Filter_ >::Descent(), FEAT::Solver::QPenalty< Functional_ >::_apply_intern(), FEAT::Solver::Linesearch< Functional_, Filter_ >::_check_convergence(), FEAT::Control::Domain::VoxelDomainControl< DomainLevel_ >::_deslag_patch_halos(), FEAT::Solver::IterativeSolver< Vector_ >::_plot_iter_line(), FEAT::DistFileIO::_rankname(), FEAT::Solver::QPenalty< Functional_ >::_set_initial_defect(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::_set_initial_defect(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::_set_new_defect(), FEAT::Solver::Linesearch< Functional_, Filter_ >::_startup(), FEAT::Dist::Comm::allprint(), FEAT::Solver::NLCG< Functional_, Filter_ >::compute_beta(), FEAT::Control::Meshopt::MeshoptControlBase< DomainControl_ >::compute_mesh_quality(), FEAT::Cubature::DriverFactory< Driver_, Shape_, true >::create(), FEAT::Cubature::Scalar::DriverFactory< Driver_, true >::create(), FEAT::Assembly::DomainAssembler< Trafo_ >::dump(), FEAT::Control::Domain::PartiDomainControlBase< DomainLevel_ >::dump_ancestry(), FEAT::Control::Domain::VoxelDomainControl< DomainLevel_ >::dump_slag_layer_levels(), FEAT::Geometry::VoxelMap::export_to_bmp(), FEAT::Geometry::RootMeshNode< RootMesh_ >::extract_patch(), FEAT::Geometry::PatchPartMap::fill_index_set(), FEAT::Geometry::Atlas::SurfaceMesh< Mesh_ >::find_cell(), FEAT::Control::Domain::PartiDomainControlBase< DomainLevel_ >::format_chosen_levels(), FEAT::Control::Domain::PartiDomainControlBase< DomainLevel_ >::format_desired_levels(), FEAT::Control::Domain::PartiDomainControlBase< DomainLevel_ >::get_chosen_parti_info(), FEAT::Statistics::get_formatted_flops(), FEAT::MemoryUsage::get_formatted_memory_usage(), FEAT::Statistics::get_formatted_solver_internals(), FEAT::Statistics::get_formatted_times(), FEAT::Solver::IterativeSolver< Vector_ >::get_summary(), FEAT::Solver::Linesearch< Functional_, Filter_ >::get_summary(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::get_summary(), FEAT::Meshopt::HyperelasticityFunctional< DT_, IT_, Trafo_, CellFunctionalType_, RefCellTrafo_ >::info(), FEAT::Meshopt::ConcentrationFunctionDefault< DT_ >::info(), FEAT::Meshopt::ConcentrationFunctionPowOfDist< DT_ >::info(), FEAT::Control::Meshopt::DuDvFunctionalControl< DT_, IT_, DomainControl_ >::info(), FEAT::Control::Meshopt::HyperelasticityFunctionalControl< DT_, IT_, DomainControl_, Hyperelasticity_ >::info(), FEAT::Meshopt::HyperelasticityFunctional< DT_, IT_, Trafo_, CellFunctionalType_, RefCellTrafo_ >::init_pre_sync(), FEAT::Pack::lossy_decode(), FEAT::Geometry::ConformalMesh< Shape_, num_coords_, Coord_ >::name(), FEAT::Geometry::IndexCalculator< Shape_, face_dim_ >::name(), FEAT::Geometry::IndexSet< num_indices_ >::name(), FEAT::LAFEM::PowerColMatrix< SubType_, blocks_ >::name(), FEAT::LAFEM::PowerDiagMatrix< SubType_, blocks_ >::name(), FEAT::LAFEM::PowerFullMatrix< SubType_, width_, height_ >::name(), FEAT::LAFEM::PowerRowMatrix< SubType_, blocks_ >::name(), FEAT::LAFEM::PowerVector< SubType_, count_ >::name(), FEAT::Shape::Simplex< dimension_ >::name(), FEAT::Shape::Hypercube< dimension_ >::name(), FEAT::Solver::MultiGrid< SystemMatrix_, SystemFilter_, TransferOperator_ >::name(), FEAT::Geometry::operator<<(), FEAT::Analytic::ParsedVectorFunction< dom_dim_, img_dim_ >::parse(), FEAT::Meshopt::HyperelasticityFunctional< DT_, IT_, Trafo_, CellFunctionalType_, RefCellTrafo_ >::prepare_pre_sync(), FEAT::Statistics::print_solver_expressions(), FEAT::Geometry::SchneidersData::raw_templates(), FEAT::Geometry::SunZhaoMaData::raw_templates(), FEAT::Geometry::SunZhaoMaExpansionData::raw_templates(), FEAT::Geometry::TwoRefinementData::raw_templates(), FEAT::PropertyMap::read(), FEAT::Geometry::VoxelMap::read(), FEAT::DistFileIO::read_combined(), FEAT::LAFEM::PowerVector< SubType_, count_ >::read_from(), FEAT::Geometry::VoxelMap::render_to_bmp(), FEAT::Control::Time::NvsBdfQ< DT_ >::set_coeffs(), FEAT::Control::Domain::PartiDomainControlBase< DomainLevel_ >::set_desired_levels(), FEAT::Solver::ALGLIBMinCG< Functional_, Filter_ >::set_direction_update(), FEAT::Geometry::TemplateBuilder< RawData_ >::stats(), stringify_bytes(), stringify_join(), FEAT::Geometry::ExportVTK< Mesh_, cell_dim_ >::write(), FEAT::LAFEM::TupleDiagMatrix< First_, Rest_ >::write_out_submatrices(), FEAT::LAFEM::PowerColMatrix< SubType_, blocks_ >::write_out_submatrices(), FEAT::LAFEM::PowerDiagMatrix< SubType_, blocks_ >::write_out_submatrices(), FEAT::LAFEM::PowerRowMatrix< SubType_, blocks_ >::write_out_submatrices(), and FEAT::Geometry::ExportVTK< Mesh_, cell_dim_ >::write_pvtu().

◆ stringify_bytes()

String FEAT::stringify_bytes ( std::uint64_t  bytes,
int  precision = 3,
int  width = 7 
)
inline

Prints a byte size to a string using the common units Bytes, KiB, MiB, Gib, TiB or PiB.

The output unit is chosen based in the input value bytes in a way, so that there are at most 3 leading digits and for any size >= 1000 bytes, and the output will contain as many digits as were specified by the precision parameter and it will be padded to the right to as many characters as specified by the width parameter excluding the unit postfix. For example, the well-known HD 3.5" floppy disk has a size of 1457664 bytes, which results in an output of " 1.390 MiB", and a standard CD-ROM has a size of 681574400 bytes, which results in an output of "650.000 MiB".

Parameters
[in]bytesThe size in bytes that is to be printed
[in]precisionThe number of decimal places to be printed; defaults to 3.
If set to 0, the default (compiler-dependent) precision will be used.
[in]widthThe width that is to be used, i.e. the total number of characters to be printed for the number excluding the unit postfix. This defaults to 7, which ensures that output will be properly aligned independent of the number of digits and the selected unit.
If set to 0, the default (compiler-dependent) width will be used.
Returns
A String containing the size in the largest sensible unit for the given size.

Definition at line 1261 of file string.hpp.

References FEAT::String::pad_front(), stringify(), and stringify_fp_fix().

Referenced by FEAT::MemoryUsage::format_peak_physical_usage().

◆ stringify_fp_fix()

template<typename DataType_ >
String FEAT::stringify_fp_fix ( DataType_  value,
int  precision = 0,
int  width = 0,
bool  sign = false 
)
inline

Prints a floating point value to a string in fixed-point notation.

Template Parameters
DataType_The data type of the value to be printed. Is silently assumed to be a standard floating-point datatype, i.e. either float, double or long double.
Note
There exists an overload of this function for the __float128 data type if FEAT is configured and build with support for the quadmath library.
Parameters
[in]valueThe floating-point value that is to be printed.
[in]precisionThe precision that is to be used, i.e. the number of mantissa digits to be printed.
If set to 0, the default (compiler-dependent) precision will be used.
[in]widthThe width that is to be used, i.e. the total number of characters to be printed.
If set to 0, the default (compiler-dependent) width will be used.
[in]signSpecifies whether non-negative numbers are to be prefixed by '+'.
Returns
A String containing the value of value in fixed-point notation.
Author
Peter Zajac

Definition at line 1142 of file string.hpp.

References value.

Referenced by FEAT::Global::PMDCDSCMatrix< Global::Matrix< LAFEM::SparseMatrixBCSR< DT_, IT_, dim_, 1 >, MirrorV_, MirrorP_ >, Global::Matrix< LAFEM::SparseMatrixBCSR< DT_, IT_, 1, dim_ >, MirrorP_, MirrorV_ > >::_fmt_time(), FEAT::Solver::IterativeSolver< Vector_ >::_plot_iter_line(), FEAT::Assembly::DomainAssembler< Trafo_ >::dump(), FEAT::Solver::IterativeSolver< Vector_ >::get_summary(), FEAT::StopWatch::percent_of(), and stringify_bytes().

◆ stringify_fp_sci()

template<typename DataType_ >
String FEAT::stringify_fp_sci ( DataType_  value,
int  precision = 0,
int  width = 0,
bool  sign = false 
)
inline

Prints a floating point value to a string in scientific notation.

Template Parameters
DataType_The data type of the value to be printed. Is silently assumed to be a standard floating-point datatype, i.e. either float, double or long double.
Note
There exists an overload of this function for the __float128 data type if FEAT is configured and build with support for the quadmath library.
Parameters
[in]valueThe floating-point value that is to be printed.
[in]precisionThe precision that is to be used, i.e. the number of mantissa digits to be printed.
If set to 0, the default (compiler-dependent) precision will be used.
[in]widthThe width that is to be used, i.e. the total number of characters to be printed.
If set to 0, the default (compiler-dependent) width will be used.
[in]signSpecifies whether non-negative numbers are to be prefixed by '+'.
Returns
A String containing the value of value in scientific notation.
Author
Peter Zajac

Definition at line 1088 of file string.hpp.

References value.

Referenced by FEAT::Solver::QPenalty< Functional_ >::_apply_intern(), FEAT::Solver::Linesearch< Functional_, Filter_ >::_check_convergence(), FEAT::Solver::IterativeSolver< Vector_ >::_plot_iter_line(), FEAT::Solver::QPenalty< Functional_ >::_set_initial_defect(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::_set_initial_defect(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::_set_new_defect(), FEAT::Solver::Linesearch< Functional_, Filter_ >::_startup(), FEAT::Assembly::VelocityInfo< DataType_, dim_ >::format_string(), FEAT::Assembly::ScalarErrorInfo< DataType_ >::format_string(), FEAT::Assembly::VectorErrorInfo< DataType_, dim_ >::format_string(), FEAT::Solver::IterativeSolver< Vector_ >::get_summary(), FEAT::Solver::Linesearch< Functional_, Filter_ >::get_summary(), FEAT::Solver::NLOptLS< Functional_, Filter_ >::get_summary(), FEAT::Meshopt::ConcentrationFunctionPowOfDist< DT_ >::info(), FEAT::Meshopt::RumpfFunctionalBase< DataType_ >::info(), FEAT::Meshopt::HyperelasticityFunctional< DT_, IT_, Trafo_, CellFunctionalType_, RefCellTrafo_ >::init_pre_sync(), FEAT::Meshopt::HyperelasticityFunctional< DT_, IT_, Trafo_, CellFunctionalType_, RefCellTrafo_ >::prepare_pre_sync(), FEAT::LAFEM::DenseMatrix< DT_, IT_ >::write_out(), FEAT::LAFEM::DenseVector< DT_, IT_ >::write_out(), FEAT::LAFEM::DenseVectorBlocked< DT_, IT_, BlockSize_ >::write_out(), FEAT::LAFEM::SparseMatrixBCSR< DT_, IT_, BlockHeight_, BlockWidth_ >::write_out(), FEAT::LAFEM::SparseVector< DT_, IT_ >::write_out(), FEAT::LAFEM::SparseVectorBlocked< DT_, IT_, BlockSize_ >::write_out(), FEAT::LAFEM::SparseMatrixCSR< DT_, IT_ >::write_out(), and FEAT::Geometry::ExportVTK< Mesh_, cell_dim_ >::write_vtu().

◆ stringify_join() [1/2]

template<typename Container_ >
String FEAT::stringify_join ( const Container_ &  container,
const String delimiter = "" 
)

Joins a sequence of strings.

This method joins a sequence of items given by a container, e.g. std::list<double>, separating each item in the container by a delimiter string.

Parameters
[in]containerA container representing the item sequence. Each item referenced of the container is converted via the stringify function.
[in]delimiterA string acting as a delimiter.
Returns
A String containing the stringified items.

Definition at line 1050 of file string.hpp.

References stringify_join().

◆ stringify_join() [2/2]

template<typename Iterator_ >
String FEAT::stringify_join ( Iterator_  first,
Iterator_  last,
const String delimiter = "" 
)

Joins a sequence of strings.

This functions joins a sequence of items given by two input iterators, separating them by a delimiter string.

Parameters
[in]first,lastTwo forward iterators representing the item sequence. Each item referenced by the iterators is converted via the stringify function.
[in]delimiterA string acting as a delimiter.
Returns
A String containing the stringified items.

Definition at line 1017 of file string.hpp.

References FEAT::String::String(), and stringify().

Referenced by stringify_join().

Variable Documentation

◆ hash_crc32_table

const std::uint32_t FEAT::hash_crc32_table[]
static

Definition at line 11 of file hash.cpp.

◆ version_major

◆ version_minor

◆ version_patch