FrontISTR / Getting Started
စတင်အသုံးပြုခြင်း
FrontISTR ဖြင့် ပတ္တာတစ်ခုကို ခွဲခြမ်းစိတ်ဖြာပြီး ParaView တွင် stress ဖြန့်ကျက်ပုံကို ကြည့်ပါ။ solver နှင့် အသင့်သုံးနိုင်သော example ရှိလျှင် ပထမဆုံးအကြိမ်အတွက် mesh ကို ကိုယ်တိုင်တည်ဆောက်ရာမှ စရန်မလိုပါ။
01
Solver ကို ပြင်ဆင်ပါ
Windows binary သို့မဟုတ် Windows၊ macOS နှင့် Linux တွင် အသုံးပြုနိုင်သော Docker image ကို ပြင်ဆင်ပါ။
Windows (64-bit)
ZIP ကို extract လုပ်ပါ။ နောက်အဆင့်တွင် example ကို ပြင်ဆင်ပြီးနောက် fistr1.exe နှင့် ပါလာသော DLL အားလုံးကို example folder (01_elastic_hinge) ထဲသို့ ကူးယူပါ။
Docker (Windows / macOS / Linux)
Docker ကို စတင်ပြီး terminal တွင် အောက်ပါ command ကို လုပ်ဆောင်ပါ။ Windows တွင် Docker ကို Linux container mode သို့ထားပြီး PowerShell ကို အသုံးပြုပါ။
docker pull --platform linux/amd64 registry.gitlab.com/frontistr-commons/frontistr/fistr1:master
လက်ရှိ တရားဝင် image ကို amd64 အတွက် build လုပ်ထားပါသည်။ Apple Silicon Mac များတွင် emulation ဖြင့် လုပ်ဆောင်ရသောကြောင့် အချိန်ပိုကြာနိုင်ပါသည်။
Source code မှ build လုပ်ရန်
ဤ operating system များတွင် FrontISTR ကို source code မှ ကိုယ်တိုင် build လုပ်နိုင်ပါသည်။ compiler နှင့် လိုအပ်သော library များတပ်ဆင်ပြီးလျှင် CMake က environment ကို သိရှိပြီး build ကို configure လုပ်ပါမည်။
သင်အသုံးပြုနေသော distribution အတွက် အောက်ပါ command များဖြင့် အခြေခံ tools များကို တပ်ဆင်ပါ။ လက်ရှိ development environment ကို အသုံးပြုပြီး MPI သို့မဟုတ် အခြား optional library များ မထည့်ဘဲ စတင်နိုင်ပါသည်။
Ubuntu / Debian
sudo apt-get update
sudo apt-get install build-essential cmake git gfortran
RHEL / Rocky Linux / AlmaLinux
sudo dnf install gcc gcc-c++ gcc-gfortran make cmake git
အောက်ပါ command များသည် macOS နှင့် Linux တွင် build နှင့် install လုပ်သည့် ဥပမာဖြစ်သည်။ executable များကို home directory အောက်ရှိ bin တွင် ထည့်သွင်းမည်ဖြစ်သောကြောင့် sudo သို့မဟုတ် PATH ပြင်ဆင်ရန် မလိုပါ။ macOS/Windows ပြင်ဆင်မှုနှင့် optional library များအတွက် build guide ကို ကြည့်ပါ။
git clone https://gitlab.com/FrontISTR-Commons/FrontISTR.git
cd FrontISTR
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="$HOME"
cmake --build build --parallel
cmake --install build
ပါလာသော example ကို ပြန်လည် download မလုပ်ဘဲ တိုက်ရိုက် လုပ်ဆောင်နိုင်ပါသည်။ အောက်ပါ command များဖြင့် analysis ကို လုပ်ဆောင်ပြီးနောက် step 04 သို့သွားကာ ParaView တွင် ရလဒ်ကို ကြည့်ပါ။
cd tutorial/01_elastic_hinge
"$HOME/bin/fistr1"
Binary နှင့် container များသည် အမြဲ update လုပ်နေသော master / LATEST version များကို အသုံးပြုပါသည်။ release version များနှင့် အခြား environment များအတွက် download page ကို ကြည့်ပါ။ အခြား version နှင့် environment များ
02
Example ကို download လုပ်ပါ
Example ZIP ကို download လုပ်ပြီး extract လုပ်ပါ။ 01_elastic_hinge folder ထဲရှိ input file သုံးခုကို အသုံးပြုပါ။
Extract လုပ်ပြီးသော 01_elastic_hinge folder ထဲတွင် analysis ကို လုပ်ဆောင်ပါ။ Command line မှ extract လုပ်ပါက macOS နှင့် Linux တွင် unzip ကို အသုံးပြုပါ။
01_elastic_hinge/
hecmw_ctrl.dat- Input နှင့် output file တည်နေရာများ
hinge.cnt- Material၊ load၊ restraint နှင့် analysis setting များ
hinge.msh- Hinge mesh
Command line မှ example ကို ပြင်ဆင်လိုပါက example ကိုထားလိုသော နေရာတွင် အောက်ပါ block တစ်ခုလုံးကို လုပ်ဆောင်ပါ။ archive ကို download လုပ်ပြီး extract လုပ်ကာ example folder ထဲသို့ ဝင်ပေးပါမည်။ ထို့နောက် terminal တစ်ခုတည်းတွင် analysis command ကို ဆက်လုပ်နိုင်ပါသည်။
Windows / PowerShell
curl.exe -fL -o 01_elastic_hinge.zip https://www.frontistr.com/sys/files/01_elastic_hinge.zip
if ($LASTEXITCODE -eq 0) {
Expand-Archive -Path 01_elastic_hinge.zip -DestinationPath . -ErrorAction Stop
cd 01_elastic_hinge
}macOS / Linux
curl -fL -o 01_elastic_hinge.zip https://www.frontistr.com/sys/files/01_elastic_hinge.zip &&
unzip 01_elastic_hinge.zip &&
cd 01_elastic_hinge03
Example folder မှ run လုပ်ပါ
Example folder (01_elastic_hinge) ထဲတွင် analysis ကို လုပ်ဆောင်ပါ။ hecmw_ctrl.dat ရှိကြောင်း စစ်ဆေးပါ။
Windows binary
Example folder ထဲရှိ fistr1.exe ကို double-click လုပ်ပါ။ ပါလာသော DLL များကိုလည်း အတူတူ folder ထဲထားရပါမည်။ လုပ်ဆောင်မှု ပြီးသွားချိန် window ပိတ်သွားပါက example folder ထဲတွင် ထွက်လာသော ရလဒ်များကို ParaView ဖြင့် ဖွင့်ပါ။
Log ကို စစ်ကြည့်လိုလျှင်
Window ချက်ချင်းပိတ်သွားပြီး ရလဒ်မထွက်ပါက သို့မဟုတ် log ကို စစ်လိုပါက example folder ထဲတွင် PowerShell ဖွင့်ပြီး အောက်ပါတို့ကို လုပ်ဆောင်ပါ။
.\fistr1.exeDocker (Windows / macOS / Linux)
docker run --rm --platform linux/amd64 -v "${PWD}:/work" -w /work registry.gitlab.com/frontistr-commons/frontistr/fistr1:master fistr1Example folder ထဲတွင် terminal (Windows တွင် PowerShell) ကိုဖွင့်ပြီး command ကို လုပ်ဆောင်ပါ။ Example folder ကို container ထဲရှိ /work သို့ mount လုပ်မည်ဖြစ်ပြီး ရလဒ်များကို local example folder ထဲတွင် သိမ်းဆည်းပါမည်။
Terminal မှ လုပ်ဆောင်ထားပါက log ၏ နောက်ဆုံးတွင် အောက်ပါ message ပေါ်လာသောအခါ analysis ပြီးဆုံးပါသည်။ ကြာချိန်သည် PC အလိုက် ကွာခြားနိုင်ပါသည်။
FrontISTR Completed !!အဆင်မပြေပါက
Input file မတွေ့ပါက 01_elastic_hinge folder ထဲမှ analysis ကို လုပ်ဆောင်နေကြောင်း စစ်ပါ။ Windows တွင် fistr1.exe နှင့် ပါလာသော DLL အားလုံးကို အဲဒီ folder ထဲသို့ ကူးယူထားကြောင်းလည်း စစ်ပါ။
04
ParaView တွင် result ကို ဖွင့်ပါ
ParaView ကို install လုပ်ပါ။ File → Open ကိုရွေးပြီး example folder ထဲရှိ အောက်ပါ file ကို ဖွင့်ပါ။
hinge_vis_psf.0001.pvtu
ရလဒ်များကို 01_elastic_hinge folder တစ်ခုတည်းထဲတွင် ထုတ်ပေးပါသည်။ ဘေးရှိ hinge_vis_psf.0001 folder လည်း လိုအပ်သောကြောင့် .pvtu file တစ်ခုတည်းကို မရွှေ့ပါနှင့်။ 0000 သည် အစအခြေအနေဖြစ်ပြီး 0001 သည် load တင်ပြီးနောက် ရလဒ်ဖြစ်ပါသည်။
မျက်နှာပြင်နမူနာ: macOS ပေါ်ရှိ ParaView 6.1.0။ Windows နှင့် Linux တွင်လည်း အခြေခံလုပ်ဆောင်ပုံ တူညီပါသည်။
-
04 / 1
File ကို ဖွင့်ပြီးချက်ချင်း မြင်ရသော screen။ ဘယ်ဘက်ရှိ Apply ကို click လုပ်ပါ။
-
04 / 2
Apply ကို click လုပ်ပြီးနောက် ပတ္တာ၏ geometry ပေါ်လာပါသည်။
-
04 / 3
အပေါ် toolbar ရှိ Solid Color ကို NodalMISES သို့ ပြောင်းလျှင် von Mises stress ဖြန့်ကျက်ပုံကို မြင်နိုင်ပါသည်။
အရောင်နှင့် background သည် ParaView setting အလိုက် ကွာနိုင်ပြီး sample image နှင့် တူရန် မလိုပါ။ model မမြင်ရပါက Reset Camera ကို စမ်းကြည့်ပါ။
ပထမဆုံး analysis ပြီးဆုံးပါပြီ
နောက်တစ်ဆင့်အဖြစ် example ထဲရှိ load နှင့် material setting များကို လေ့လာပါ။ manual တွင် ဤ model နှင့် အခြား analysis method များကို ရှင်းပြထားပါသည်။