バケット掘削時の掘削土量を算出するEDEMpyスクリプト

Kosuke_IKEDA
Kosuke_IKEDA
Altair Employee

本記事では、Altair MotionSolve - Altair EDEMの連成シミュレーションによりパワーショベルの掘削挙動をシミュレーションした場合の掘削土量を算出する方法を紹介します。

掘削土量を算出には、EDEMのPythonAPIであるEDEMpyを使用します。

Altair InspireのパラメトリックモデリングとAltair HyperStudyのDOEにより、バケット形状を様々に変えた場合の掘削性能を評価できます。掘削土量は重要な掘削性能の1つです。

image

本記事で使用したスクリプト、モデルは下記よりダウンロードいただけます。

edempy_post.py

EDEM.zip

MotionView.zip

 

EDEMpyによるバケット掘削土量算出

下記EDEMpyのサンプルコードです。

from edempy import Deck from edempy import BoxBin import pandas as pd  #load EDEM model deck=Deck('EDEM_IronOre.dem')  #define time time_interval = 0.1 time = [7,9,11] step=[t/time_interval for t in time] 	 #get final step nstep=deck.numTimesteps-1  def calc_binned_mass(s): 	#get Center of Mass of Bucket 	geocom=deck.timestep[s].geometry['bucket'].getCoM()  	#set Bin volume 	boxbin = BoxBin(geocom + [0,0,0],3,3,3)  	#get ID / Position / Mass list 	ids=deck.timestep[nstep].particle[0].getIds() 	pos=deck.timestep[nstep].particle[0].getPositions() 	masses=deck.timestep[nstep].particle[0].mass  	#get ID / Position / Mass in Bin 	binned_ids=boxbin.getBinnedObjects(ids,pos) 	binned_mass=boxbin.getBinnedObjects(masses,pos,queryType='total') 	 	return binned_mass  mass=[calc_binned_mass(s) for s in step]  #write out to csv df=pd.DataFrame({'data':mass}) df.to_csv('edemout.csv',index=False)  

 

任意時刻におけるバケット掘削土量を算出できます。

下記は7sec, 9sec, 11secの時刻における掘削土量を算出できます。指定時刻の数は任意です。

EDEMの出力間隔 0.1secを指定することで、出力すべきフレーム数を取得します。EDEMモデルの出力間隔に合わせてください。

#define time time_interval = 0.1 time = [7,9,11]

 

ジオメトリ名'bucket'の重心位置を取得し、重心位置から指定した寸法の立方体内の粒子の質量を計算します。

ここでは、3m x 3m x 3mとしています。バケットの大きさが変わる場合はこの値を修正します。

	#get Center of Mass of Bucket 	geocom=deck.timestep[s].geometry['bucket'].getCoM()  	#set Bin volume 	boxbin = BoxBin(geocom + [0,0,0],3,3,3)

image

 

粒子のIDと位置を取得し、先に定義したボックス内の質量を算出するスクリプトです。

粒子の種類が複数ある場合は、どの粒子の質量を算出するかの指定が必要です。

1種類の場合は修正不要でそのままご利用いただけます。

	#get ID / Position / Mass list 	ids=deck.timestep[nstep].particle[0].getIds() 	pos=deck.timestep[nstep].particle[0].getPositions() 	masses=deck.timestep[nstep].particle[0].mass  	#get ID / Position / Mass in Bin 	binned_ids=boxbin.getBinnedObjects(ids,pos) 	binned_mass=boxbin.getBinnedObjects(masses,pos,queryType='total')

 

最終的にedemout.csvでファイルが出力されます。7sec, 9sec, 11secの時刻における掘削土量(kg)が書き出されます。

image

 

このファイルの値をHyperStudyから応答として抽出することで、バケット形状変更後の掘削土量をすばやく評価できます。

例:バケットパラメータ(前後長さR、フロント壁長さl1、ボトム円弧r、カットアングルbeta)と掘削土量の関係

imageimage

 

関連記事

パラメトリックバケットモデルの作成方法

Altair ComposeでEDEMpyを使用する方法

 

使用ソフト

Altair EDEM

Altair MotionView/MotionSolve

Altair Inspire

Altair HyperStudy

Altair Compose

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.