From db49cd6cbc99fbd7a0fe8821053f096de821ce6d Mon Sep 17 00:00:00 2001 From: hackbard Date: Fri, 23 Oct 2009 14:22:17 +0200 Subject: [PATCH] check whether transformed selective dynamics are used and change offset --- vasp_tools/visualize_contcar | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/vasp_tools/visualize_contcar b/vasp_tools/visualize_contcar index d272d18..f25d155 100755 --- a/vasp_tools/visualize_contcar +++ b/vasp_tools/visualize_contcar @@ -223,7 +223,14 @@ EOF # atoms ((count=1)) - ((offset=8)) + checktsd=`sed -n 7p $file | awk '{ print $1 }'` + if [ "$checktsd" = "Transformed" ]; then + ((offset=9)) + echo "tsd: yes, offset = $offset" + else + ((offset=8)) + echo "tsd: no, offset = $offset" + fi while [ "1" ]; do echo -en "$count " -- 2.39.2