Section 0: Introduction

In this page, no information is provided about multiexpFD, the graphic user interface for multiexp. Only the text-based version of the program is described. This is because a GUI should not require any explanation.

Section 1: Installation

Section 2: Running multiexp

  1. Write a file with instructions for creating fcn (see section 3)
  2. run:
    multiexp fcn_file_name
  3. write commands at the minuit prompt (see section 4)
As a general rule, time scales are relative; use always the same time unit (ps for example).

Section 3: FCN file

This file defines the experimental data that we want to fit. It is made by a sequence of commands. More than one command can be put on a same line, by separating them with a ";". Lines beginning with "#" are considered comments; the text is copied to the stdout when the file is read, and is not processed.
The command can be any of the following.
scale = scale_value
where scale_value is the distance (in ps) from consecutive bins. For example:
scale = 2.44
  • maxdelta = max_delta_value
    The F can be displaced with respect to its IRF. The program looks for the best fit displacing the functions by an amount δ, less than max_delta_value in ps.
  • lambda_corr λ0 c0 c1 c2 ...
    The measured amplitude can be dependent on wave length λ. lambda_corr defines a correction for this. The amplitude will be multiplied by:
    c0 + c1(λ-λ0) + c2*(λ-λ0)2 + ...
    save data "filename"
    The program can output some data on a file. Writing to files is performed when the user calls the standard command at the minuit prompt. But the definition of the file names must be performed in FCN file. data can be graph, tau, gpfile. By default, files are not saved; they are not saved also if file name is a null string "". graph generates a file with one block for each F, with four columns: λ, F value, best fit, IRF. tau contains all the parameter values. gpfile is a gnuplot command file, that can read "tau" and generate a graph with the DAS.
    load decay "filename" [ (from-to) ] lambda time
    load IRF "filename" [ (from-to) ]
    These commands load the F and the IRF. Since each decay can have a different IRF, a load IRF command must be issued before all the load decay" that have that IRF. For example:
    load IRF "irfA.txt"
    load decay "decay1_irfA.txt" 650 100
    load decay "decay2_irfA.txt" 670 100
    load decay "decay3_irfA.txt" 690 100
    load IRF "irfB.txt"
    load decay "decay1_irfB.txt" 650 100
    load decay "decay2_irfB.txt" 670 100
    load decay "decay3_irfB.txt" 690 100

    The first group of decays has been measured with a given setup, and its IRF has been saved as "irfA.txt". Then, a second group of measures has been performed, with a different setup, and its IRF has been saved as "irfB.txt".

    The (from-to) can be optionally appended to the command, in order to define which lines must be processed.

    For "decay" measurements, "lambda" and "time" must be defined. "lambda" will be used for lambda_corr (if any), while "time" will be used to normalize the resulting A.

    The files with data must contain a column of numbers, representin the counts in each bin. Negative values are excluded from the fit. It's worth noting that a poissonian error is assumed for every count in a bin, and is evaluated as the square root of the counts. So do not normalize or multiply the counts by any amount.

    basename "base_name"
    has effect on all the subsequent load commands. It adds a base name to the file name. For example:
    basename "data/"
    load decay "d1.txt" 680 10
    loads the file "data/d1.txt". This command can be issued anywhere; it has effect until another basename command is issued. To stop the effect of a basename command, use basename ""
    Note: the file names can contain any character different from ". If you want to use the character ", you must type it twice. Example:
    load decay "test"".txt" 680 10

    Section 4: Minuit commands

    Typical minuit commands:
    set title
    1 'tau1' 3000.0 100.3 0 10000
    2 'tau2' 149.0 10.0 0 500
    3 'tau3' 63.0 2.0 0 200
    4 'tau4' 12.0 0.2 0 100

    fix 1

    Parameters can be added, modified, fixed and released at any time. Parameter names can be:
    decay time constants. Adding a tauN adds an exponential to the fit, along with all the A, b, δ
    decay time of the fluorophore used to measure the IRF. It should be fixed if known. If it is not present, it is assumed 0.
    amplitude of 4th decay, with tau4, in 3rd fluorescence measurement.
    background of 3rd fluorescence measurement.
    displacement of 2nd fluorescence measurement with respect to IRF.
    this parameter is accepted but not used by fcn

    When a new tauN is defined, an exponential is added to the fitting function. It is not necessary to define A, b and δ. If they are defined, they can be fixed to any value, and error evaluation can be performed. Anyhow, their value is always calculated, also if the parameter doesn't appear anywhere.

    If a parameter has been defined but it is no more needed, it can be overwritten with a new parameter. For example, if parameter 3 is A2-3, you can do:
    > param
    > 3 'A2-1' 0.02 0.01
    > (remember to press <ENTER> in this line before writing other commands)

    If no other parameter is needed, minuit gives no way to delete it. Multiexp gives a way to make it harmless: it must be overwritten with a new parameter called 'null1' or similar; the value is not important; moreover, the parameter must be set 'fix'. For example, if parameter 3 is no more needed:
    > param
    > 3 'null1' 2 1
    > (remember to press <ENTER> in this line before writing other commands)
    > fix 3

    Multiexp accepts parameters like 'null1', 'null2' and so on, and neglects their value; setting them 'fix' prevents minuit from performing any calculation on them.

    The parameters τ must be always different from one another. If you define two of them with the same value, you will likely obtain a "singular matrix" error, that means you have a manifold of solutions.

    The parameters A are the amplitude of the exponential function in which the measured function is decomposed, with a normalization constant. The normalization constant contains the following terms:

    The user should never define UP with "set err 13.5" or similar. The correct value of UP is defined by the program in order to give the 68% confidence.

    The command standard performs the following operations:

    This can be used for drawing graphs. The user must provide a working Makefile that converts the saved files to graphs and shows them.