@@ -50,7 +50,6 @@ double title_font_size_rk_tol = 0.046;
50
50
int title_font = 132 ;
51
51
int label_font = 132 ;
52
52
int legend_font = 132 ;
53
- double marker_size = 1.9 ;
54
53
double pad_x0 = 0.005f ;
55
54
double pad_x1 = 1.f ;
56
55
double pad_y0 = 0.005f ;
@@ -189,7 +188,9 @@ void draw_graphs(const std::string header_title, const std::string geom_title,
189
188
TGraph * gr [25 ];
190
189
TMultiGraph * mg = new TMultiGraph ();
191
190
192
- const std ::array < int , 5u > marker_styles = {7 , 2 , 5 , 27 , 32 };
191
+ const std ::array < int , 5u > marker_styles = {7 , 2 , 5 , 27 , 25 };
192
+ const std ::array < double , 5u > marker_sizes = {2.135 , 2.135 , 2.135 , 2.135 ,
193
+ 1.49 };
193
194
const std ::array < int , 5u > line_styles = {1 , 3 , 2 , 7 , 4 };
194
195
const std ::array < int , 5u > hues = {kOrange + 2 , kPink + 5 , kBlue + 2 ,
195
196
kCyan + 2 , kGreen + 2 };
@@ -211,7 +212,7 @@ void draw_graphs(const std::string header_title, const std::string geom_title,
211
212
const int m = i % 5 ;
212
213
213
214
gr [i ]-> SetMarkerStyle (marker_styles [n ]);
214
- gr [i ]-> SetMarkerSize (marker_size );
215
+ gr [i ]-> SetMarkerSize (marker_sizes [ n ] );
215
216
gr [i ]-> SetLineStyle (line_styles [m ]);
216
217
gr [i ]-> SetMarkerColor (hues [m ]);
217
218
gr [i ]-> SetLineColor (hues [m ]);
@@ -247,6 +248,10 @@ void draw_graphs(const std::string header_title, const std::string geom_title,
247
248
double x_max = x_vec .back ();
248
249
249
250
if (x_vec .size () > 10 ) {
251
+ if (x_vec .size () == 13 ) {
252
+ x_margin = 2 ;
253
+ }
254
+
250
255
x_min = x_min - x_margin ;
251
256
x_max = x_max + x_margin ;
252
257
mg -> GetXaxis ()-> SetLimits (x_min , x_max );
@@ -255,13 +260,23 @@ void draw_graphs(const std::string header_title, const std::string geom_title,
255
260
256
261
mg -> Draw ("APL" );
257
262
258
- auto ga = new TGaxis (x_vec .front (), yaxis_min - yaxis_margin ,
259
- x_vec .back (), yaxis_min - yaxis_margin ,
260
- x_vec .front (), x_vec .back (), 405 , "N ");
261
- ga -> SetLabelFont (label_font );
262
- ga -> SetLabelSize (label_font_size_rk_tol );
263
- ga -> SetLabelOffset (-0.0065 );
264
- ga -> Draw ();
263
+ if (x_vec .size () == 11 ) {
264
+ auto ga = new TGaxis (x_vec .front (), yaxis_min - yaxis_margin ,
265
+ x_vec .back (), yaxis_min - yaxis_margin ,
266
+ x_vec .front (), x_vec .back (), 405 , "N ");
267
+ ga -> SetLabelFont (label_font );
268
+ ga -> SetLabelSize (label_font_size_rk_tol );
269
+ ga -> SetLabelOffset (-0.0065 );
270
+ ga -> Draw ();
271
+ } else if (x_vec .size () == 13 ) {
272
+ auto ga = new TGaxis (x_vec .front (), yaxis_min - yaxis_margin ,
273
+ x_vec .back (), yaxis_min - yaxis_margin ,
274
+ x_vec .front (), x_vec .back (), 304 , "N ");
275
+ ga -> SetLabelFont (label_font );
276
+ ga -> SetLabelSize (label_font_size_rk_tol );
277
+ ga -> SetLabelOffset (-0.0065 );
278
+ ga -> Draw ();
279
+ }
265
280
266
281
mg -> GetYaxis ()-> SetLabelSize (0 );
267
282
mg -> GetYaxis ()-> SetTickLength (0 );
@@ -284,6 +299,10 @@ void draw_graphs(const std::string header_title, const std::string geom_title,
284
299
double rk_title_deltaX =
285
300
(x_vec .back () - x_vec .front ()) * rk_title_offset_fraction ;
286
301
302
+ if (x_vec .size () == 13 ) {
303
+ rk_title_deltaX = -0.2 ;
304
+ }
305
+
287
306
legend -> Draw ();
288
307
draw_text (rk_title_deltaX + x_vec .front (), rk_title_y , rk_ygap ,
289
308
rk_header_text_size , rk_geom_text_size , header_title , geom_title );
@@ -309,6 +328,11 @@ void draw_mean_step_size(const std::string header_title,
309
328
gr -> GetXaxis ()-> SetTitle ("log_{10}(#font[12]{#tau} [mm])" );
310
329
gr -> GetYaxis ()-> SetTitle ("log_{10}(Mean of avg. step size [mm])" );
311
330
gr -> GetXaxis ()-> SetLimits (x_vec .front () - 0.5 , x_vec .back () + 0.5 );
331
+
332
+ if (x_vec .size () == 13 ) {
333
+ ymin = -4 ;
334
+ }
335
+
312
336
gr -> GetYaxis ()-> SetRangeUser (ymin , ymax );
313
337
gr -> GetYaxis ()-> SetNdivisions (505 );
314
338
gr -> GetXaxis ()-> SetLabelSize (label_font_size_step );
@@ -327,18 +351,32 @@ void draw_mean_step_size(const std::string header_title,
327
351
gr -> GetYaxis ()-> SetLabelFont (label_font );
328
352
329
353
if (x_vec .size () > 10 ) {
330
- gr -> GetXaxis ()-> SetLimits (x_vec .front () - 1 , x_vec .back () + 1 );
354
+ if (x_vec .size () == 13 ) {
355
+ x_margin = 2 ;
356
+ }
357
+
358
+ gr -> GetXaxis ()-> SetLimits (x_vec .front () - x_margin ,
359
+ x_vec .back () + x_margin );
331
360
gr -> GetXaxis ()-> SetLabelSize (0 );
332
361
gr -> GetXaxis ()-> SetTickLength (0 );
333
362
334
363
gr -> Draw ("APL" );
335
364
336
- auto ga = new TGaxis (x_vec .front (), ymin , x_vec .back (), ymin ,
337
- x_vec .front (), x_vec .back (), 405 , "N ");
338
- ga -> SetLabelFont (label_font );
339
- ga -> SetLabelSize (label_font_size_step );
340
- ga -> SetLabelOffset (x_label_offset );
341
- ga -> Draw ();
365
+ if (x_vec .size () == 11 ) {
366
+ auto ga = new TGaxis (x_vec .front (), ymin , x_vec .back (), ymin ,
367
+ x_vec .front (), x_vec .back (), 405 , "N ");
368
+ ga -> SetLabelFont (label_font );
369
+ ga -> SetLabelSize (label_font_size_step );
370
+ ga -> SetLabelOffset (x_label_offset );
371
+ ga -> Draw ();
372
+ } else if (x_vec .size () == 13 ) {
373
+ auto ga = new TGaxis (x_vec .front (), ymin , x_vec .back (), ymin ,
374
+ x_vec .front (), x_vec .back (), 304 , "N ");
375
+ ga -> SetLabelFont (label_font );
376
+ ga -> SetLabelSize (label_font_size_step );
377
+ ga -> SetLabelOffset (x_label_offset );
378
+ ga -> Draw ();
379
+ }
342
380
343
381
} else {
344
382
gr -> Draw ();
0 commit comments