#include <iostream>
#include <sstream>
#include <ctime>
#include <cstdlib>
#include <cstdio>
#include <cstring>
#include <cmath>
#include "moab/Core.hpp"
#include "moab/Interface.hpp"
#include "moab/IntxMesh/Intx2MeshOnSphere.hpp"
#include "moab/ProgOptions.hpp"
#include "MBTagConventions.hpp"
#include "moab/ParallelComm.hpp"
#include "moab/IntxMesh/IntxUtils.hpp"
#include "IntxUtilsCSLAM.hpp"
#include "TestUtil.hpp"
Go to the source code of this file.
Functions | |
ErrorCode | add_field_value (Interface *mb, EntityHandle euler_set, int rank, Tag &tagTracer, Tag &tagElem, Tag &tagArea) |
ErrorCode | compute_velocity_case1 (Interface *mb, EntityHandle euler_set, Tag &tagh, int rank, int tStep) |
ErrorCode | compute_tracer_case1 (Interface *mb, Intx2MeshOnSphere &worker, EntityHandle euler_set, EntityHandle lagr_set, EntityHandle out_set, Tag &tagElem, Tag &tagArea, int rank, int tStep, Range &connecVerts) |
int | main (int argc, char **argv) |
Variables | |
const char | BRIEF_DESC [] = "Simulate a transport problem in a semi-Lagrangian formulation\n" |
std::ostringstream | LONG_DESC |
double | gtol = 1.e-9 |
double | radius = 1. |
int | numSteps = 3 |
double | T = 1 |
int | case_number = 1 |
bool | writeFiles = false |
bool | parallelWrite = false |
bool | velocity = false |
int | field_type = 1 |
ErrorCode add_field_value | ( | Interface * | mb, |
EntityHandle | euler_set, | ||
int | rank, | ||
Tag & | tagTracer, | ||
Tag & | tagElem, | ||
Tag & | tagArea | ||
) |
Definition at line 61 of file diffusion.cpp.
References moab::IntxAreaUtils::area_spherical_polygon(), moab::Range::begin(), moab::IntxUtils::cart_to_spherical(), moab::Range::end(), ErrorCode, field_type, moab::Core::get_connectivity(), moab::Core::get_coords(), moab::Core::get_entities_by_dimension(), moab::IntxUtils::SphereCoords::lat, moab::IntxUtils::SphereCoords::lon, mb, MB_CHK_ERR, MB_SUCCESS, IntxUtilsCSLAM::quasi_smooth_field(), moab::IntxUtils::SphereCoords::R, radius, moab::Range::size(), IntxUtilsCSLAM::slotted_cylinder_field(), IntxUtilsCSLAM::smooth_field(), moab::IntxUtils::spherical_to_cart(), moab::Core::tag_get_data(), and moab::Core::tag_iterate().
Referenced by main().
ErrorCode compute_tracer_case1 | ( | Interface * | mb, |
Intx2MeshOnSphere & | worker, | ||
EntityHandle | euler_set, | ||
EntityHandle | lagr_set, | ||
EntityHandle | out_set, | ||
Tag & | tagElem, | ||
Tag & | tagArea, | ||
int | rank, | ||
int | tStep, | ||
Range & | connecVerts | ||
) |
Definition at line 242 of file diffusion.cpp.
References moab::Range::begin(), moab::Core::clear_meshset(), CORRTAGNAME, moab::Intx2Mesh::create_departure_mesh_3rd_alg(), moab::Core::delete_entities(), delta_t, IntxUtilsCSLAM::departure_point_case1(), moab::dum, moab::Range::end(), ErrorCode, moab::Core::get_connectivity(), moab::Core::get_coords(), moab::Core::get_entities_by_dimension(), moab::Intx2Mesh::intersect_meshes(), mb, MB_CHK_ERR, MB_TAG_DENSE, MB_TYPE_HANDLE, numSteps, parallelWrite, radius, moab::Core::set_coords(), moab::subtract(), t, T, moab::Core::tag_get_data(), moab::Core::tag_get_handle(), moab::Intx2MeshOnSphere::update_tracer_data(), moab::Core::write_file(), and writeFiles.
Referenced by main().
ErrorCode compute_velocity_case1 | ( | Interface * | mb, |
EntityHandle | euler_set, | ||
Tag & | tagh, | ||
int | rank, | ||
int | tStep | ||
) |
Definition at line 199 of file diffusion.cpp.
References moab::Range::begin(), moab::Range::end(), ErrorCode, moab::Core::get_connectivity(), moab::Core::get_coords(), moab::Core::get_entities_by_dimension(), mb, MB_CHK_ERR, MB_SUCCESS, numSteps, moab::Range::size(), t, T, moab::Core::tag_iterate(), IntxUtilsCSLAM::velocity_case1(), and moab::Core::write_file().
Referenced by main().
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 364 of file diffusion.cpp.
References add_field_value(), ProgOptions::addOpt(), moab::Range::begin(), BRIEF_DESC, moab::ParallelComm::check_all_shared_handles(), compute_tracer_case1(), compute_velocity_case1(), moab::Core::create_meshset(), IntxUtilsCSLAM::deep_copy_set(), moab::Range::end(), ErrorCode, field_type, moab::Intx2Mesh::FindMaxEdges(), moab::Core::get_entities_by_dimension(), moab::ParallelComm::get_pcomm(), gtol, input_file, moab::Core::load_file(), LONG_DESC, mb, MB_CHK_ERR, MB_TAG_CREAT, MB_TAG_DENSE, MB_TYPE_DOUBLE, MESHSET_SET, numSteps, parallelWrite, ProgOptions::parseCommandLine(), moab::ParallelComm::proc_config(), moab::ProcConfig::proc_rank(), radius, moab::Intx2Mesh::set_error_tolerance(), moab::Intx2MeshOnSphere::set_radius_destination_mesh(), moab::Intx2MeshOnSphere::set_radius_source_mesh(), moab::Range::size(), moab::Core::tag_get_data(), moab::Core::tag_get_handle(), moab::Core::tag_iterate(), velocity, and writeFiles.
const char BRIEF_DESC[] = "Simulate a transport problem in a semi-Lagrangian formulation\n" |
Definition at line 44 of file diffusion.cpp.
Referenced by main().
int case_number = 1 |
Definition at line 54 of file diffusion.cpp.
int field_type = 1 |
Definition at line 58 of file diffusion.cpp.
Referenced by add_field_value(), and main().
double gtol = 1.e-9 |
Definition at line 49 of file diffusion.cpp.
Referenced by main().
std::ostringstream LONG_DESC |
Definition at line 45 of file diffusion.cpp.
Referenced by main().
int numSteps = 3 |
Definition at line 52 of file diffusion.cpp.
Referenced by compute_tracer_case1(), compute_velocity_case1(), and main().
bool parallelWrite = false |
Definition at line 56 of file diffusion.cpp.
Referenced by compute_tracer_case1(), and main().
double radius = 1. |
Definition at line 50 of file diffusion.cpp.
Referenced by add_field_value(), compute_tracer_case1(), and main().
double T = 1 |
Definition at line 53 of file diffusion.cpp.
Referenced by moab::SysUtil::byteswap(), moab::SmoothCurve::compute_control_points_on_boundary_edges(), moab::SmoothCurve::compute_tangents_for_each_edge(), moab::SmoothFace::compute_tangents_for_each_edge(), compute_tracer_case1(), compute_velocity_case1(), moab::connectivity_match(), IntxUtilsCSLAM::departure_point_case1(), get_vartag_data(), ProgOptions::getReqArg(), moab::SmoothFace::init_bezier_edge(), moab::ScdNCHelper::kji_to_jik(), moab::UcdNCHelper::kji_to_jik_stride(), moab::TagTypeEqual< T >::operator()(), moab::TagTypeLess< T >::operator()(), moab::TagOneTypeEqual< T >::operator()(), moab::TagOneTypeLess< T >::operator()(), moab::TagVarTypeEqual< T >::operator()(), moab::TagVarTypeLess< T >::operator()(), moab::PACK(), parse_value(), parse_values_typed(), moab::permute_this(), moab::common_tree::print_vector(), moab::ParallelComm::reduce(), moab::WriteUtilIface::reorder(), moab::rev_permute_this(), tensor_c3(), tensor_r3(), moab::UNPACK(), IntxUtilsCSLAM::velocity_case1(), moab::WriteVtk::write_data(), and moab::WriteVtk::write_tag().
bool velocity = false |
Definition at line 57 of file diffusion.cpp.
Referenced by main().
bool writeFiles = false |
Definition at line 55 of file diffusion.cpp.
Referenced by compute_tracer_case1(), and main().