tadd two-grain collision example - granular - granular dynamics simulation | |
git clone git://src.adamsgaard.dk/granular | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit ad3e64425c18a35f07606f42c4a2319edbd5b2ab | |
parent ac0900f4a7a870c7b5636bb32a0b5de012ba6736 | |
Author: Anders Damsgaard <[email protected]> | |
Date: Fri, 23 Apr 2021 09:54:41 +0200 | |
add two-grain collision example | |
Diffstat: | |
A examples/collision.sh | 18 ++++++++++++++++++ | |
1 file changed, 18 insertions(+), 0 deletions(-) | |
--- | |
diff --git a/examples/collision.sh b/examples/collision.sh | |
t@@ -0,0 +1,18 @@ | |
+#!/bin/sh | |
+set -e | |
+ | |
+id=collision | |
+ | |
+rm -f ${id}.grains.*.{tsv,png} ${id}.mp4 | |
+ | |
+(granulargrain -R -u 0.1; granulargrain -f -x 1.2) | granular -e 4.0 -I 0.1 ${… | |
+ | |
+for f in ${id}.grains.*.tsv; do | |
+ #./granular2img -f '$50' -l 'number of contacts' -t png < "$f" > "${f%… | |
+ #./granular2img -f '$5' -l 'x velocity [m/s]' -t png < "$f" > "${f%.ts… | |
+ ./granular2img -f '$14' -l 'force_x [N]' -t png < "$f" > "${f%.tsv}.pn… | |
+done | |
+ | |
+ffmpeg -y -framerate 5 -i ${id}.grains.%05d.png \ | |
+ -c:v libx264 -r 30 -pix_fmt yuv420p ${id}.mp4 | |
+xdg-open ${id}.mp4 |