[FEM] enable to run Elmer multi-threaded

- this needs proper testing, especially on a non-Windows system

- note that for some tasks multi-threading requires non-standard additional solvers like MUMPS. Ideally the user should be informed about this, depending on the equations he uses. But this should not block this PR, meaning to use multi-threading in general.
This commit is contained in:
Uwe
2022-07-10 17:25:19 +02:00
parent 74e77f0191
commit eec258ab37
11 changed files with 401 additions and 231 deletions

View File

@@ -53,6 +53,7 @@
# include <vtkRectilinearGrid.h>
# include <vtkUnstructuredGrid.h>
# include <vtkXMLUnstructuredGridReader.h>
# include <vtkXMLPUnstructuredGridReader.h>
# include <vtkXMLUnstructuredGridWriter.h>
# include <vtkPointData.h>
# include <vtkCellData.h>
@@ -215,6 +216,14 @@ FemMesh* FemVTKTools::readVTKMesh(const char* filename, FemMesh* mesh)
}
importVTKMesh(dataset, mesh);
}
else if (f.hasExtension("pvtu")) {
vtkSmartPointer<vtkDataSet> dataset = readVTKFile<vtkXMLPUnstructuredGridReader>(filename);
if (!dataset.Get()) {
Base::Console().Error("Failed to load file %s\n", filename);
return nullptr;
}
importVTKMesh(dataset, mesh);
}
else if(f.hasExtension("vtk"))
{
vtkSmartPointer<vtkDataSet> dataset = readVTKFile<vtkDataSetReader>(filename);