MOAB: Mesh Oriented datABase
(version 5.5.0)
|
#include "moab/Core.hpp"
#include "moab/Range.hpp"
#include "moab/ProgOptions.hpp"
#include "moab/CartVect.hpp"
#include "moab/ElemEvaluator.hpp"
#include "moab/CN.hpp"
#include "ElemUtil.hpp"
#include <iostream>
#include <ctime>
#include <cstdlib>
#include <cassert>
#include <sstream>
#include <string>
#include <sys/resource.h>
Go to the source code of this file.
Macros | |
#define | CHK(r, s) |
Functions | |
static void | fail (ErrorCode error_code, const char *str, const char *file_name, int line_number) |
double | mytime () |
ErrorCode | get_ents (Interface &mbi, std::string &filename, int &dim, Range &elems, EntityType &tp, int &nv) |
void | parse_options (ProgOptions &opts, int &dim, std::string &filename) |
ErrorCode | get_elem_map (EntityType tp, std::vector< CartVect > &vcoords, int nconn, Element::Map *&elemmap) |
ErrorCode | time_forward_eval (Interface *mbi, int method, Range &elems, std::vector< CartVect > ¶ms, std::vector< CartVect > &coords, double &evtime) |
ErrorCode | time_reverse_eval (Interface *mbi, int method, Range &elems, std::vector< CartVect > &coords, std::vector< CartVect > ¶ms, double &retime) |
ErrorCode | time_jacobian (Interface *mbi, int method, Range &elems, std::vector< CartVect > ¶ms, double &jactime) |
ErrorCode | time_integrate (Interface *mbi, int method, Tag tag, Range &elems, double &inttime) |
ErrorCode | put_random_field (Interface &mbi, Tag &tag, Range &elems) |
ErrorCode | elem_evals (Interface *mbi, int method, Range &elems, Tag tag, std::vector< CartVect > ¶ms, std::vector< CartVect > &coords, double &evtime, double &retime, double &jactime, double &inttime) |
int | main (int argc, char *argv[]) |
double | mytime2 (double &tot_time, double &utime, double &stime, long &imem, long &rmem) |
Variables | |
const int | ELEMEVAL = 0 |
const int | ELEMUTIL = 1 |
#define CHK | ( | r, | |
s | |||
) |
Definition at line 27 of file elem_eval_time.cpp.
ErrorCode elem_evals | ( | Interface * | mbi, |
int | method, | ||
Range & | elems, | ||
Tag | tag, | ||
std::vector< CartVect > & | params, | ||
std::vector< CartVect > & | coords, | ||
double & | evtime, | ||
double & | retime, | ||
double & | jactime, | ||
double & | inttime | ||
) |
Definition at line 333 of file elem_eval_time.cpp.
References CHK, ErrorCode, time_forward_eval(), time_integrate(), time_jacobian(), and time_reverse_eval().
Referenced by main().
|
static |
Definition at line 39 of file elem_eval_time.cpp.
ErrorCode get_elem_map | ( | EntityType | tp, |
std::vector< CartVect > & | vcoords, | ||
int | nconn, | ||
Element::Map *& | elemmap | ||
) |
Definition at line 88 of file elem_eval_time.cpp.
References MB_SUCCESS, MBHEX, MBQUAD, and MBTET.
Referenced by time_forward_eval(), time_integrate(), time_jacobian(), and time_reverse_eval().
ErrorCode get_ents | ( | Interface & | mbi, |
std::string & | filename, | ||
int & | dim, | ||
Range & | elems, | ||
EntityType & | tp, | ||
int & | nv | ||
) |
Definition at line 47 of file elem_eval_time.cpp.
References moab::Range::begin(), CHK, dim, moab::Range::empty(), ErrorCode, filename, moab::Interface::get_connectivity(), moab::Interface::get_entities_by_dimension(), moab::Interface::load_file(), MB_SUCCESS, moab::Range::rbegin(), and moab::Interface::type_from_handle().
Referenced by main().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 365 of file elem_eval_time.cpp.
References CHK, dim, elem_evals(), ELEMEVAL, ELEMUTIL, moab::CN::EntityTypeName(), ErrorCode, filename, get_ents(), MB_SUCCESS, parse_options(), ProgOptions::parseCommandLine(), put_random_field(), and moab::Range::size().
double mytime | ( | ) |
Definition at line 457 of file elem_eval_time.cpp.
References mytime2().
Referenced by time_forward_eval(), time_integrate(), time_jacobian(), and time_reverse_eval().
double mytime2 | ( | double & | tot_time, |
double & | utime, | ||
double & | stime, | ||
long & | imem, | ||
long & | rmem | ||
) |
void parse_options | ( | ProgOptions & | opts, |
int & | dim, | ||
std::string & | filename | ||
) |
Definition at line 80 of file elem_eval_time.cpp.
References ProgOptions::addOpt(), dim, filename, and ProgOptions::int_flag.
Referenced by main().
Definition at line 319 of file elem_eval_time.cpp.
References CHK, ErrorCode, moab::Interface::get_adjacencies(), MB_TAG_CREAT, MB_TAG_DENSE, MB_TYPE_DOUBLE, moab::Range::size(), moab::Interface::tag_get_handle(), moab::Interface::tag_set_data(), and moab::Interface::UNION.
Referenced by main().
ErrorCode time_forward_eval | ( | Interface * | mbi, |
int | method, | ||
Range & | elems, | ||
std::vector< CartVect > & | params, | ||
std::vector< CartVect > & | coords, | ||
double & | evtime | ||
) |
Definition at line 128 of file elem_eval_time.cpp.
References moab::Range::begin(), CHK, ELEMEVAL, ELEMUTIL, moab::Range::end(), ErrorCode, moab::ElemEvaluator::eval(), moab::Element::Map::evaluate(), moab::Interface::get_connectivity(), moab::Interface::get_coords(), get_elem_map(), moab::CN::MAX_NODES_PER_ELEMENT, MB_SUCCESS, mytime(), moab::ElemEvaluator::set_ent_handle(), moab::ElemEvaluator::set_eval_set(), moab::ElemEvaluator::set_tag_handle(), and moab::Interface::type_from_handle().
Referenced by elem_evals().
Definition at line 270 of file elem_eval_time.cpp.
References moab::Range::begin(), CHK, ELEMEVAL, ELEMUTIL, moab::Range::end(), ErrorCode, moab::Interface::get_connectivity(), moab::Interface::get_coords(), get_elem_map(), moab::ElemEvaluator::integrate(), moab::Element::Map::integrate_scalar_field(), moab::CN::MAX_NODES_PER_ELEMENT, MB_SUCCESS, mytime(), moab::ElemEvaluator::set_ent_handle(), moab::ElemEvaluator::set_eval_set(), moab::ElemEvaluator::set_tag_handle(), moab::Interface::tag_get_data(), and moab::Interface::type_from_handle().
Referenced by elem_evals().
ErrorCode time_jacobian | ( | Interface * | mbi, |
int | method, | ||
Range & | elems, | ||
std::vector< CartVect > & | params, | ||
double & | jactime | ||
) |
Definition at line 227 of file elem_eval_time.cpp.
References moab::Matrix3::array(), moab::Range::begin(), CHK, ELEMEVAL, ELEMUTIL, moab::Range::end(), ErrorCode, moab::Interface::get_connectivity(), moab::Interface::get_coords(), get_elem_map(), moab::Element::Map::jacobian(), moab::ElemEvaluator::jacobian(), moab::CN::MAX_NODES_PER_ELEMENT, MB_SUCCESS, mytime(), moab::ElemEvaluator::set_ent_handle(), moab::ElemEvaluator::set_eval_set(), moab::ElemEvaluator::set_tag_handle(), and moab::Interface::type_from_handle().
Referenced by elem_evals().
ErrorCode time_reverse_eval | ( | Interface * | mbi, |
int | method, | ||
Range & | elems, | ||
std::vector< CartVect > & | coords, | ||
std::vector< CartVect > & | params, | ||
double & | retime | ||
) |
Definition at line 178 of file elem_eval_time.cpp.
References moab::Range::begin(), CHK, ELEMEVAL, ELEMUTIL, moab::Range::end(), ErrorCode, moab::Interface::get_connectivity(), moab::Interface::get_coords(), get_elem_map(), moab::Element::Map::ievaluate(), moab::CN::MAX_NODES_PER_ELEMENT, MB_SUCCESS, mytime(), moab::ElemEvaluator::reverse_eval(), moab::ElemEvaluator::set_ent_handle(), moab::ElemEvaluator::set_eval_set(), moab::ElemEvaluator::set_tag_handle(), and moab::Interface::type_from_handle().
Referenced by elem_evals().
const int ELEMEVAL = 0 |
Definition at line 37 of file elem_eval_time.cpp.
Referenced by main(), time_forward_eval(), time_integrate(), time_jacobian(), and time_reverse_eval().
const int ELEMUTIL = 1 |
Definition at line 37 of file elem_eval_time.cpp.
Referenced by main(), time_forward_eval(), time_integrate(), time_jacobian(), and time_reverse_eval().