{ "cells": [ { "cell_type": "markdown", "id": "3fcdae59", "metadata": {}, "source": [ "# eval\n", "\n", "\n", "\n", "\n", "**Author:** Rene Brun \n", "This notebook tutorial was automatically generated with ROOTBOOK-izer from the macro found in the ROOT repository on Tuesday, May 19, 2026 at 08:36 PM." ] }, { "cell_type": "code", "execution_count": 1, "id": "76495efd", "metadata": { "collapsed": false, "execution": { "iopub.execute_input": "2026-05-19T20:36:59.734464Z", "iopub.status.busy": "2026-05-19T20:36:59.734281Z", "iopub.status.idle": "2026-05-19T20:37:00.238829Z", "shell.execute_reply": "2026-05-19T20:37:00.229671Z" } }, "outputs": [], "source": [ "TCanvas *c1 = new TCanvas(\"c1\");\n", "c1->Range(0, 0, 20, 10);\n", "TPaveLabel *pt1 = new TPaveLabel(0.2, 4, 3, 6, \"Eval\");\n", "pt1->SetTextSize(0.5);\n", "pt1->SetFillColor(42);\n", "pt1->Draw();\n", "TPaveText *pt2 = new TPaveText(4.5, 4, 7.8, 6);\n", "pt2->Draw();\n", "TText *t1 = pt2->AddText(\"Read Operator\");\n", "TText *t2 = pt2->AddText(\"number i\");\n", "TPaveText *pt3 = new TPaveText(9, 3.5, 17.5, 6.5);\n", "TText *t4 = pt3->AddText(\"Apply Operator to current stack values\");\n", "TText *t5 = pt3->AddText(\"Example: if operator +\");\n", "TText *t6 = pt3->AddText(\"value[i] += value[i-1]\");\n", "t4->SetTextAlign(22);\n", "t5->SetTextAlign(22);\n", "t6->SetTextAlign(22);\n", "t5->SetTextColor(4);\n", "t6->SetTextColor(2);\n", "pt3->Draw();\n", "TPaveLabel *pt4 = new TPaveLabel(4, 0.5, 12, 2.5, \"return result = value[i]\");\n", "pt4->Draw();\n", "TArrow *ar1 = new TArrow(6, 4, 6, 2.7, 0.02, \"|>\");\n", "ar1->Draw();\n", "TText *t7 = new TText(6.56, 2.7, \"if i = number of stack elements\");\n", "t7->SetTextSize(0.04);\n", "t7->Draw();\n", "ar1->DrawArrow(6, 8, 6, 6.2, 0.02, \"|>\");\n", "TLine *l1 = new TLine(12, 6.6, 12, 8);\n", "l1->Draw();\n", "l1->DrawLine(12, 8, 6, 8);\n", "ar1->DrawArrow(3, 5, 4.4, 5, 0.02, \"|>\");\n", "ar1->DrawArrow(7.8, 5, 8.9, 5, 0.02, \"|>\");" ] }, { "cell_type": "markdown", "id": "2a713d24", "metadata": {}, "source": [ "Draw all canvases " ] }, { "cell_type": "code", "execution_count": 2, "id": "189c4122", "metadata": { "collapsed": false, "execution": { "iopub.execute_input": "2026-05-19T20:37:00.255290Z", "iopub.status.busy": "2026-05-19T20:37:00.255103Z", "iopub.status.idle": "2026-05-19T20:37:00.491117Z", "shell.execute_reply": "2026-05-19T20:37:00.489090Z" } }, "outputs": [ { "data": { "text/html": [ "\n", "\n", "