Commit 0429a6f2 authored by Sergey Kireev's avatar Sergey Kireev
Browse files

scripts modified

parent 8a2d2fd2
#!/bin/bash
source ./do_parameters.sh
fromdir="dat_${nt}"
todir="png2d_${nt}"
[ ! -d ${fromdir} ] && { echo "Directory ${fromdir} does not exist!" ; exit ; }
[ -d ${todir} ] && { echo "Terget directory ${todir} already exist!" ; exit ; }
mkdir ${todir}
LC_NUMERIC="en_US.UTF-8"
count=0
for (( en100=${minn}; en100 <= ${maxn}; en100 += ${step} )); do
en1=`echo "scale=2; ${en100}/100" | bc`
en=`printf "%04.2f" ${en1}`
val[$count]=$en
count=$((count + 1))
done
for inn in `seq 0 $((count - 1))`; do
echo "en:" ${val[$inn]}
enn=${val[$inn]}
inls=`seq 0 $inn`
nls=`for i in $inls; do echo -n "${val[$i]} "; done`
ills=`seq 0 $inn`
lls=`for i in $ills; do echo -n "${val[$i]} "; done`
target="${todir}/en${enn}_enl_el"
#echo " nls: ${nls[*]}"
#echo " lls: ${lls[*]}"
gnuplot -e "name=\"${target}\"; nx=${nx}; ny=${ny}; ppp=${ppp}; \
rows=\"${nls}\"; cols=\"${lls}\"; rlabel=\"e_{nl}=\"; clabel=\"e_{l}=\"; \
format=\"${fromdir}/en${enn}_enl%s_el%s${suffix}\";" $script_png2d
# [ ! -d ${todir} ] && mkdir ${todir}
# mv ${name}.png ${todir}/
done
for inl in `seq 0 $((count - 1))`; do
echo "enl:" ${val[$inl]}
enl=${val[$inl]}
inns=`seq $inl $((count - 1))`
nns=`for i in $inns; do echo -n "${val[$i]} "; done`
ills=`seq 0 $inl`
lls=`for i in $ills; do echo -n "${val[$i]} "; done`
target="${todir}/en_enl${enl}_el"
#echo " nns: ${nns[*]}"
#echo " lls: ${lls[*]}"
gnuplot -e "name=\"${target}\"; nx=${nx}; ny=${ny}; ppp=${ppp}; \
rows=\"${nns}\"; cols=\"${lls}\"; rlabel=\"e_{n}=\"; clabel=\"e_{l}=\"; \
format=\"${fromdir}/en%s_enl${enl}_el%s${suffix}\";" $script_png2d
# [ ! -d ${todir} ] && mkdir ${todir}
# mv ${name}.png ${todir}/
done
for ill in `seq 0 $((count - 1))`; do
echo "el:" ${val[$ill]}
ell=${val[$ill]}
inls=`seq $ill $((count - 1))`
nls=`for i in $inls; do echo -n "${val[$i]} "; done`
inns=`seq $ill $((count - 1))`
nns=`for i in $inns; do echo -n "${val[$i]} "; done`
target="${todir}/en_enl_el${ell}"
#echo " nns: ${nns[*]}"
#echo " nls: ${nls[*]}"
gnuplot -e "name=\"${target}\"; nx=${nx}; ny=${ny}; ppp=${ppp}; \
rows=\"${nns}\"; cols=\"${nls}\"; rlabel=\"e_{n}=\"; clabel=\"e_{nl}=\"; \
format=\"${fromdir}/en%s_enl%s_el${ell}${suffix}\";" $script_png2d
# [ ! -d ${todir} ] && mkdir ${todir}
# mv ${name}.png ${todir}/
done
......@@ -58,10 +58,10 @@ for inn in `seq 0 $((count_en - 1))`; do
enn=${val_en[$inn]}
echo "en: ${enn}"
inls=`seq 0 $((count_enl - 1))`
inls=`seq 0 $inn`
nls=`for i in $inls; do echo -n "${val_enl[$i]} "; done`
ills=`seq 0 $((count_el - 1))`
ills=`seq 0 $inn`
lls=`for i in $ills; do echo -n "${val_el[$i]} "; done`
#ievs=`seq 0 $((count_en - 1))`
......@@ -86,10 +86,10 @@ for inl in `seq 0 $((count_enl - 1))`; do
enl=${val_enl[$inl]}
echo "enl: ${enl}"
inns=`seq 0 $((count_en - 1))`
inns=`seq $inl $((count_en - 1))`
nns=`for i in $inns; do echo -n "${val_en[$i]} "; done`
ills=`seq 0 $((count_el - 1))`
ills=`seq 0 $inl`
lls=`for i in $ills; do echo -n "${val_el[$i]} "; done`
#ievs=`seq 0 $((count_evap - 1))`
......@@ -116,10 +116,10 @@ for ill in `seq 0 $((count_el - 1))`; do
el=${val_el[$ill]}
echo "el: ${el}"
inls=`seq 0 $((count_enl - 1))`
inls=`seq $ill $((count_enl - 1))`
nls=`for i in $inls; do echo -n "${val_enl[$i]} "; done`
inns=`seq 0 $((count_en - 1))`
inns=`seq $ill $((count_en - 1))`
nns=`for i in $inns; do echo -n "${val_en[$i]} "; done`
target="${todir}/en_enl_el${el}"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment