Drawing options

'm plotting the radiation distribution in the air surrounding a circle with a homogeneous radiation distribution.
My source code can be found at
home.fnal.gov/~mauede/APD-Dir/Ci … rces-new.C

The input file is:

cat My-answers.txt

The hbook can be found at home.fnal.gov/~mauede/APD-Dir/mine.root

If I plot the results by the following commans sequence:

cat Run-Macro.C
TFile f(“plots.root”);
TH2D h= (TH2D)f->Get(“Extended”);

then nothing is plotted and I get a lot of errors messages:

root [0] .x Run-Macro.C
: created default TCanvas with name c1
Warning in : Inf/NaN propagated to the pad. Check drawn objects.
Warning in : c1 width changed from 0 to 10

Warning in : c1 height changed from 0 to 10

Error in : number of points for line not equal 2
Error in : number of points for line not equal 2
Error in : number of points for line not equal 2
Error in : number of points for line not equal 2

If I change the drawing option to “LEGO” I get the same result. But if I change it to "COL"
then I get nice picture. See home.fnal.gov/~mauede/APD-Dir/Ci … es-new.png

Nevertheless, if I click on the top menu bar option “File” to save my picture, no menu is dropped down. Instead I get a bunch of errors:
root [7]
*** Break *** segmentation violation
Generating stack trace…
0xb7928096 in TList::FindLink(TObject const*, int&) const at cont/src/TList.cxx:464 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb792842e in TList::Remove(TObject*) at cont/src/TList.cxx:558 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb5caeabe in TGClient::UnregisterPopup(TGWindow*) at gui/src/TGClient.cxx:478 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5d28fbc in TGPopupMenu::EndMenu(void*&) at gui/src/TGMenu.cxx:1028 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5d2b692 in TGMenuTitle::SetState(bool) at gui/src/TGMenu.cxx:1695 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5d268e5 in TGMenuBar::HandleButton(Event_t*) at gui/src/TGMenu.cxx:405 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5cdc24b in TGFrame::HandleEvent(Event_t*) at gui/src/TGFrame.cxx:444 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5caf783 in TGClient::HandleEvent(Event_t*) at gui/src/TGClient.cxx:746 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5caf2cb in TGClient::ProcessOneEvent() at gui/src/TGClient.cxx:586 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5caf425 in TGClient::HandleInput() at gui/src/TGClient.cxx:632 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb5cad608 in TGInputHandler::Notify() at gui/src/TGClient.cxx:79 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libGui.so
0xb79da16b in TUnixSystem::DispatchOneEvent(bool) at unix/src/TUnixSystem.cxx:738 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb78e01a3 in TSystem::InnerLoop() at base/src/TSystem.cxx:319 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb78e012e in TSystem::Run() at base/src/TSystem.cxx:287 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb784bdaf in TApplication::Run(bool) at base/src/TApplication.cxx:826 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libCore.so
0xb627ca2b in TRint::Run(bool) at rint/src/TRint.cxx:285 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/lib/libRint.so
0x08048e9b in main + 0xb7 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/bin/root.exe
0x0077be23 in __libc_start_main + 0xd3 from /lib/tls/libc.so.6
0x08048d51 in TApplicationImp::ShowMembers(TMemberInspector&, char*) + 0x31 from /afs/fnal.gov/ups/root/v5_10_00a/Linux+2.4-2.3.2-GCC_3_4_3-debug/bin/root.exe

If you look at my source code you’ll see a lot of “catch” statements aimed at finding “inf” and “nan” occurrences which are likely to happen when working with Doubles.
But the Log file is clean. So I’m left speechless …

Many thanks to anyone who helps me understand the difference among the many drawing options.

Where is plots.root? what is mine.root?


My program output is saved to an external file “plots.root” that is then used to generate the isocontours.
The last version can be found on my website:

as well as “mine.root” which is the Root version of the HBOOK archive storing the original circle 2-D histogram.
Actually at the moment such histogram is only used to get the maximum radiation value, and some core information (bin-width, height, …)

Thank you.

Your histogram “Extended” in plots.root has many bind with infinite values.
To see what I mean, do:

TFile f("plots.root"); TH2D *h= (TH2D*)f->Get("Extended"); h->Print("all"); >x.log
then see the file.log and look at bins, eg

fSumw[119][107]=-1.#IND, x=-3.944, y=-5.576 fSumw[120][107]=-1.#IND, x=-3.808, y=-5.576 fSumw[121][107]=68596.5, x=-3.672, y=-5.576

So you should fix the problem in the source histogram.