diff --git a/ChangeLog b/ChangeLog index 2d6c95e3..96cbdde5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -36,6 +36,8 @@ FIXED 2012-09-23 fixed wrong chisq output in musrview if expected chisq is present. FIXED 2012-05-30 fixed RRF bug in single histo plotting. FIXED 2012-05-18 fixed wrong forward/backward tag for ROOT-PPC (MUSR-215) +CHANGED 2012-12-11 if multiple SAVE are present in the COMMAND block, append + MINUIT2.OUTPUT file. Added docu for PRINT_LEVEL (MUSR-244). CHANGED 2012-11-19 replaced hard coded gyromagnetic ratio of the muon in the whole code. CHANGED 2012-11-09 when converting to WKM, take the beamline tag to decide diff --git a/doc/examples/test-histo-MusrRoot.msr b/doc/examples/test-histo-MusrRoot.msr index afcda768..4a6e52f3 100644 --- a/doc/examples/test-histo-MusrRoot.msr +++ b/doc/examples/test-histo-MusrRoot.msr @@ -97,10 +97,11 @@ SAVE ############################################################### FOURIER units Gauss # units either 'Gauss', 'MHz', or 'Mc/s' -fourier_power 11 -apodization MEDIUM # NONE, WEAK, MEDIUM, STRONG -plot POWER # REAL, IMAG, REAL_AND_IMAG, POWER, PHASE -range 0 100 +fourier_power 10 +apodization STRONG # NONE, WEAK, MEDIUM, STRONG +plot REAL # REAL, IMAG, REAL_AND_IMAG, POWER, PHASE +dc-corrected true +phase par7 ############################################################### PLOT 0 (single histo plot) diff --git a/doc/examples/test-histo-ROOT-NPP.msr b/doc/examples/test-histo-ROOT-NPP.msr index 29299059..335db7b3 100644 --- a/doc/examples/test-histo-ROOT-NPP.msr +++ b/doc/examples/test-histo-ROOT-NPP.msr @@ -25,15 +25,17 @@ norm 5 backgr.fit 6 lifetimecorrection map 0 0 0 0 0 0 0 0 0 0 -forward 1 +forward 1 data 3419 66000 -t0 3419 +t0 3419.0 fit 0.1 10 packing 250 ############################################################### COMMANDS +PRINT_LEVEL 3 MINIMIZE +SAVE MINOS SAVE @@ -43,5 +45,5 @@ runs 1 range 0 8 -0.3 0.3 ############################################################### -STATISTIC --- 2011-02-06 14:52:54 - chisq = 248.83532814099809, NDF = 197, chisq/NDF = 1.2631234931015132 +STATISTIC --- 2012-12-11 07:58:13 + chisq = 248.8, NDF = 197, chisq/NDF = 1.263124 diff --git a/doc/html/user/MUSR/BmwLibs.html b/doc/html/user/MUSR/BmwLibs.html index df7c3057..75f0619c 100644 --- a/doc/html/user/MUSR/BmwLibs.html +++ b/doc/html/user/MUSR/BmwLibs.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -144,7 +144,7 @@ pre {
- Edit | Attach | Print version | PDF | History: r5 < r4 < r3 < r2 | Backlinks | View wiki text | Refresh | More topic actions + Edit | Attach | Print version | PDF | History: r5 < r4 < r3 < r2 | Backlinks | View wiki text | Refresh | More topic actions
Topic revision: 10 Jul 2011, wojek
@@ -192,7 +192,7 @@ pre { - +

diff --git a/doc/html/user/MUSR/LibFitPofB.html b/doc/html/user/MUSR/LibFitPofB.html index 3118e43e..66ec18f7 100644 --- a/doc/html/user/MUSR/LibFitPofB.html +++ b/doc/html/user/MUSR/LibFitPofB.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -420,7 +420,7 @@ An example XML file looks as follows:
- Edit | Attach | Print version | PDF | History: r16 < r15 < r14 < r13 | Backlinks | View wiki text | Refresh | More topic actions + Edit | Attach | Print version | PDF | History: r16 < r15 < r14 < r13 | Backlinks | View wiki text | Refresh | More topic actions
Topic revision: 10 Jul 2011, wojek
@@ -468,7 +468,7 @@ An example XML file looks as follows: - +

diff --git a/doc/html/user/MUSR/LibZFRelaxation.html b/doc/html/user/MUSR/LibZFRelaxation.html index 26ee2a4a..83a220a9 100644 --- a/doc/html/user/MUSR/LibZFRelaxation.html +++ b/doc/html/user/MUSR/LibZFRelaxation.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -225,7 +225,7 @@ The parameters are:
    Topic revision: 10 Jul 2011, wojek
    @@ -273,7 +273,7 @@ The parameters are:
      - +

      diff --git a/doc/html/user/MUSR/Msr2Data.html b/doc/html/user/MUSR/Msr2Data.html index 4bbfd2d9..a934b4df 100644 --- a/doc/html/user/MUSR/Msr2Data.html +++ b/doc/html/user/MUSR/Msr2Data.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -349,7 +349,7 @@ For reporting bugs or requesting new features and improvements please use the - @@ -419,7 +419,7 @@ For reporting bugs or requesting new features and improvements please use the - +

      diff --git a/doc/html/user/MUSR/MusrFit.html b/doc/html/user/MUSR/MusrFit.html index 930f6e9f..fea36846 100644 --- a/doc/html/user/MUSR/MusrFit.html +++ b/doc/html/user/MUSR/MusrFit.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -980,6 +980,17 @@ A typical example could look like:
       
       The last accepted command in the COMMAND block is SCALE_N0_BKG TRUE | FALSE. This command is only used in conjunction with single-histogram fits. The default is SCALE_N0_BKG TRUE which will result in a scaling of N(t) such that it is given in ns-1, whereas with SCALE_N0_BKG FALSE no scaling is performed and N(t) will be given in bin-1. If the command is not present at all, it will be interpreted as if SCALE_N0_BKG TRUE was present.
       

      + +For debug purposes it is possible to force MINUIT2 to print out additional informations. The COMMAND block command is PRINT_LEVEL <n>, where <n> can have the values 0,1,2, or 3. A typical example could look like:
      +  COMMANDS
      +  MIGRAD
      +  SAVE
      +  PRINT_LEVEL 3
      +  MINOS
      +  SAVE
      +
      +Here the MINOS command will print out lot of additional information to the standard output. Notice there are 2 SAVE commands here. This will write the result of MIGRAD to the MINUIT2.OUTPUT file and at the end append the MINOS results to this file. +

      4.7 The FOURIER Block

      The Fourier transform is done and the results are plotted within musrview —as input data the actual data shown in musrview is used. In the FOURIER block of the msr file all necessary parameters for calculating and presenting the Fourier transform of the data specified in the PLOT block is given. If the FOURIER block is not present in the msr file, either the parameters set in the XML startup file or the system defaults are taken when the Fourier transform is performed. The block starts with the FOURIER keyword and may contain the following entries on the successive lines:
      @@ -1433,7 +1444,7 @@ For reporting bugs or requesting new features and improvements please use the -
      Topic revision: 11 Dec 2012, AndreasSuter
      @@ -1503,7 +1514,7 @@ For reporting bugs or requesting new features and improvements please use the
      - +

      diff --git a/doc/html/user/MUSR/MusrFitAcknowledgements.html b/doc/html/user/MUSR/MusrFitAcknowledgements.html index 15f2e4f8..d4662573 100644 --- a/doc/html/user/MUSR/MusrFitAcknowledgements.html +++ b/doc/html/user/MUSR/MusrFitAcknowledgements.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -142,7 +142,7 @@ pre {
      Topic revision: 10 Jul 2011, wojek
      @@ -190,7 +190,7 @@ pre { - +

      diff --git a/doc/html/user/MUSR/MusrFitSetup.html b/doc/html/user/MUSR/MusrFitSetup.html index e9581265..0edfbf73 100644 --- a/doc/html/user/MUSR/MusrFitSetup.html +++ b/doc/html/user/MUSR/MusrFitSetup.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -332,7 +332,7 @@ musrview test-histo-ROOT-NPP.msr

      Notes

      - 1 : In case only a single user is working at the machine it might be considerable to change the ownership of the ROOT folder so that the user has easy write access to this directory: + 1 : In case only a single user is working at the machine it might be considerable to change the ownership of the ROOT folder so that the user has easy write access to this directory:

      2 : When using GCC ≥ 4.2 please make sure that the environment variables USE_PARALLEL_MINUIT2 and USE_OPENMP are not set! Otherwise MINUIT2 will be compiled with parallelization support and cannot be used together with musrfit afterwards since the musrfit code is not fully thread-safe! When compiled with GCC ≥ 4.2 musrfit itself will parallelize the χ2 calculation.

      @@ -821,7 +821,7 @@ musrview test-histo-ROOT-NPP.msr
      Topic revision: 03 Sep 2012, AndreasSuter
      @@ -869,7 +869,7 @@ musrview test-histo-ROOT-NPP.msr - +

      diff --git a/doc/html/user/MUSR/MusrGui.html b/doc/html/user/MUSR/MusrGui.html index 7025c4d3..1ae17ea0 100644 --- a/doc/html/user/MUSR/MusrGui.html +++ b/doc/html/user/MUSR/MusrGui.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -324,7 +324,7 @@ For reporting bugs or requesting new features and improvements please use the - @@ -394,7 +394,7 @@ For reporting bugs or requesting new features and improvements please use the - +

      diff --git a/doc/html/user/MUSR/QuickStart.html b/doc/html/user/MUSR/QuickStart.html index dadba970..cbf25b16 100644 --- a/doc/html/user/MUSR/QuickStart.html +++ b/doc/html/user/MUSR/QuickStart.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -280,7 +280,7 @@ RUN 2008/lem08_his_8472 MUE4 PSI ROOT-NPP (name beamline institute dat
      Topic revision: 10 Jul 2011, wojek
      @@ -328,7 +328,7 @@ RUN 2008/lem08_his_8472 MUE4 PSI ROOT-NPP (name beamline institute dat - +

      diff --git a/doc/html/user/MUSR/TutorialSingleHisto.html b/doc/html/user/MUSR/TutorialSingleHisto.html index ef5787db..a8b5e081 100644 --- a/doc/html/user/MUSR/TutorialSingleHisto.html +++ b/doc/html/user/MUSR/TutorialSingleHisto.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -281,7 +281,7 @@ This page only summarizes the very basic features and options of the programs co -
      +

      Attachments (6)

      processing
      @@ -303,7 +303,7 @@ This page only summarizes the very basic features and options of the programs co
      Topic revision: 02 Sep 2011, wojek
      @@ -351,7 +351,7 @@ This page only summarizes the very basic features and options of the programs co
      - +

      diff --git a/doc/html/user/MUSR/WebHome.html b/doc/html/user/MUSR/WebHome.html index 47954d00..a15939ba 100644 --- a/doc/html/user/MUSR/WebHome.html +++ b/doc/html/user/MUSR/WebHome.html @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + @@ -133,7 +133,7 @@ pre {
    1. Acknowledgements
    2. --- AS & BMW - last update Nov 19, 2012 +-- AS & BMW - last update Dec 11, 2012
      @@ -156,9 +156,9 @@ pre {
      Topic revision: 19 Nov 2012, AndreasSuter
      +
      Topic revision: 11 Dec 2012, AndreasSuter
      @@ -204,7 +204,7 @@ pre {
      - +

      diff --git a/src/classes/PFitter.cpp b/src/classes/PFitter.cpp index b5f632dc..99aa70c7 100644 --- a/src/classes/PFitter.cpp +++ b/src/classes/PFitter.cpp @@ -229,6 +229,7 @@ Bool_t PFitter::DoFit() } // walk through the command list and execute them + Bool_t firstSave = true; for (UInt_t i=0; iExecute the save command. * + * \param firstSave flag indication if this is the first save call and hence write a fresh MINUIT2.OUTPUT + * * return: true if the valid minuit2 state is found, otherwise returns false. */ -Bool_t PFitter::ExecuteSave() +Bool_t PFitter::ExecuteSave(Bool_t firstSave) { // if any minimization was done, otherwise get out immediately if (!fFcnMin) { @@ -1593,7 +1598,11 @@ Bool_t PFitter::ExecuteSave() ofstream fout; // open minuit2 output file - fout.open("MINUIT2.OUTPUT", iostream::out); + if (firstSave) + fout.open("MINUIT2.OUTPUT", iostream::out); + else + fout.open("MINUIT2.OUTPUT", iostream::out | iostream::app); + if (!fout.is_open()) { cerr << endl << "**ERROR** PFitter::ExecuteSave() couldn't open MINUIT2.OUTPUT file"; cerr << endl; @@ -1826,6 +1835,11 @@ Bool_t PFitter::ExecuteSave() } else { fout << endl << " no correlation coefficients available"; } + fout << endl; + fout << endl << "*************************************************************************"; + fout << endl << " DONE "; + fout << endl << "*************************************************************************"; + fout << endl << endl; // close MINUIT2.OUTPUT file fout.close(); diff --git a/src/include/PFitter.h b/src/include/PFitter.h index 1979e9d1..d968d7f4 100644 --- a/src/include/PFitter.h +++ b/src/include/PFitter.h @@ -124,7 +124,7 @@ class PFitter Bool_t ExecuteRelease(UInt_t lineNo); Bool_t ExecuteRestore(); Bool_t ExecuteScan(); - Bool_t ExecuteSave(); + Bool_t ExecuteSave(Bool_t first); Bool_t ExecuteSimplex(); };