~ubuntu-branches/ubuntu/trusty/rheolef/trusty

1
2
3
4
5
6
7
8
9
10
11
12
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
set terminal epslatex color standalone
set output "cvge-dirichlet-nh-h1.tex"

set logscale
set key bottom
set size square
set xrange [1e-2:1e-1]
set yrange [1e-8:1e-0]
set xlabel '[c]{$h$}'
set  label '[l]{$|u_h-\pi_h(u)|_{1,2,\Omega}$}' at graph 0.05,0.9

set xtics (\
	'[l]{$10^{-2}$}' 1e-2, \
	'[r]{$10^{-1}$}' 1e-1)
set ytics (\
	'[r]{$10^{-8}$}' 1e-8, \
	'[r]{$10^{-6}$}' 1e-6, \
	'[r]{$10^{-4}$}' 1e-4, \
	'[r]{$10^{-2}$}' 1e-2, \
	'[r]{$10^{0}$}' 1e-0)

graph_ratio = 1.0/8.0

# triangle a droite, pente +1
slope_A = graph_ratio*1.0
xA =  0.12
yA =  0.70
dxA = 0.10
dyA = dxA*slope_A
set label "[l]{\\scriptsize $1=k$}" at graph xA+dxA+0.02, yA+0.5*dyA right
set arrow from graph xA,     yA to     graph xA+dxA, yA     nohead
set arrow from graph xA+dxA, yA to     graph xA+dxA, yA+dyA nohead
set arrow from graph xA+dxA, yA+dyA to graph xA,     yA     nohead

# triangle a droite, pente +2
slope_B = graph_ratio*2.0
xB =  0.12
yB =  0.42
dxB = 0.10
dyB = dxB*slope_B
set label "[l]{\\scriptsize $2$}" at graph xB+dxB+0.02, yB+0.5*dyB right
set arrow from graph xB,     yB to     graph xB+dxB, yB     nohead
set arrow from graph xB+dxB, yB to     graph xB+dxB, yB+dyB nohead
set arrow from graph xB+dxB, yB+dyB to graph xB,     yB     nohead

# triangle a droite, pente +3
slope_C = graph_ratio*3.0
xC =  0.12
yC =  0.20
dxC = 0.10
dyC = dxC*slope_C
set label "[l]{\\scriptsize $3$}" at graph xC+dxC+0.02, yC+0.5*dyC right
set arrow from graph xC,     yC to     graph xC+dxC, yC     nohead
set arrow from graph xC+dxC, yC to     graph xC+dxC, yC+dyC nohead
set arrow from graph xC+dxC, yC+dyC to graph xC,     yC     nohead

plot \
 "cvge-dirichlet-nh-P1-ut.gdat" u (1./$1):($3) t "[r]{$k=1$}" w lp, \
 "cvge-dirichlet-nh-P2-ut.gdat" u (1./$1):($3) t "[r]{$k=2$}" w lp, \
 "cvge-dirichlet-nh-P3-ut.gdat" u (1./$1):($3) t "[r]{$k=3$}" w lp

#pause -1 "<retour>"