天天看點

Elmer仿真流程

Elmer仿真流程

個人認為在有限元仿真任務中建立模型幾何步驟是基礎也是非常關鍵的一步,後面的實體場設定、材料參數、邊界條件都可以根據自己所在研究領域的專業知識得出。

在使用ElmerGui過程中發現程式還不是很穩定,處理有些網格模型會出錯自動關閉程式,上圖中總結的流程是筆者自己測試後得出的比較靠譜的方法,主要是用gmsh生成網格後導出inp(推薦)或者unv格式,然後再用ElmerGrid進行轉化,當然,對于簡單的模型(例如單實體)也可以嘗試直接使用ElmerGui打開inp、unv、step檔案(簡單的可以直接打開step檔案,但稍微複雜點ElmerGui程式在生成網格的時候就崩了),總之如果直接導入不行的話就自己經過前面的步驟手動轉化為适合elmer solver處理的*.mesh.*格式模型檔案。

Q:為什麼不使用FreeCAD FEM工作台得到的網格檔案?

A:FreeCAD可以導出FEM生成的網格檔案,但是發現導出後的模型隻有一個實體了,對于多實體模型是不适用的,比如一個模型中有三種不同參數的材料,如果隻有一個實體,那麼在後面設定材料參數的時候可選擇的實體(body)也隻有一個,這明顯不符合仿真要求,當然對于單實體模型是可以的。

Q:ElmerGrid指令參數含義?

A:指令行執行ElmerGrid後有以下資訊:

Starting program Elmergrid
****************** Elmergrid ************************
This program can create simple 2D structured meshes consisting of
linear, quadratic or cubic rectangles or triangles. The meshes may
also be extruded and revolved to create 3D forms. In addition many
mesh formats may be imported into Elmer software. Some options have
not been properly tested. Contact the author if you face problems.

The program has two operation modes
A) Command file mode which has the command file as the only argument
   'ElmerGrid commandfile.eg'

B) Inline mode which expects at least three input parameters
   'ElmerGrid 1 3 test'

The first parameter defines the input file format:
1)  .grd      : Elmergrid file format
2)  .mesh.*   : Elmer input format
3)  .ep       : Elmer output format
4)  .ansys    : Ansys input format
5)  .inp      : Abaqus input format by Ideas
6)  .fil      : Abaqus output format
7)  .FDNEUT   : Gambit (Fidap) neutral file
8)  .unv      : Universal mesh file format
9)  .mphtxt   : Comsol Multiphysics mesh format
10) .dat      : Fieldview format
11) .node,.ele: Triangle 2D mesh format
12) .mesh     : Medit mesh format
13) .msh      : GID mesh format
14) .msh      : Gmsh mesh format
15) .ep.i     : Partitioned ElmerPost format
16) .2dm      : 2D triangular FVCOM format

The second parameter defines the output file format:
1)  .grd      : ElmerGrid file format
2)  .mesh.*   : ElmerSolver format (also partitioned .part format)
3)  .ep       : ElmerPost format
4)  .msh      : Gmsh mesh format
5)  .vtu      : VTK ascii XML format

The third parameter is the name of the input file.
If the file does not exist, an example with the same name is created.
The default output file name is the same with a different suffix.
...
           

不想翻譯了,關于其他參數的詳細解釋可以參考官方幫助文檔

ElmerGrid Manual.pdf

,目前我也隻了解使用

-autoclean

參數可以消除一些不同格式之間轉化的錯誤問題。

本文主要記錄自己在elmer上處理多實體問題的心得體會,使用開源/免費軟體不像使用COMSOL那般一帆風順,有很多坑要踩,不斷折騰不斷學習!

繼續閱讀