13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
+
+
+
+
-
+
+
+
+
+
+
+
|
#$Id$
while [ -n "`echo $1 | grep '^-'`" ]; do
case $1 in
-internal )
internal=yes;
;;
-external )
external=yes;
;;
*)
echo "$1 is an invalid argument - ignoring";
exit ;;
esac
shift
done
if [ -n "$internal" ]; then
name=MTT$2"[0-9]"; # echo $name
grep "MTT$2[^(]" $1_ese.r | wc -l
grep -i "$name" $1_ese.r | wc -l
exit
fi
if [ -n "$external" ]; then
name="^MTT"$2"("; #echo $name
grep -i "$name" $1_ese.r | wc -l
exit
fi
## The original version for external sizes.
if [ "$2" = "xx" ]; then
n=`mtt_getsize $1 x`
N=`echo "$n * $n" | bc`
|