| 124 | *******************************************************************************/ |
| 125 | |
| 126 | int |
| 127 | main(int argc, char* argv[]) |
| 128 | { |
| 129 | // Initialize IBAMR and libraries. Deinitialization is handled by this object as well. |
| 130 | IBTKInit ibtk_init(argc, argv, MPI_COMM_WORLD); |
| 131 | const LibMeshInit& init = ibtk_init.getLibMeshInit(); |
| 132 | |
| 133 | { // cleanup dynamically allocated objects prior to shutdown |
| 134 | |
| 135 | // Parse command line options, set some standard options from the input |
| 136 | // file, initialize the restart database (if this is a restarted run), |
| 137 | // and enable file logging. |
| 138 | Pointer<AppInitializer> app_initializer = new AppInitializer(argc, argv, "IB.log"); |
| 139 | Pointer<Database> input_db = app_initializer->getInputDatabase(); |
| 140 | |
| 141 | // Get various standard options set in the input file. |
| 142 | const bool dump_viz_data = app_initializer->dumpVizData(); |
| 143 | const int viz_dump_interval = app_initializer->getVizDumpInterval(); |
| 144 | const bool uses_visit = dump_viz_data && app_initializer->getVisItDataWriter(); |
| 145 | #ifdef LIBMESH_HAVE_EXODUS_API |
| 146 | const bool uses_exodus = dump_viz_data && !app_initializer->getExodusIIFilename().empty(); |
| 147 | #else |
| 148 | const bool uses_exodus = false; |
| 149 | if (!app_initializer->getExodusIIFilename().empty()) |
| 150 | { |
| 151 | plog << "WARNING: libMesh was compiled without Exodus support, so no " |
| 152 | << "Exodus output will be written in this program.\n"; |
| 153 | } |
| 154 | #endif |
| 155 | const string exodus_filename = app_initializer->getExodusIIFilename(); |
| 156 | |
| 157 | const bool dump_restart_data = app_initializer->dumpRestartData(); |
| 158 | const int restart_dump_interval = app_initializer->getRestartDumpInterval(); |
| 159 | const string restart_dump_dirname = app_initializer->getRestartDumpDirectory(); |
| 160 | const string restart_read_dirname = app_initializer->getRestartReadDirectory(); |
| 161 | const int restart_restore_num = app_initializer->getRestartRestoreNumber(); |
| 162 | |
| 163 | const bool dump_postproc_data = app_initializer->dumpPostProcessingData(); |
| 164 | const int postproc_data_dump_interval = app_initializer->getPostProcessingDataDumpInterval(); |
| 165 | const string postproc_data_dump_dirname = app_initializer->getPostProcessingDataDumpDirectory(); |
| 166 | if (dump_postproc_data && (postproc_data_dump_interval > 0) && !postproc_data_dump_dirname.empty()) |
| 167 | { |
| 168 | Utilities::recursiveMkdir(postproc_data_dump_dirname); |
| 169 | } |
| 170 | const bool use_markers = input_db->getBoolWithDefault("use_markers", false); |
| 171 | |
| 172 | const bool dump_timer_data = app_initializer->dumpTimerData(); |
| 173 | const int timer_dump_interval = app_initializer->getTimerDumpInterval(); |
| 174 | |
| 175 | // Create a simple FE mesh. |
| 176 | ReplicatedMesh mesh(init.comm(), NDIM); |
| 177 | const double dx = input_db->getDouble("DX"); |
| 178 | const double ds = input_db->getDouble("MFAC") * dx; |
| 179 | string elem_type = input_db->getString("ELEM_TYPE"); |
| 180 | const double R = 0.2; |
| 181 | if (NDIM == 2 && (elem_type == "TRI3" || elem_type == "TRI6")) |
| 182 | { |
| 183 | #ifdef LIBMESH_HAVE_TRIANGLE |
nothing calls this directly
no test coverage detected