42 lines
1.9 KiB
Plaintext
42 lines
1.9 KiB
Plaintext
|
set terminal epslatex font 8 color dashed
|
||
|
set output './ModeleLaTeX_TP-gnuplottex-fig24.tex'
|
||
|
set format '\num{%g}'
|
||
|
set key top left Left
|
||
|
set key width 3.5
|
||
|
set key heigh 1
|
||
|
set key spacing 1.5
|
||
|
|
||
|
set xlabel 'Vitesse angulaire \(\omega\) (\si{\radian\per\second})' # attention il faut parfois utiliser certains guillemets
|
||
|
# notamment quand on utilise la commande \si, il faut impérativement des primes '...'
|
||
|
set ylabel 'Tension U (\si{\volt})'
|
||
|
|
||
|
# Création du fit des données
|
||
|
# la fonction de fit
|
||
|
f(x)=a*x+b
|
||
|
fit f(x) 'moteur/data_mot_hall_inconnu_TOP.txt' index 1 u 1:2 via a,b
|
||
|
title_f(a,b) = sprintf('\(k = \SI{%.4f}{\volt\second\per\radian}\)', a)
|
||
|
g(x)=c*x+d
|
||
|
fit g(x) 'moteur/data_mot_hall_3.txt' index 0 u 1:2 via c,d
|
||
|
title_g(c,d) = sprintf('\(k = \SI{%.4f}{\volt\second\per\radian}\)',c)
|
||
|
h(x)=e*x+f
|
||
|
fit h(x) 'moteur/data_mot_hall_k_Opitec.txt' index 0 u 1:2 via e,f
|
||
|
title_h(e,f) = sprintf('\(k = \SI{%.4f}{\volt\second\per\radian}\)',e)
|
||
|
k(x)=m*x+n
|
||
|
fit k(x) 'moteur/data_mot_hall_k_Opitec.txt' index 1 u 1:2 via m,n
|
||
|
title_k(m,n) = sprintf('\(k = \SI{%.4f}{\volt\second\per\radian}\)',m)
|
||
|
l(x)=o*x+p
|
||
|
fit l(x) 'moteur/data_mot_hall_k_Opitec.txt' index 2 u 1:2 via o,p
|
||
|
title_l(o,p) = sprintf('\(k = \SI{%.4f}{\volt\second\per\radian}\)',o)
|
||
|
|
||
|
plot [0:450][0:4]\
|
||
|
'moteur/data_mot_hall_inconnu_TOP.txt' index 1 u 1:2 title 'Moteur inconnu série 1' pt 4,\
|
||
|
f(x) title title_f(a,b) lc 'violet',\
|
||
|
'moteur/data_mot_hall_3.txt' index 0 u 1:2:5:6 title 'Moteur inconnu série 2' pt 4 w xyerrorbars,\
|
||
|
g(x) title title_g(c,d) lc 'blue',\
|
||
|
'moteur/data_mot_hall_k_Opitec.txt' index 0 u 1:2:5:6 title 'Moteur Opitec série 0' pt 4 w xyerrorbars,\
|
||
|
h(x) title title_h(e,f) lc 'yellow',\
|
||
|
'moteur/data_mot_hall_k_Opitec.txt' index 1 u 1:2:5:6 title 'Moteur Opitec série 1' pt 4 w xyerrorbars,\
|
||
|
k(x) title title_k(m,n) lc 'red',\
|
||
|
'moteur/data_mot_hall_k_Opitec.txt' index 2 u 1:2:5:6 title 'Moteur Opitec série 2' pt 4 w xyerrorbars,\
|
||
|
l(x) title title_l(o,p) lc 'orange'
|