summaryrefslogtreecommitdiff
path: root/report/Figures/3.gnu
diff options
context:
space:
mode:
authorConnor Moore <connor@hhmoore.ca>2026-03-23 01:40:30 -0400
committerConnor Moore <connor@hhmoore.ca>2026-03-23 01:40:30 -0400
commit5b08f435327695bb633cd21ae8252b25528de3f6 (patch)
tree7eb5cdfa0acded8eaf8f1881e8542fe7b441d67c /report/Figures/3.gnu
parentf7ad40d801e30f542baaf471e0b0d08aacc212ee (diff)
New report and code for final submission.HEADmaster
Diffstat (limited to 'report/Figures/3.gnu')
-rw-r--r--report/Figures/3.gnu62
1 files changed, 62 insertions, 0 deletions
diff --git a/report/Figures/3.gnu b/report/Figures/3.gnu
new file mode 100644
index 0000000..4956337
--- /dev/null
+++ b/report/Figures/3.gnu
@@ -0,0 +1,62 @@
+#set term x11 persist
+set term cairolatex pdf size 7in,2in
+set output "fig43.tex"
+
+set multiplot layout 1,2 margins 0.1, 0.9, 0.1, 0.8 spacing 0.10, 0.0
+
+set datafile separator ","
+set datafile missing NaN
+
+ptsize = 0.5
+
+# R ColorBrewer theme (minus yellow)
+set linetype 1 lc rgb '#E41A1C' pt 7 ps ptsize
+set linetype 2 lc rgb '#377EB8' pt 7 ps ptsize
+set linetype 3 lc rgb '#4DAF4A' pt 7 ps ptsize
+set linetype 4 lc rgb '#984EA3' pt 7 ps ptsize
+set linetype 5 lc rgb '#FF7F00' pt 7 ps ptsize
+set linetype 6 lc rgb '#A65628' pt 7 ps ptsize
+set linetype 7 lc rgb '#F781BF' pt 7 ps ptsize
+set linetype 8 lc rgb '#999999' pt 7 ps ptsize
+set linetype 9 lc rgb '#8DD3C7' pt 7 ps ptsize
+set linetype 10 lc rgb '#BEBADA' pt 7 ps ptsize
+set linetype 11 lc rgb '#FB8072' pt 7 ps ptsize
+
+#set format x "$10^{%L}$"
+#set format y "$10^{%L}$"
+
+set xlabel "Number of Threads"
+set ylabel "Wall Time [s]"
+set xtics 0,2
+set xrange [0.5:9.5]
+set yrange [-45:450]
+#set logscale xy
+unset key
+set grid
+
+#sectors = "1 4 16 64 256 1024"
+#particles = "1 4 16 64 256 1024 2048 4096"
+particles = "1024 2048 4096"
+sectors = "16"
+
+# remove header, sectors, particles
+plot for [n in particles] sprintf("< awk -F',' 'NR > 1 && $4 == %d && $2 == %d && $3 <= 8 && $3 >=2 ' joedata.csv", int(sectors),int(n)) \
+ using 3:5 with linespoints title n." Particles"
+
+# SPEEDUP PLOT
+set ylabel "Speedup (vs. 2 threads)"
+set yrange [0.5:4.5]
+set format y "%.1f"
+set offsets graph 0.05, graph 0.05, graph 0.05, graph 0.05
+set key at screen 0.5, screen 0.925 center top vertical maxrows 1
+
+plot for [n in particles] \
+ baseline = real(system(sprintf("awk -F',' 'NR > 1 && $4 == %d && $2 == %d && $3 == 2 {print $5}' joedata.csv", int(sectors), int(n)))), \
+ sprintf("< awk -F',' 'NR > 1 && $4 == %d && $2 == %d && $3 <= 8 && $3 >=2' joedata.csv", int(sectors), int(n)) \
+ using 3:(baseline / $5) with linespoints title n." Particles", [2:8] 0.5*x with lines dt 2 lc rgb 'black' notitle
+#plot for [n in particles] \
+# baseline = system(sprintf("< awk -F',' 'NR > 1 && $4 == %d && $2 == %d && $3 == 2' joedata.csv", int(sectors),int(n))), \
+# sprintf("< awk -F',' 'NR > 1 && $4 == %d && $2 == %d && $3 <= 8' joedata.csv", int(sectors),int(n)) \
+# using 3:(baseline/$5) with linespoints title n." Particles"
+
+unset multiplot