Common class#

template<class T>
struct add_pointer#
#include <variant_lite.hpp>

Public Types

typedef remove_reference<T>::type *type#
struct aligned_storage_t#
#include <optional_lite.hpp>

Public Members

align_as_type data[1 + (sizeof(value_type) - 1) / sizeof(align_as_type)]#
union aligned_storage_t#

Public Members

align_as_type data[1 + (data_size - 1) / sizeof(align_as_type)]#
template<size_t A, size_t S>
struct alignment_logic#
#include <optional_lite.hpp>

Public Types

Values:

template<size_t A, size_t S>
struct alignment_logic#
#include <variant_lite.hpp>

Public Types

enum V#

Values:

template<typename T>
struct alignment_of#
#include <optional_lite.hpp>

Public Types

Values:

enumerator value#
template<typename T>
struct alignment_of#
#include <variant_lite.hpp>

Public Types

enum V#

Values:

enumerator value#
template<typename T>
struct alignment_of_hack#
#include <optional_lite.hpp>

Public Functions

alignment_of_hack()#

Public Members

char c#
T t#
template<typename T>
struct alignment_of_hack#
#include <variant_lite.hpp>

Public Functions

alignment_of_hack()#

Public Members

char c#
T t#
class AsciiDocExporter : public tabulate::Exporter#

Public Functions

inline virtual std::string dump(Table &table) override#
inline virtual ~AsciiDocExporter()#

Private Functions

inline std::string add_formatted_cell(Cell &cell) const#
inline std::string add_alignment_header(Table &table)#

Private Static Attributes

static const char new_line = '\n'#
class Cell#
#include <cell.hpp>

Public Functions

inline explicit Cell(std::shared_ptr<class Row> parent)#
inline void set_text(const std::string &text)#
inline const std::string &get_text()#
inline size_t size()#
inline std::string locale()#
inline Format &format()#
inline bool is_multi_byte_character_support_enabled()#

Private Members

std::string data_#
std::weak_ptr<class Row> parent_#
optional<Format> format_#
class CellIterator#
#include <column.hpp>

Public Functions

inline explicit CellIterator(std::vector<std::reference_wrapper<Cell>>::iterator ptr)#
inline CellIterator operator++()#
inline bool operator!=(const CellIterator &other) const#
inline Cell &operator*()#

Private Members

std::vector<std::reference_wrapper<Cell>>::iterator ptr#
class CellIterator#
#include <row.hpp>

Public Functions

inline explicit CellIterator(std::vector<std::shared_ptr<Cell>>::iterator ptr)#
inline CellIterator operator++()#
inline bool operator!=(const CellIterator &other) const#
inline Cell &operator*()#

Private Members

std::vector<std::shared_ptr<Cell>>::iterator ptr#
class Column#
#include <column.hpp>

Public Functions

inline explicit Column(std::shared_ptr<class TableInternal> parent)#
inline void add_cell(Cell &cell)#
inline Cell &operator[](size_t index)#
inline std::vector<std::reference_wrapper<Cell>> cells() const#
inline size_t size() const#
inline ColumnFormat format()#
inline auto begin() -> CellIterator#
inline auto end() -> CellIterator#

Private Functions

inline size_t get_configured_width()#
inline size_t get_computed_width()#
inline size_t get_cell_width(size_t cell_index)#

Private Members

std::vector<std::reference_wrapper<Cell>> cells_#
std::weak_ptr<class TableInternal> parent_#

Friends

friend class ColumnFormat
friend class Printer
class ColumnFormat : public tabulate::Format#
#include <column_format.hpp>

Public Functions

inline explicit ColumnFormat(class Column &column)#
inline ColumnFormat &width(size_t value)#
inline ColumnFormat &height(size_t value)#
inline ColumnFormat &padding(size_t value)#
inline ColumnFormat &padding_left(size_t value)#
inline ColumnFormat &padding_right(size_t value)#
inline ColumnFormat &padding_top(size_t value)#
inline ColumnFormat &padding_bottom(size_t value)#
inline ColumnFormat &border(const std::string &value)#
inline ColumnFormat &border_color(Color value)#
inline ColumnFormat &border_background_color(Color value)#
inline ColumnFormat &border_left(const std::string &value)#
inline ColumnFormat &border_left_color(Color value)#
inline ColumnFormat &border_left_background_color(Color value)#
inline ColumnFormat &border_right(const std::string &value)#
inline ColumnFormat &border_right_color(Color value)#
inline ColumnFormat &border_right_background_color(Color value)#
inline ColumnFormat &border_top(const std::string &value)#
inline ColumnFormat &border_top_color(Color value)#
inline ColumnFormat &border_top_background_color(Color value)#
inline ColumnFormat &border_bottom(const std::string &value)#
inline ColumnFormat &border_bottom_color(Color value)#
inline ColumnFormat &border_bottom_background_color(Color value)#
inline ColumnFormat &corner(const std::string &value)#
inline ColumnFormat &corner_color(Color value)#
inline ColumnFormat &corner_background_color(Color value)#
inline ColumnFormat &column_separator(const std::string &value)#
inline ColumnFormat &column_separator_color(Color value)#
inline ColumnFormat &column_separator_background_color(Color value)#
inline ColumnFormat &font_align(FontAlign value)#
inline ColumnFormat &font_style(const std::vector<FontStyle> &style)#
inline ColumnFormat &font_color(Color value)#
inline ColumnFormat &font_background_color(Color value)#
inline ColumnFormat &color(Color value)#
inline ColumnFormat &background_color(Color value)#
inline ColumnFormat &multi_byte_characters(bool value)#
inline ColumnFormat &locale(const std::string &value)#

Private Members

std::reference_wrapper<class Column> column_#
template<class Variant>
struct Comparator#
#include <variant_lite.hpp>

Public Static Functions

static inline bool equal(Variant const &v, Variant const &w)#
static inline bool less_than(Variant const &v, Variant const &w)#
template<bool B, typename T, typename F>
struct conditional#
#include <optional_lite.hpp>

Public Types

typedef T type#
template<bool Cond, class Then, class Else>
struct conditional#
template<typename T, typename F>
struct conditional<false, T, F>#
#include <optional_lite.hpp>

Public Types

typedef F type#
template<class Then, class Else>
struct conditional<false, Then, Else>#
#include <variant_lite.hpp>

Public Types

typedef Else type#
template<class Then, class Else>
struct conditional<true, Then, Else>#
#include <variant_lite.hpp>

Public Types

typedef Then type#
class csvfile#
#include <csvfile.h>

Public Functions

inline csvfile(const std::string filename, const std::string separator = ";")#
inline ~csvfile()#
inline void flush()#
inline void endrow()#
inline csvfile &operator<<(csvfile &(*val)(csvfile&))#
inline csvfile &operator<<(const char *val)#
inline csvfile &operator<<(const std::string &val)#
template<typename T>
inline csvfile &operator<<(const T &val)#

Private Functions

template<typename T>
inline csvfile &write(const T &val)#
inline std::string escape(const std::string &val)#

Private Members

std::ofstream fs_#
bool is_first_#
const std::string separator_#
const std::string escape_seq_#
const std::string special_chars_#
struct energy_type#
#include <openfdem_general.h>

Public Functions

inline energy_type()#

Public Members

Real external_work = 0.0#
Real internal_energy = 0.0#
Real gravity_energy = 0.0#
Real kinetic_energy = 0.0#
Real damping_energy = 0.0#
Real absorbing_energy = 0.0#
Real contactFrictionEnergy = 0.0#
Real contactNormalEnergy = 0.0#
Real element_energy = 0.0#
Real cohesive_energy = 0.0#
Real kinetic_ratio = 0.0#
class Exporter#
#include <exporter.hpp>

Subclassed by tabulate::AsciiDocExporter, tabulate::LatexExporter, tabulate::MarkdownExporter

Public Functions

virtual std::string dump(Table &table) = 0#
inline virtual ~Exporter()#
class ExportOptions#
#include <latex_exporter.hpp>

Public Functions

inline ExportOptions &indentation(std::size_t value)#

Private Members

optional<size_t> indentation_#

Friends

friend class LatexExporter
class Format#
#include <format.hpp>

Subclassed by tabulate::ColumnFormat

Public Functions

inline Format &width(size_t value)#
inline Format &height(size_t value)#
inline Format &padding(size_t value)#
inline Format &padding_left(size_t value)#
inline Format &padding_right(size_t value)#
inline Format &padding_top(size_t value)#
inline Format &padding_bottom(size_t value)#
inline Format &border(const std::string &value)#
inline Format &border_color(Color value)#
inline Format &border_background_color(Color value)#
inline Format &border_left(const std::string &value)#
inline Format &border_left_color(Color value)#
inline Format &border_left_background_color(Color value)#
inline Format &border_right(const std::string &value)#
inline Format &border_right_color(Color value)#
inline Format &border_right_background_color(Color value)#
inline Format &border_top(const std::string &value)#
inline Format &border_top_color(Color value)#
inline Format &border_top_background_color(Color value)#
inline Format &border_bottom(const std::string &value)#
inline Format &border_bottom_color(Color value)#
inline Format &border_bottom_background_color(Color value)#
inline Format &show_border()#
inline Format &hide_border()#
inline Format &show_border_top()#
inline Format &hide_border_top()#
inline Format &show_border_bottom()#
inline Format &hide_border_bottom()#
inline Format &show_border_left()#
inline Format &hide_border_left()#
inline Format &show_border_right()#
inline Format &hide_border_right()#
inline Format &corner(const std::string &value)#
inline Format &corner_color(Color value)#
inline Format &corner_background_color(Color value)#
inline Format &corner_top_left(const std::string &value)#
inline Format &corner_top_left_color(Color value)#
inline Format &corner_top_left_background_color(Color value)#
inline Format &corner_top_right(const std::string &value)#
inline Format &corner_top_right_color(Color value)#
inline Format &corner_top_right_background_color(Color value)#
inline Format &corner_bottom_left(const std::string &value)#
inline Format &corner_bottom_left_color(Color value)#
inline Format &corner_bottom_left_background_color(Color value)#
inline Format &corner_bottom_right(const std::string &value)#
inline Format &corner_bottom_right_color(Color value)#
inline Format &corner_bottom_right_background_color(Color value)#
inline Format &column_separator(const std::string &value)#
inline Format &column_separator_color(Color value)#
inline Format &column_separator_background_color(Color value)#
inline Format &font_align(FontAlign value)#
inline Format &font_style(const std::vector<FontStyle> &style)#
inline Format &font_color(Color value)#
inline Format &font_background_color(Color value)#
inline Format &color(Color value)#
inline Format &background_color(Color value)#
inline Format &multi_byte_characters(bool value)#
inline Format &locale(const std::string &value)#

Public Static Functions

static inline std::string word_wrap(const std::string &str, size_t width, const std::string &locale, bool is_multi_byte_character_support_enabled)#
static inline std::vector<std::string> split_lines(const std::string &text, const std::string &delimiter, const std::string &locale, bool is_multi_byte_character_support_enabled)#
static inline Format merge(Format first, Format second)#

Private Functions

inline void set_defaults()#

Private Members

optional<size_t> width_ = {}#
optional<size_t> height_ = {}#
optional<FontAlign> font_align_ = {}#
optional<std::vector<FontStyle>> font_style_ = {}#
optional<Color> font_color_ = {}#
optional<Color> font_background_color_ = {}#
optional<size_t> padding_left_ = {}#
optional<size_t> padding_top_ = {}#
optional<size_t> padding_right_ = {}#
optional<size_t> padding_bottom_ = {}#
optional<bool> show_border_top_ = {}#
optional<std::string> border_top_ = {}#
optional<Color> border_top_color_ = {}#
optional<Color> border_top_background_color_ = {}#
optional<bool> show_border_bottom_ = {}#
optional<std::string> border_bottom_ = {}#
optional<Color> border_bottom_color_ = {}#
optional<Color> border_bottom_background_color_ = {}#
optional<bool> show_border_left_ = {}#
optional<std::string> border_left_ = {}#
optional<Color> border_left_color_ = {}#
optional<Color> border_left_background_color_ = {}#
optional<bool> show_border_right_ = {}#
optional<std::string> border_right_ = {}#
optional<Color> border_right_color_ = {}#
optional<Color> border_right_background_color_ = {}#
optional<std::string> corner_top_left_ = {}#
optional<Color> corner_top_left_color_ = {}#
optional<Color> corner_top_left_background_color_ = {}#
optional<std::string> corner_top_right_ = {}#
optional<Color> corner_top_right_color_ = {}#
optional<Color> corner_top_right_background_color_ = {}#
optional<std::string> corner_bottom_left_ = {}#
optional<Color> corner_bottom_left_color_ = {}#
optional<Color> corner_bottom_left_background_color_ = {}#
optional<std::string> corner_bottom_right_ = {}#
optional<Color> corner_bottom_right_color_ = {}#
optional<Color> corner_bottom_right_background_color_ = {}#
optional<std::string> column_separator_ = {}#
optional<Color> column_separator_color_ = {}#
optional<Color> column_separator_background_color_ = {}#
optional<bool> multi_byte_characters_ = {}#
optional<std::string> locale_ = {}#

Private Static Functions

static inline std::string trim_left(const std::string &input_string)#
static inline std::string trim_right(const std::string &input_string)#
static inline std::string trim(const std::string &input_string)#
static inline size_t index_of_any(const std::string &input, size_t start_index, const std::vector<std::string> &split_characters)#
static inline std::vector<std::string> explode_string(const std::string &input, const std::vector<std::string> &split_characters)#

Friends

friend class Cell
friend class Row
friend class Column
friend class TableInternal
friend class Printer
friend class MarkdownExporter
friend class LatexExporter
friend class AsciiDocExporter
struct General_structure#
#include <openfdem_general.h>

Public Functions

void resize(Int size, Int initialsize = 0)#
void clear()#

Public Members

char RunTime[Openfdem_ARGC_LENGTH] = "\0"#
char InputFileName[Openfdem_ARGC_LENGTH] = "\0"#
char save_path[Openfdem_ARGC_LENGTH] = "\0"#
char save_filename[Openfdem_ARGC_LENGTH] = "\0"#
FILE *inputfile = nullptr#
FILE *logfile = nullptr#
FILE *FilePointer[Openfdem_FILE_LIMIT]#
short FileID = 0#
Int thread = 1#
Int TotalStep = 0#
Int NowStep = 0#
Int ShowIntervalonScreen = 2000#
Int ShowIntervalinLog = 2000#
Int remeshinterval = 0#
Int inletInterval = 0#
Int nodebeforeRead = 0#
Real TimeStep = 0.0#
Real Creepdt = 0.0#
Real CurrentTime = 0.0#
Real remeshTime = 0.0#
Real global_damp = 0.7#
Real massScale = 1.0#
Real solveratio = 1.0e-5#
bool useSolveMode = false#
bool debug = true#
bool is_save_results = false#
bool save_flag = false#
bool update_dt = false#
bool fixeddt = false#
bool check_dt = false#
bool useFastMode = false#
bool usrdefined_dt = false#
Vector2 gravity#
energy_type energy#
solver_base solver#
config config_type = config::PLANESTRESS#
model_t model#
template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class T10, class T11, class T12, class T13, class T14, class T15>
struct helper#
#include <variant_lite.hpp>

Public Types

typedef signed char type_index_t#

Public Functions

typedef variant_TL16 (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15) variant_types

Public Static Functions

template<class U>
static inline U *as(void *data)#
template<class U>
static inline U const *as(void const *data)#
static inline type_index_t to_index_t(std::size_t index)#
static inline void destroy(type_index_t index, void *data)#
static inline type_index_t copy_construct(type_index_t const from_index, const void *from_value, void *to_value)#
static inline type_index_t copy_assign(type_index_t const from_index, const void *from_value, void *to_value)#
template<std::size_t K>
struct in_place_index_tag#
#include <optional_lite.hpp>
struct in_place_t#
#include <optional_lite.hpp>
template<class T>
struct in_place_type_tag#
#include <optional_lite.hpp>
struct init#
#include <optional_lite.hpp>
struct Keywords#
#include <openfdem_struct.h>

Public Functions

inline Keywords()#
inline void clean()#

Public Members

char copy[MAX_CHARACTER]#
char *keywords[MAX_KEYWORDS]#
Int MAXNUM = MAX_KEYWORDS#
Int count = 0#
bool findbracket = false#
class LatexExporter : public tabulate::Exporter#
#include <latex_exporter.hpp>

Public Functions

inline ExportOptions &configure()#
inline virtual std::string dump(Table &table) override#
inline virtual ~LatexExporter()#

Private Functions

inline std::string add_alignment_header(Table &table)#

Private Members

ExportOptions options_#

Private Static Attributes

static const char new_line = '\n'#
class Logger#
#include <logger.h>

Logger class used by OOFEM to print information during analysis. Prints warnings and errors into a separate stream from normal output.

Public Types

enum logLevelType#

Type defining basic log levels.

Values:

enumerator LOG_LEVEL_FORCED#
enumerator LOG_LEVEL_FATAL#
enumerator LOG_LEVEL_ERROR#
enumerator LOG_LEVEL_WARNING#
enumerator LOG_LEVEL_RELEVANT#
enumerator LOG_LEVEL_INFO#
enumerator LOG_LEVEL_ALL#
enumerator LOG_LEVEL_DEBUG#

Public Functions

Logger(logLevelType level)#
~Logger()#
void appendLogTo(const std::string &fname)#

Redirects log output to given file name (with path).

void appendErrorTo(const std::string &fname)#

Redirects error output to given file name (with path).

void appendLogTo(FILE *stream)#

Redirects log output to given stream.

void appendErrorTo(FILE *stream)#

Redirects error output to given stream.

void writeLogMsg(logLevelType level, const char *format, ...)#

Writes the normal log message.

void writeELogMsg(logLevelType level, const char *_func, const char *_file, int _line, const char *format, ...)#

Writes extended log message with file and line info.

void writeExitMsg(const char *_func, const char *_file, int _line)#

Writes exit information.

void writeImplementLogMsg(const char *_func, const char *_file, int _line)#

write information to be implemented

inline void flush()#

Flushes the log stream.

inline void setLogLevel(logLevelType level)#

Sets log level to given one. Only log messages with level less or equal given threshold will be printed.

void setLogLevel(int level)#

Sets log level to given one. Only log messages with level less or equal given threshold will be printed.

inline void incrementErrorCounter()#

Increment error count by one.

void printStatistics()#

Prints number of errors and warning logged.

Protected Functions

const char *giveLevelName(logLevelType l) const#

Protected Attributes

FILE *logStream#

Stream used for logging.

FILE *errStream#
bool closeFlag#

flag indicating whether to close mylogStream.

bool errCloseFlag#
logLevelType logLevel#

Current log level, messages with higher level are not reported.

int numberOfWrn#

Counter of all warning and error messages.

int numberOfErr#
class MarkdownExporter : public tabulate::Exporter#

Public Functions

inline virtual std::string dump(Table &table) override#
inline virtual ~MarkdownExporter()#

Private Functions

inline void add_alignment_header_row(Table &table)#
inline void remove_alignment_header_row(Table &table)#
inline void apply_markdown_format(Table &table)#
inline void restore_table_format(Table &table)#

Private Members

std::vector<Format> formats_#
class Matrix#
#include <openfdem_matrix.h>

Class : dynamic Matrix (Real), it is used to create dynamic matrix assigned by the user according to the row and coloumn of the matrix

Used to manage Matrix The matrix is a dynamic matrix composed by _rows x _cols, 2 x 2 matrix should use the specific type: Matrix2.

Public Functions

Matrix(const Int = 2, const Int = 2, const Real = 0.0)#

Constructor to create a 2x2 matrix with initial value 0.0.

Attention

The matrix class will generate dynamic memory

Parameters:
  • cloumn[in] - Matrix column

  • row[in] - Matrix row

  • value[in] - Initial matrix value

Returns:

The initial matrix

Matrix(const Matrix&)#

constructor by copy from the matrix.

Param :

Matrix(Int rows, Int cols, Real firstValue, Real secondValue, ...)#

constructor by several arguments input.

Parameters:
  • rows

  • cols

  • firstValue

  • secondValue

Param :

~Matrix()#

deconstructor.

void allocate(const Int row, const Int coloumn)#

allocate the size of this matrix.

param

Param :

void desallocate()#

freeup the dynamic memory.

inline Real &operator()(Int row, Int coloumn)#

return the matrix compoment. matrix(0,2)

Parameters:
  • row

  • coloumn

Returns:

Matrix &operator=(const Real &val)#

set the matrix equals to a double value. M = a;

Parameters:

val

Returns:

Matrix &operator=(const Matrix&)#

set the matrix equals to another matrix. two matrixs should have the same dimension, otherwise resize

M = N;

return

Param :

void operator-=(const Matrix&)#

minus a matrix. M = M - N;

Param :

void operator*=(const Real&)#

element-wise multiply and store the new value in this matrix.

M = M * a;

Param :

void operator/=(const Real&)#

element-wise divid. M = M / a;

Param :

void operator+=(const Matrix&)#

matrix add. M = M + N;

Param :

void print(std::ostream&) const#

log this matrix.

Param :

inline bool indexCheck(Int, Int) const#

check the index of the matrix.

param

Param :

Returns:

bool operator!=(const Matrix&) const#

identify the bool between two matrixs. return true when M != N; otherwise false

return

Param :

bool operator==(const Matrix&) const#

return true when M == N, otherwise false.

return

Param :

Real doubleProduct() const#

This method defines a Real contracted product of two second order tensors. The result of this operation is a scalar defined by:

\[ s = A : B \]
s = T : U = T.ij * U.ji Example :
Tensor tensor1,tensor2;
Real s;
s = tensor1.doubleProduct(tensor2); // Real contracted product
  • tensor2 Second second order tensor to use for the operation

Returns:

Real getAverageTrace() const#

This method calculates the average of the trace of a square matrix Return: value of the average of the trace of the matrix. s = M.trace / row

Returns:

Real getDeterminant2x2() const#

return the determinant of a 2x2 matrix.

Returns:

Real getDeterminant3x3() const#

return the determinant of a 3x3 matrix.

Returns:

Real getTrace() const#

return the trace of the matrix. s = M.ii

Returns:

Real maxAbsoluteValue() const#

returns the maximum absolute component of a matrix.

Returns:

Real maxValue() const#

returns the maximum component of a matrix.

Returns:

Real minAbsoluteValue() const#

returns the minmum absolute component of a matrix.

Returns:

Real minValue() const#

returns the minmum component of a matrix.

Returns:

inline Real operator()(Int row, Int coloumn) const#

return the compoment of the matrix.

param

Param :

Returns:

inline Real sumTerms() const#

sum the matrix compoment.

Returns:

Int Memory() const#

return the memory size of the matrix.

Returns:

Matrix getSkewSymetricPart() const#

This method extracts the anti-symmetric part of a matrix and returns it

Warning

This method is only available for matrices of size 2 and 3. Return: anti-symmetric part of the matrix.

Returns:

Matrix getSymetricPart() const#

This method extracts the symmetric part of a matrix and returns it

Warning

This method is only available for matrices of size 2 and 3. Return: symmetric part of the matrix.

Returns:

Matrix getTranspose() const#

return the transpose of the matrix.

Returns:

Matrix operator-() const#

negatie a matrix. M = -M

Returns:

Matrix operator-(const Matrix&) const#

minus a matrix. A = M -N

Returns:

Matrix operator*(const Real&) const#

multiply a value and return a new matrix. A = M * c

return

Param :

Matrix operator/(const Real&) const#

divid a value and return a new matrix. A = M /c

return

Param :

Matrix operator+(const Matrix&) const#

add a new matrix. A = M + N

return

Param :

Vector columnSum() const#

return a dynamic vector of the row.

Returns:

Vector getColumn(Int) const#

return a dynamic vector of a assigned column.

return

Param :

Vector getRow(Int) const#

return a dynamic vector of the assigned row.

return

Param :

Vector rowSum() const#

return a vector to sum up the row.

Returns:

void computeInverse2x2(Real det, Matrix &inverse) const#

return the inverse matrix of 2x2 matrix.

Parameters:
  • det

  • inverse

void computeInverse3x3(Real det, Matrix &inverse) const#

return the inverse matrix of a 3x3 matrix and out the reuslt in a dynamic matrix

Parameters:
  • det

  • inverse

void computeInverse2x2(Real det, Matrix2 &inverse) const#

return the inverse matrix of a 3x3 matrix and ouput the result in a 3x3 matrix.

Parameters:
  • det

  • inverse

void resize(const Int, const Int)#

resize the dimension of the matrix.

param

Param :

void setToUnity()#

set the matrix to unit matrix.

void setToValue(Real)#

set the matrix an assigned value.

Param :

Private Members

Int _rows#
Int _cols#
Int _dataLength#
Real *_data#

Friends

friend class Vector
friend Matrix operator*(const Real &val, const Matrix&)#

element-wise multiply a real value M = a * N;

class Matrix2#

Class : Matrix2 (Real) Used to manage Matrix2 The matrix is a fixed matrix composed by _rows x _cols, 2 x 2 matrix should use the specific type .

Public Functions

Matrix2(const Real = 0.0)#

constructor

Matrix2(const Matrix2&)#
Matrix2(Real firstValue, Real secondValue, ...)#
~Matrix2()#
inline Real &operator()(Int row, Int coloumn)#

return the compoment of M(i,j).

Parameters:
  • row

  • coloumn

Returns:

Matrix2 &operator=(const Real &val)#

set the matrix equals to a double value. M = a;

Parameters:

val

Returns:

Matrix2 &operator=(const Matrix2&)#

set the matrix equals to another matrix. two matrixs should have the same dimension, otherwise resize

M = N;

return

Param :

Matrix2 &operator=(const Real array[2][2])#

set the matrix equals to another matrix. two matrixs should have the same dimension, otherwise resize

M = N;

return

Param :

void operator-=(const Matrix2&)#

minus a matrix. M = M - N;

Param :

void operator*=(const Real&)#

element-wise multiply and store the new value in this matrix.

M = M * a;

Param :

void operator/=(const Real&)#

element-wise divid. M = M / a;

Param :

void operator+=(const Matrix2&)#

matrix add. M = M + N;

Param :

void print(std::ostream&) const#

log this matrix.

Param :

inline void timesby(const Matrix2&, const Real)#

this = A * s.

param

Param :

inline void addby(const Matrix2&, const Matrix2&)#

get the matrix from two matrixs. this = A + B

param

Param :

inline bool indexCheck(Int row, Int coloumn) const#

check the index of the matrix.

param

Param :

Returns:

bool operator!=(const Matrix2&) const#

identify the bool between two matrixs. return true when M != N; otherwise false

return

Param :

bool operator==(const Matrix2&) const#

return true when M == N, otherwise false.

return

Param :

Real doubleProduct() const#

This method defines a Real contracted product of two second order tensors. The result of this operation is a scalar defined by:

\[ s = A : B \]
s = T : U = T.ij * U.ji Example :
Tensor tensor1,tensor2;
Real s;
s = tensor1.doubleProduct(tensor2); // Real contracted product
  • tensor2 Second second order tensor to use for the operation

Returns:

Real getAverageTrace() const#

This method calculates the average of the trace of a square matrix Return: value of the average of the trace of the matrix. s = M.trace / row

Returns:

Real getDeterminant() const#

return the determinant of a matrix.

Returns:

Real getTrace() const#

return the trace of the matrix. s = M.ii

Returns:

Real maxAbsoluteValue() const#

returns the maximum absolute component of a matrix.

Returns:

Real maxValue() const#

returns the maximum component of a matrix.

Returns:

Real minAbsoluteValue() const#

returns the minmum absolute component of a matrix.

Returns:

Real minValue() const#

returns the minmum component of a matrix.

Returns:

inline Real operator()(Int, Int) const#

return the compoment of the matrix.

param

Param :

Returns:

inline Real sumTerms() const#
Int Memory() const#

return the memory size of the matrix.

Returns:

Matrix2 getSkewSymetricPart() const#
Matrix2 getSymetricPart() const#
Matrix2 getTranspose() const#

return the transpose of the current matrix.

Returns:

void getTransposefrom(const Matrix2 &matrix)#

compute the transpose of existed matrix and store the result in current matrix.

Parameters:

matrix

Matrix2 operator-() const#

negatie a matrix. M = -M

Returns:

Matrix2 operator-(const Matrix2&) const#

minus a matrix. A = M -N

Returns:

Matrix2 operator*(const Real&) const#

multiply a value and return a new matrix. A = M * c

return

Param :

Matrix2 operator*(const Matrix2&) const#

multiply a matrix and return a new 2x2 matrix.

return

Param :

Vector2 operator*(const Vector2&) const#

multiply a vector and return a vector. v = M * vc

return

Param :

Matrix2 operator/(const Real&) const#

divid a value and return a new matrix. A = M /c

return

Param :

Matrix2 operator+(const Matrix2&) const#

add a new matrix. A = M + N

return

Param :

Vector2 columnSum() const#
Vector2 getColumn(Int) const#
Vector2 getRow(Int) const#
Vector2 rowSum() const#
void computeInverse(Real det, Matrix2 &inverse) const#

return the inverse matrix of a 3x3 matrix and out the reuslt in a matrix

Parameters:
  • det

  • inverse

void computeInverse(Matrix2 &inverse) const#

set the matrix to unit matrix.

void setToUnity()#

set the matrix to unit matrix.

void setToValue(Real)#

set the matrix an assigned value.

Param :

void setToZero()#

set the matrix an assigned value.

Param :

void addI()#

Public Members

Real _data[MAX_MATRIX2_SIZE]#

Private Members

friend Matrix

Friends

friend Matrix2 operator*(const Real &val, const Matrix2&)#

return a new matrix by multiply a value with a matrix.

class model : public OpenFdemAbstract#
#include <openfdem_base.h>

Public Functions

inline model()#
inline ~model()#
void initialize(Openfdem openfdem)#

model initialization to set memory of the main structres. the classes will be constructered automatically and double-checked at this step.

Parameters:

openfdem

void setenvironment(Openfdem openfdem, int argc, char **argv)#

set a new environment for the model.

Parameters:
  • openfdem

  • argc

  • argv

void finalize(Int ret)#

finalize the run. all created variables will be earsed and memory is released in the heap.

Parameters:

ret

void Run(Openfdem openfdem)#

main run function for the calculation.

Parameters:

openfdem

Int readRunFile(Openfdem openfdem, char **argv)#

parse the input file.

Parameters:
  • openfdem

  • argv

Returns:

Private Members

char inputFileFullPath[Openfdem_ARGC_LENGTH]#
char inputFileWithSuffix[Openfdem_ARGC_LENGTH]#
char inputFileName[Openfdem_ARGC_LENGTH]#
struct model_t#
#include <openfdem_general.h>

Public Functions

inline model_t()#

Public Members

bool has_mazars = false#
bool has_JH2 = false#
bool has_Yang = false#
bool has_TCK = false#
bool has_dfb = false#
bool has_plastic = false#
bool has_viscous = false#
bool has_JWL = false#
bool has_nonlocal = false#
bool has_cohesive = false#
bool has_phasefield = false#
bool use_largedeformation = false#
bool has_contact = true#
bool has_blast = false#
bool has_dynamic = false#
bool has_thermal = false#
bool has_hydro = false#
bool has_remesh = false#
bool has_AMR = false#
bool has_AMRdynamic = false#
bool has_GBM = false#
bool has_mmg = false#
bool has_quadratic = false#
bool has_extrinsic = false#
bool has_rigid = false#
bool has_deformable = false#
bool has_particle = false#
bool has_mpm = false#
bool usedu = false#
bool gravityzero = true#
bool has_dynamicCZM = false#
bool useConnect = false#
bool has_hetCZM = false#
class monostate#
#include <variant_lite.hpp>
struct nullopt_t#
#include <optional_lite.hpp>

disengaged state tag

Public Functions

inline explicit optional_constexpr nullopt_t (init) optional_noexcept
struct nulltype#
#include <optional_lite.hpp>
struct nulltype#
#include <variant_lite.hpp>
class OpenFdemAbstract#

Subclassed by ns_common::OpenFDEMTools

Public Functions

OpenFdemAbstract()#
virtual ~OpenFdemAbstract()#
class OpenFDEMchrono#
#include <openfdem_chrono.h>

Public Static Functions

static inline void DateTime(char *date_time)#
static inline void StampTime(void)#
static inline double openfdem_time_count()#
class OpenFDEMmanager#
#include <openfdem_manager.h>

Public Static Functions

static inline void usehelp(char *prog)#

Print help for common options of the 3 codes (first section).

Parameters:

*prog – pointer toward the program name.

static inline bool checkLicense()#
static inline void foldercfg(int argc, char **argv, char *inputFileFullPath, char *inputFileWithSuffix, char *inputFileName, General general)#
static inline void printversion()#
static inline void printCopyrightPage()#
static inline void writepage(FILE *fileptr)#
class OpenFDEMmessage#
#include <openfdem_message.h>

Public Static Functions

static inline void Runtime_message(const char *c1)#

print a string to screen.

Runtime_message("exit with error.");
=> exit with error.\n

Parameters:

c1

static inline void RuntimeInfo(const char *c1)#

print a string to screen.

Runtime_message("exit with error.");
=>Info     :exit with error.\n

Parameters:

c1

static inline void Runtime_strformat(const char *c1)#

print a formated string to screen.

Runtime_strformat("exit with error.");
=>Info     :exit with error.\n

Parameters:

c1

static inline void RuntimeKeywordError(const char *s1, int i1)#

print error message for keword parsing.

RuntimeKeywordError("geometry",12)
=>Info     :Error: unknow keyword [geometry] at line [12]. \n

Parameters:
  • s1

  • i1

static inline void RuntimeStringIntStringInt(const char *s1, int i1, const char *s2, int i2)#
static inline void RuntimeStringtoFile(FILE *fileptr, const char *c1)#

print a string to file.

Runtime_message("exit with error.");
=< exit with error.\n

Parameters:

c1

static inline void RuntimebackStringString(const char *c1, const char *c2)#

print a sentence composed by two strings.

RuntimebackStringString("geometry group is","rock.")
=>Info     : geometry group is [rock]. \n

Parameters:
  • c1

  • c2

static inline void RuntimeIntStringString(int n1, const char *c1, const char *c2)#

print a sentence composed by two strings.

   RuntimebackStringString("mesh.msh"," file is imported.")
   =>Info     : [mesh.msh] file is imported. \n
  
   \param c1
   \param c2
  /
static void RuntimefrontStringString(const char* c1, const char* c2)  // print message out to screen
{
    printf("Info     :");
    writeCharValue(stdout, "[");
    writeCharValue(stdout, c1);
    writeCharValue(stdout, "] ");
    writeCharValue(stdout, c2);
    writeCharValue(stdout, "\n");
}

Parameters:
  • n1

  • c1

  • c2

static inline void RuntimeStringInt(const char *c1, int c2)#

print a sentence composed by a string and integer.

RuntimeStringInt("The count of node in the model is ","2300")
=>Info     : The count of node in the model is [2300]. \n

Parameters:
  • c1

  • c2

static inline void RuntimeString(std::string c1)#
static inline void RuntimeStringReal(const char *c1, double c2)#

print a sentence composed by a string and double value.

RuntimeStringReal("The stiffness of the rock is ","1.2e9")
=>Info     : The stiffness of the rock is [1.2e9]. \n

Parameters:
  • c1

  • c2

static inline void RuntimeIntString(int c2, const char *c1)#

print a sentence composed by a integer and a string.

RuntimeStringReal("20","nodes are added in the model.")
=>Info     : [20] nodes are added in the model. \n

Parameters:
  • c1

  • c2

static inline void RuntimeStringIntString(const char *s1, int c2, const char *s2)#

print a sentence composed by a string, integer and a string.

RuntimeStringReal("Congratulation,","20","nodes are added in the model.")
=>Info     :Congratulation, [20] nodes are added in the model. \n

Parameters:
  • s1

  • c2

  • s2

static inline void RuntimeStringStringString(const char *s1, const char *c2, const char *s2)#

print a sentence composed by a string, integer and a string.

RuntimeStringReal("Congratulation,","20","nodes are added in the model.")
=>Info     :Congratulation, [20] nodes are added in the model. \n

Parameters:
  • s1

  • c2

  • s2

static inline void Runtime_writelogs(FILE *checkfile, const char *keyword)#

write parsing log to log file.

Parameters:
  • checkfile

  • keyword

class OpenFDEMTools : public ns_common::OpenFdemAbstract#
#include <openfdem_tools.h>

Public Static Functions

static void checkmodule(Openfdem openfdem)#

check the module and print out.

Parameters:

openfdem

static void checkMeshInfo(Openfdem openfdem)#

check mesh and print out info.

Parameters:

openfdem

static void checkBoundaryInfo(Openfdem openfdem)#

check boundary condition and print out info.

Parameters:

openfdem

static void checkMaterials(Openfdem openfdem)#

check material and print out info.

Parameters:

openfdem

static void PrintProgressInfo(Openfdem openfdem)#

print the running progress.

Parameters:

openfdem

template<typename T>
class optional#
#include <optional_lite.hpp>

class optional

optional access error

optional

Public Types

typedef T value_type#

Public Functions

inline optional_constexpr optional () optional_noexcept
inline optional_constexpr optional (nullopt_t) optional_noexcept
inline optional_constexpr14 optional(optional const &other)#
template<typename U>
inline optional(optional<U> const &other)#
inline optional(value_type const &value)#
inline ~optional()#
inline optional & operator= (nullopt_t) optional_noexcept
inline optional &operator=(optional const &other)#
template<typename U>
inline optional &operator=(U const &value)#
template<typename U>
inline optional &operator=(optional<U> const &other)#
inline void swap(optional &other)#
inline optional_constexpr value_type const * operator-> () const
inline optional_constexpr14 value_type * operator-> ()
inline optional_constexpr value_type const & operator* () const optional_ref_qual
inline optional_constexpr14 value_type & operator* () optional_ref_qual
inline optional_constexpr operator safe_bool () const optional_noexcept
inline optional_constexpr bool has_value () const optional_noexcept
inline optional_constexpr14 value_type const & value () const optional_ref_qual
inline optional_constexpr14 value_type & value () optional_ref_qual
template<typename U> inline optional_constexpr value_type value_or (U const &v) const
inline void reset () optional_noexcept

Private Types

typedef void (optional::* safe_bool)() const#

Private Functions

inline void this_type_does_not_support_comparisons() const#
template<typename V>
inline void initialize(V const &value)#

Private Members

bool has_value_#
detail::storage_t<value_type> contained#

Friends

friend class optional
class Printer#
#include <printer.hpp>

Public Static Functions

static inline std::pair<std::vector<size_t>, std::vector<size_t>> compute_cell_dimensions(TableInternal &table)#
static inline void print_table(std::ostream &stream, TableInternal &table)#
static inline void print_row_in_cell(std::ostream &stream, TableInternal &table, const std::pair<size_t, size_t> &index, const std::pair<size_t, size_t> &dimension, size_t num_columns, size_t row_index)#
static inline bool print_cell_border_top(std::ostream &stream, TableInternal &table, const std::pair<size_t, size_t> &index, const std::pair<size_t, size_t> &dimension, size_t num_columns)#
static inline bool print_cell_border_bottom(std::ostream &stream, TableInternal &table, const std::pair<size_t, size_t> &index, const std::pair<size_t, size_t> &dimension, size_t num_columns)#
static inline void apply_element_style(std::ostream &stream, Color foreground_color, Color background_color, const std::vector<FontStyle> &font_style)#
static inline void reset_element_style(std::ostream &stream)#

Private Static Functions

static inline void print_content_left_aligned(std::ostream &stream, const std::string &cell_content, const Format &format, size_t text_with_padding_size, size_t column_width)#
static inline void print_content_center_aligned(std::ostream &stream, const std::string &cell_content, const Format &format, size_t text_with_padding_size, size_t column_width)#
static inline void print_content_right_aligned(std::ostream &stream, const std::string &cell_content, const Format &format, size_t text_with_padding_size, size_t column_width)#
static inline void apply_font_style(std::ostream &stream, FontStyle style)#
static inline void apply_foreground_color(std::ostream &stream, Color foreground_color)#
static inline void apply_background_color(std::ostream &stream, Color background_color)#
template<class T>
struct remove_const#
#include <variant_lite.hpp>

Public Types

typedef T type#
template<class T>
struct remove_const<const T>#
#include <variant_lite.hpp>

Public Types

typedef T type#
template<class T>
struct remove_cv#
#include <variant_lite.hpp>

Public Types

typedef remove_volatile<typenameremove_const<T>::type>::type type#
template<class T>
struct remove_reference#
#include <variant_lite.hpp>

Public Types

typedef T type#
template<class T>
struct remove_reference<T&>#
#include <variant_lite.hpp>

Public Types

typedef T type#
template<class T>
struct remove_volatile#
#include <variant_lite.hpp>

Public Types

typedef T type#
template<class T>
struct remove_volatile<volatile T>#
#include <variant_lite.hpp>

Public Types

typedef T type#
class Row#
#include <row.hpp>

Public Functions

inline explicit Row(std::shared_ptr<class TableInternal> parent)#
inline void add_cell(std::shared_ptr<Cell> cell)#
inline Cell &operator[](size_t index)#
inline Cell &cell(size_t index)#
inline std::vector<std::shared_ptr<Cell>> cells() const#
inline size_t size() const#
inline Format &format()#
inline auto begin() -> CellIterator#
inline auto end() -> CellIterator#

Private Functions

inline size_t get_configured_height()#
inline size_t get_computed_height(const std::vector<size_t> &column_widths)#
inline size_t get_cell_height(size_t cell_index, size_t column_width)#

Private Members

std::vector<std::shared_ptr<Cell>> cells_#
std::weak_ptr<class TableInternal> parent_#
optional<Format> format_#

Friends

friend class Printer
class RowIterator#
#include <table.hpp>

Public Functions

inline explicit RowIterator(std::vector<std::shared_ptr<Row>>::iterator ptr)#
inline RowIterator operator++()#
inline bool operator!=(const RowIterator &other) const#
inline Row &operator*()#

Private Members

std::vector<std::shared_ptr<Row>>::iterator ptr#
class RuntimeException : public std::exception#
#include <openfdem_error.h>

Public Functions

RuntimeException(const char *_func, const char *_file, int _line, const char *format, ...)#
const char *what() const noexcept override#

Public Members

std::string msg#
struct S0#
#include <variant_lite.hpp>
struct S1#
#include <variant_lite.hpp>
struct S10#
#include <variant_lite.hpp>
struct S11#
#include <variant_lite.hpp>
struct S12#
#include <variant_lite.hpp>
struct S13#
#include <variant_lite.hpp>
struct S14#
#include <variant_lite.hpp>
struct S15#
#include <variant_lite.hpp>
struct S2#
#include <variant_lite.hpp>
struct S3#
#include <variant_lite.hpp>
struct S4#
#include <variant_lite.hpp>
struct S5#
#include <variant_lite.hpp>
struct S6#
#include <variant_lite.hpp>
struct S7#
#include <variant_lite.hpp>
struct S8#
#include <variant_lite.hpp>
struct S9#
#include <variant_lite.hpp>
struct solver_base#
#include <openfdem_general.h>

Public Functions

inline solver_base()#

Public Members

UInt previousCountofNode = 0#
UInt previousCountofElement = 0#
UInt previousCountofCohele = 0#
UInt finishedExcavationSteps = 0#
UInt run_times = 0#
union storage_t#
#include <optional_lite.hpp>

C++03 constructed union to hold value.

Public Types

typedef T value_type#

Public Functions

inline  storage_t () optional_is_default explicit storage_t(value_type const &v)
inline void construct_value(value_type const &v)#
inline void destruct_value()#
inline optional_nodiscard value_type const * value_ptr () const
inline value_type *value_ptr()#
inline optional_nodiscard value_type const & value () const optional_ref_qual
inline value_type & value () optional_ref_qual
typedef optional_ALIGN_AS (value_type) align_as_type
inline optional_nodiscard void * ptr () optional_noexcept
inline optional_nodiscard void const * ptr () const optional_noexcept
template<typename U> inline optional_nodiscard U * as ()
template<typename U> inline optional_nodiscard U const * as () const

Public Members

aligned_storage_t data#
class String : public std::string#
#include <openfdem_string.h>

Public Functions

String()#
String(const char*)#
String(const std::string&)#
String(const String&)#
~String()#
String &operator=(const char*)#
bool contains(char c, int = 0) const#
bool contains(const String&, int = 0) const#
bool containsWithCase(const String&, bool) const#
bool empty() const#
bool ok() const#
bool popInt(long&, String = " ")#
bool popReal(double&, String = " ")#
bool popString(String&, String = " ")#
bool scanFileLine(FILE*)#
char firstchar() const#
char lastchar() const#
const char *chars() const#
double getReal() const#
double getRealAtPos(int, String = " ")#
int containsWithCaseSub(const String&, bool) const#
int search(char c, int = 0) const#
int search(const String&, int = 0) const#
long getInt() const#
String &convert(const double, const char* = "%lf")#
String &convert(const int, short leading = 0)#
String &convert(const long, short leading = 0)#
String &replace(const char, const char)#
String &replace(const String&, const String&)#
String afterItem(char c, int = 0) const#
String afterItem(const String&, int = 0) const#
String afterItem(int) const#
String afterLast(const String&) const#
String atItem(char c, int = 0) const#
String atItem(const String&, int = 0) const#
String atItem(int, int) const#
String beforeItem(char c, int = 0) const#
String beforeItem(const String&, int = 0) const#
String beforeItem(int) const#
String beforeLast(const String&) const#
String fromItem(char c, int = 0) const#
String fromItem(const String&, int = 0) const#
String fromItem(int) const#
String operator()(int, int) const#
String subString(int, int) const#
String throughItem(char c, int = 0) const#
String throughItem(const String&, int = 0) const#
String throughItem(int) const#
void addExtension(String)#
void remove(char, int = 0)#
void remove(const String&, int = 0)#
void remove(int, int)#
void fromFile(FILE*)#
void lowerCase()#
void dump(const String&) const#
void strip()#
void toFile(FILE*)#
void upperCase()#
template<typename T>
struct struct_t#
#include <optional_lite.hpp>

Public Members

T _#
template<typename T>
struct struct_t#
#include <variant_lite.hpp>

Public Members

T _#
class Table#
#include <table.hpp>

Public Types

using Row_t = std::vector<variant<std::string, const char*, string_view, Table>>#

Public Functions

inline Table()#
inline Table &add_row(const Row_t &cells)#
inline Row &operator[](size_t index)#
inline Row &row(size_t index)#
inline Column column(size_t index)#
inline Format &format()#
inline void print(std::ostream &stream)#
inline std::string str()#
inline std::pair<size_t, size_t> shape()#
inline auto begin() -> RowIterator#
inline auto end() -> RowIterator#

Private Members

size_t rows_ = {0}#
size_t cols_ = {0}#
std::shared_ptr<TableInternal> table_#

Friends

friend class MarkdownExporter
friend class LatexExporter
friend class AsciiDocExporter
friend std::ostream &operator<<(std::ostream &stream, const Table &table)#
class TableInternal : public std::enable_shared_from_this<TableInternal>#
#include <table_internal.hpp>

Public Functions

inline void add_row(const std::vector<std::string> &cells)#
inline Row &operator[](size_t index)#
inline const Row &operator[](size_t index) const#
inline Column column(size_t index)#
inline size_t size() const#
inline std::pair<size_t, size_t> shape()#
inline Format &format()#
inline void print(std::ostream &stream)#
inline size_t estimate_num_columns() const#

Public Static Functions

static inline std::shared_ptr<TableInternal> create()#

Private Functions

inline TableInternal()#
TableInternal &operator=(const TableInternal&)#
TableInternal(const TableInternal&)#

Private Members

std::vector<std::shared_ptr<Row>> rows_#
Format format_#

Friends

friend class Table
friend class MarkdownExporter
class Tensor#
#include <openfdem_tensor.h>

Class : Tensor (Real) Used to manage Tensor The second order tensor is constructured as xx, xy, null yx, yy, null null, null, zz

Public Functions

Tensor()#

constructor.

Tensor(Real, Real, Real, Real, Real)#

constructor by input compoments.

param

param

param

Param :

Param :

Param :

Tensor(const Tensor&)#
void copy(const Tensor&)#
~Tensor()#
inline Real &operator()(Int, Int)#

return the compoment of T(i,j).

Parameters:
  • row

  • coloumn

Returns:

inline Real &operator[](Int)#

operator to directly get the compoment using [].

Parameters:

i

Returns:

inline Real &xx()#
inline Real &xy()#
inline Real &yx()#
inline Real &yy()#
inline Real &zz()#
inline Tensor &operator=(const Real&)#
inline Tensor &operator=(const Real list[])#
inline void getData(Real *list) const#
inline void getData(std::vector<Real> &list) const#
inline Tensor &operator=(const Tensor&)#

build a tensor from a existed tensor.

return

Param :

Tensor &operator=(const Matrix2 &matrix)#

build a tensor from 2x2 matrix, whereas zz is 0.0.

Parameters:

matrix

Returns:

inline void operator=(const Real tensor[2][2])#

build a tensor from 2x2 array, zz is initialized to 0.0.

Parameters:

tensor

Returns:

inline void operator=(const Real tensor[3][3])#
inline void operator-=(const Tensor&)#

minus a symmertic tensor.

Param :

inline void operator*=(const Real)#
inline void operator/=(const Real)#
inline void operator+=(const Tensor&)#
void print(std::ostream&) const#
bool operator!=(const Tensor&) const#
bool operator==(const Tensor&) const#
inline void timesby(const Tensor&, const Real)#
inline void addby(const Tensor&, const Tensor&)#
void updateTrialStress(const Tensor&, Real e1, Real e2, Real g)#
void updateTrialfullStress(const Tensor&, Real e1, Real e2, Real g)#
Real doubleProduct() const#

:Tensor::doubleProduct()

:Double contracted product of a second order tensor by itself.

This method defines a Real contracted product of a second order tensor by itself. The result of this operation is a scalar defined by: \begin{equation*} s = \A : \A = \sum_{i=1}^{3} \sum_{j=1}^{3} A_{ij}\times A_{ij} \end{equation*} where $\A$ is a second order tensor.

Returns:

Real doubleProduct(const Tensor&) const#

:Tensor::doubleProduct(Tensor)

:Double contracted product of 2 second order tensors.

This method defines a Real contracted product of two second order tensors. The result of this operation is a scalar defined by: \begin{equation*} s = \A : \B = \sum_{i=1}^{3} \sum_{j=1}^{3} A_{ij}\times B_{ij} \end{equation*} where $\A$ and $\B$ are two second order tensors.

return

Param :

inline Real getDeterminant() const#

get the determinant of the tensor, the zz compoment is ignored.

Returns:

inline Real getJ2() const#

get the J2 equvalient stress. J2 = 1/2 s.ij x s.ij = 1/6 [(sig.x - sig.y)^2 + (sig.y - sig.z)^2 + (sig.z-sig.x)^2 + 6(tau.xy^2 + tau.yz^2 + tau.zx^2)]

Returns:

inline Real getNorm() const#
inline Real getSquareNorm() const#
inline Real getThirdTrace() const#

get the hydrostatic stress.

Returns:

inline Real getTrace() const#

get the trace of the tensor, considering the zz compoment.

Returns:

Real maxAbsoluteValue()#
Real maxValue()#
Real minAbsoluteValue()#
Real minValue()#
inline Real operator()(Int, Int) const#
inline Real xx() const#
inline Real xy() const#
inline Real yx() const#
inline Real yy() const#
inline Real zz() const#
Vector2 rowSum() const#
Vector2 columnSum() const#
Vector2 getRow(Int row) const#
Vector2 getColumn(Int col) const#
Tensor getDeviator() const#

:Tensor::getDeviator()

:Deviatoric part of a second order tensor.

This method defines the deviatoric part of a second second order tensor. The result of this operation is a second order tensor defined by the following equation: \begin{equation*} \Sig^d=\Sig-\frac{1}{3}\tr[\Sig].\Id \end{equation*} where $\Sig^d$ is the deviatoric part of the tensor, $\Sig$ is the tensor and $\Id$ is the unit tensor.

Returns:

inline Real getEnergy(Tensor &strain) const#

get the inverse of the tensor, ignore the zz compoment.

Returns:

Real getPrincipal(Real principal[], Real Q[2][2], UInt index[]) const#
Tensor getPrincipal(UInt index[]) const#
void getPrincipal2D(Real prin[]) const#
Real getPrincipalDirection2D() const#
void solveBack(Tensor &prin, Real theta, UInt index[])#
void solveBack(Tensor &prin, Real theta)#
void solveBack(Real prin[][3], Real theta)#
inline Real getPostiveNorm() const#
Tensor getInverse() const#
Tensor getSkewSymetricPart() const#
Tensor getSymetricPart() const#
Tensor getTranspose() const#
Tensor operator-() const#
Tensor operator-(const Tensor&) const#
Tensor operator*(const Real) const#
Tensor operator*(const Tensor&) const#
Tensor operator/(const Real) const#
Tensor operator+(const Tensor&) const#
Tensor operator+(const Real&) const#
Tensor singleProduct() const#
Vector2 operator*(const Vector2&) const#

:Tensor::operator*(Vec2D)

:Multiplication of a second order tensor by a vector. ignore the zz compoment

return

Param :

Vector2 solve(const Vector2&) const#
void addI()#
void setToUnity(</