'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
mine.root
710
6.8
0.01
20.0
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”);
gStyle->SetPalette(50);
h->SetContour(99);
h->Draw(“CONT4”);
}
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.
Maura