root / examples / Test / Dep_tgt.awk @ 3
Historique | Voir | Annoter | Télécharger (592 octet)
| 1 |
BEGIN{
|
|---|---|
| 2 |
it=-1 |
| 3 |
pi=3.14159265358979 |
| 4 |
} |
| 5 |
{ if ($1=="PATHNAME") { i=index($3,","); if (i==0) {Nom=$3} else {Nom=substr($3,1,i-1) }; Nom=Nom "_tgt_";next}
|
| 6 |
} |
| 7 |
|
| 8 |
/Visualization of tangents/,/END of tangents/ {
|
| 9 |
if ($1=="Visualization") { it++; File=Nom it ".dat";
|
| 10 |
print "#Tangents for Iopt=" it > File; next;} |
| 11 |
if ($1=="END") { next }
|
| 12 |
if (NF==0) {print "" >> File; next}
|
| 13 |
printf(" %12.5f %12.5f %12.5f",$1*1.,$2*1.,$3*180./pi) >> File
|
| 14 |
for(j=4;j<=NF;j+=3) { printf(" %12.5f %12.5f %12.5f",$j*1.,$(j+1)*180./pi,$(j+2)*180./pi) >> File }
|
| 15 |
print "" >> File |
| 16 |
} |
| 17 |
END{
|
| 18 |
} |
| 19 |
|