Merge lp:~maddevelopers/mg5amcnlo/FKS5 into lp:mg5amcnlo/lts

Proposed by Olivier Mattelaer
Status: Merged
Merged at revision: 182
Proposed branch: lp:~maddevelopers/mg5amcnlo/FKS5
Merge into: lp:mg5amcnlo/lts
Diff against target: 341349 lines
To merge this branch: bzr merge lp:~maddevelopers/mg5amcnlo/FKS5
Reviewer Review Type Date Requested Status
Johan Alwall (community) Needs Fixing
Olivier Mattelaer Needs Fixing
Review via email: mp+97762@code.launchpad.net

Description of the change

Hi guys,

Since I start to implement things in the code, I start to have a bunch of comment.
So I propose to open a merge discussion on the current situation. I realize that this is not in the merge status but this will allow to better keep track of the (probably long) e-change of email.

When you will be ready for the real merge. We can open thread if you like. (or continue on this one, this is as you want.

To post a comment you must log in.
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :
Download full text (6.5 KiB)

Hi guys,

So this is my first round of observation:

If you read the review that I did in the past, you will not be surprise that I have usually A LOT of comment, since you did a lot of (great) work, this will means a huge numbers of comments.

So In each email, I will put a number with each comment and will keep those number unique.
Let's try to future email to keep track of the un-resolve comment at the end of the mails.
This will ensure that we will not drop some comments in the flow.

So let's start:

1) in loop_exporters, will not makes sense to have one routine by file written?
2) dans loop_num.inc, they are text after the column 77 (with a lot of space in the line)
3) Why using LW and not explicitely ZERO?
4) ALL the HELP/ Completion
   --> Help are VERY important and are for the moment only LO...
5) in master_cmd:
   I think that we need to separate the dummy function from those which are really modified.
   (this will be much more clear and much more easy to see what happen in the future)
6) Error in the input format should raised self.InvalidCmd and NOT MadGraph5Error!!!
(in debug mode this doesn't change anything but in production mode it does)

7) in master_cmd:
   You have:
    def do_generate(self, line, *args, **opts):

        argss = cmd.Cmd.split_arg(line)
        # Make sure to switch to the right interface.
        if len(argss)>=1:
            proc_line = ' '.join(argss[1:])
            (type,nlo_mode,orders)=self.extract_process_type(proc_line)
            if type=='NLO':
                if not nlo_mode in self._valid_nlo_modes: raise MadGraph5Error, \
                    'The NLO mode %s is not valid. Please chose one among: %s' \
                    % (nlo_mode, ' '.join(valid_nlo_modes))

    Two points here:
    a) this should be a self.InvalidCmd and not MadGraph5Error (as point above)
    b) the last line should be % (nlo_mode, ' '.join(self._valid_nlo_modes))

8) File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/core/base_objects.py", line 2529, in has_multiparticle_label
    return false
should be False

9) one error that I don't understand:
generate p p > u u~ [virt=QCD]
Traceback (most recent call last):
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/extended_cmd.py", line 518, in onecmd
    return cmd.Cmd.onecmd(self, line)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/cmd.py", line 219, in onecmd
    return func(arg)
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/master_interface.py", line 338, in do_generate
    return self.cmd.do_generate(self, line, *args, **opts)
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/Loop_interface.py", line 58, in do_generate
    mg_interface.MadGraphCmd.do_generate(self, *args,**opt)
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/madgraph_interface.py", line 2275, in do_generate
    self.do_add(" ".join(args))
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/master_interface.py", line 287, in do_add
    return self.cmd.do_add(self, line, *args, **opts)
  File "/Users/omatt/Documents/Eclipse/CMS_NLO/madgraph/interface/Lo...

Read more...

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
177. By mattelaer-olivier

fix the drawing (after an output is done)
remove the versioned file present in loop_material/CutTools/includects/

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :

Hi again, here is some additional points:

19) in file process_check at line 406 you have:
        from tests.parallel_tests.loop_me_comparator import LoopMG5Runner
    I don't like the idea to have some code present in the tests directory.
    In fact, we should be able to remove this directory for any release. We didn't do that yet,
    but we should. so please re-factorize that.

20) File "/Users/omatt/Documents/Eclipse/CMS_NLO/tests/parallel_tests/loop_me_comparator.py"
    line 39, in <module>
    import madgraph.iolibs.misc as misc
   this files is now madgraph.various.misc.py (this probably passes the 1.4.3 merging)
   I checked that's the only wrong import related

21) the routine def has_multiparticle_label(self):
    in core/base_objects
returns either None or False.... this does not seems right. (So this is the routine that need to be checked). Will also be useful to add a simple unit test for this routine ;-)

Note: concerning my comment #9
a) this might be due to the point 21
b) I obtained the same error if I call
HelasMatrixElement
instead of LoopHelasMatrixElement.

lp:~maddevelopers/mg5amcnlo/FKS5 updated
178. By Valentin Hirschi <email address hidden>

1. Fixed Olivier's latest push
2. Now FKS5 can generate the real only starting from a tree-level model.

179. By Valentin Hirschi <email address hidden>

1. Fixing 1) to 11) of Olivier's review points (except for 4) )

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :
Download full text (9.2 KiB)

Hi Valentin,

Thanks for your prompt reply and fix. ( your reply didn't appear on
launchpad,... don't know why....)

> 1)
> It is the case no? I mean, practically there is one function per
> file output. The structure is a bit less trivial that at LO because
> there is the possibility of putting all files relevant to
> loop_matrix.f into a single fortran source code if the user asks for
> the matrix output.
> Also, if the number of helas calls gets too large, there is the
> possibility of splitting both the HelasCalls and the JAMP definition
> to make the compilation possible.
> But, besides these complications, there is one function per file
> written out.

Yes and no, in fact the .inc are define in the same time as the file
which calling those.
But ok.

> 2)
> Ok, this is funny. My aim is to output the following code:

Since I don't think this is f77 compatible, I don't want to include
such code in LO part ;-)
In your case, I would say that it makes a lot of sense to modify the
FortranWriter

> 4) (concerning help/completion)
>
> Mhh, I know they matter, but ok, later ^^.

To my experience, the sooner is the better for that.
Also for Johan and I this help us to learn the code otherwise this is
very hard to know what is allowed.

> 9) Ok, now LoopInterface correctly forbids processes containing
> multiple particles labels. FKS5 is meant for that after all.

I think that multiparticles are very usefull for the user.
generate p p > W+ j j is something quite natural and very important to
support (at all level). This is something very important
since this simplifies a lot to life for the user.

> 10) Mhh my idea about this was that maybe we would like to specify
> the squared order for tree-level processes as well (for the HIG
> order for example). And then the [] plays the role of a delimiter
> just fine. So I'd prefer to keep it like this.

Not really like this syntax, since this is far to be readable...
why not something like that then
p p > g g QCD=2 {NP=2}

which will do the following syntqx
PROCESS RESTRICTION ORDER [LOOP_INFO] {AMP_ORDER} @#
with all option can be switched in order?
(by restriction I mean / $ $$)

We can maybe have a skype meeting on this.

> 11) The logic goes like this:
> a) There are no specified options with the '=' delimiter, so
> that the default is that both real and virtual corrections are
> applied.
> b) Given a), it is now the FKS5 interface which treats the
> process and first check that the perturbation order asked for is
> exactly QCD (as none other is supported so far). FKS5 interfaces
> reckognizes that the perturbation order asked for is 'virt' (which
> is correct as this is exactly what you would put if you had a model
> with a 'virt' order defined and being perturbed) and therefore
> complains.
>
> So tell me at which point you would like this kind of request
> to be handled differently. Because apart from a dedicated check for
> this special form of input line, i don't see how we could do it
> differently.

I will just handle two special tag for [virt] and [real]

Otherwise some additional points:

19) Marco, Do you nee...

Read more...

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (10.2 KiB)

ciao olivier
i'll have a more detailed look at the points later
so far, there is no index.html/diagram drawing in madfks
it is something we would like to have, of course, but to which i did not pay much attention so far
i will look at it

i think the issue/fix was maybe related with the loop_material dir that has been removed from versioning, but i am not 100% sure
so this morning i try to fix the vbfnnlo page, so that we can continue on mg5 later
cheers
marco

On 19 Mar 2012, at 23:28, Olivier Mattelaer wrote:

> Hi Valentin,
>
> Thanks for your prompt reply and fix. ( your reply didn't appear on
> launchpad,... don't know why....)
>
>> 1)
>> It is the case no? I mean, practically there is one function per
>> file output. The structure is a bit less trivial that at LO because
>> there is the possibility of putting all files relevant to
>> loop_matrix.f into a single fortran source code if the user asks for
>> the matrix output.
>> Also, if the number of helas calls gets too large, there is the
>> possibility of splitting both the HelasCalls and the JAMP definition
>> to make the compilation possible.
>> But, besides these complications, there is one function per file
>> written out.
>
> Yes and no, in fact the .inc are define in the same time as the file
> which calling those.
> But ok.
>
>
>> 2)
>> Ok, this is funny. My aim is to output the following code:
>
> Since I don't think this is f77 compatible, I don't want to include
> such code in LO part ;-)
> In your case, I would say that it makes a lot of sense to modify the
> FortranWriter
>
>> 4) (concerning help/completion)
>>
>> Mhh, I know they matter, but ok, later ^^.
>
>
> To my experience, the sooner is the better for that.
> Also for Johan and I this help us to learn the code otherwise this is
> very hard to know what is allowed.
>
>
>> 9) Ok, now LoopInterface correctly forbids processes containing
>> multiple particles labels. FKS5 is meant for that after all.
>
>
> I think that multiparticles are very usefull for the user.
> generate p p > W+ j j is something quite natural and very important to
> support (at all level). This is something very important
> since this simplifies a lot to life for the user.
>
>> 10) Mhh my idea about this was that maybe we would like to specify
>> the squared order for tree-level processes as well (for the HIG
>> order for example). And then the [] plays the role of a delimiter
>> just fine. So I'd prefer to keep it like this.
>
> Not really like this syntax, since this is far to be readable...
> why not something like that then
> p p > g g QCD=2 {NP=2}
>
> which will do the following syntqx
> PROCESS RESTRICTION ORDER [LOOP_INFO] {AMP_ORDER} @#
> with all option can be switched in order?
> (by restriction I mean / $ $$)
>
> We can maybe have a skype meeting on this.
>
>> 11) The logic goes like this:
>> a) There are no specified options with the '=' delimiter, so
>> that the default is that both real and virtual corrections are
>> applied.
>> b) Given a), it is now the FKS5 interface which treats the
>> process and first check that the perturbation order asked for is
...

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (11.2 KiB)

Hi Olivier
i fixed the display processes / diagrams for the fks interface

actually in the fks interface, it looked reasonable to me, that one may ask born/real/virt_diagrams (or processes)
so if you type display diagrams after the generation of a nlo process you 'll receive an error sayng to type real/virt/born_diagrams instead
if you type them (also auto-completion works) you will have the ones that you need
let me know if you agree with this choice
(the same as for processes)

cheers
Marco

On 20 Mar 2012, at 08:49, marco zaro wrote:

> ciao olivier
> i'll have a more detailed look at the points later
> so far, there is no index.html/diagram drawing in madfks
> it is something we would like to have, of course, but to which i did not pay much attention so far
> i will look at it
>
> i think the issue/fix was maybe related with the loop_material dir that has been removed from versioning, but i am not 100% sure
> so this morning i try to fix the vbfnnlo page, so that we can continue on mg5 later
> cheers
> marco
>
>
>
>
> On 19 Mar 2012, at 23:28, Olivier Mattelaer wrote:
>
>> Hi Valentin,
>>
>> Thanks for your prompt reply and fix. ( your reply didn't appear on
>> launchpad,... don't know why....)
>>
>>> 1)
>>> It is the case no? I mean, practically there is one function per
>>> file output. The structure is a bit less trivial that at LO because
>>> there is the possibility of putting all files relevant to
>>> loop_matrix.f into a single fortran source code if the user asks for
>>> the matrix output.
>>> Also, if the number of helas calls gets too large, there is the
>>> possibility of splitting both the HelasCalls and the JAMP definition
>>> to make the compilation possible.
>>> But, besides these complications, there is one function per file
>>> written out.
>>
>> Yes and no, in fact the .inc are define in the same time as the file
>> which calling those.
>> But ok.
>>
>>
>>> 2)
>>> Ok, this is funny. My aim is to output the following code:
>>
>> Since I don't think this is f77 compatible, I don't want to include
>> such code in LO part ;-)
>> In your case, I would say that it makes a lot of sense to modify the
>> FortranWriter
>>
>>> 4) (concerning help/completion)
>>>
>>> Mhh, I know they matter, but ok, later ^^.
>>
>>
>> To my experience, the sooner is the better for that.
>> Also for Johan and I this help us to learn the code otherwise this is
>> very hard to know what is allowed.
>>
>>
>>> 9) Ok, now LoopInterface correctly forbids processes containing
>>> multiple particles labels. FKS5 is meant for that after all.
>>
>>
>> I think that multiparticles are very usefull for the user.
>> generate p p > W+ j j is something quite natural and very important to
>> support (at all level). This is something very important
>> since this simplifies a lot to life for the user.
>>
>>> 10) Mhh my idea about this was that maybe we would like to specify
>>> the squared order for tree-level processes as well (for the HIG
>>> order for example). And then the [] plays the role of a delimiter
>>> just fine. So I'd prefer to keep it like this.
>>
>> Not really like this syntax, since this ...

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :
Download full text (12.3 KiB)

Hi Marco,

> i fixed the display processes / diagrams for the fks interface
Thanks

> actually in the fks interface, it looked reasonable to me, that one
> may ask born/real/virt_diagrams (or processes)
> so if you type display diagrams after the generation of a nlo
> process you 'll receive an error sayng to type real/virt/
> born_diagrams instead
> if you type them (also auto-completion works) you will have the ones
> that you need
> let me know if you agree with this choice
> (the same as for processes)

Sure that's perfect.
Just maybe display diagrams might either
a) not be proposed anymore in the auto-completion
b) simply return the three above output

Valentin could you fix this also in the ML5 interface?

Cheers,

Olivier

On Mar 20, 2012, at 10:58 AM, marco zaro wrote:

> Hi Olivier
> i fixed the display processes / diagrams for the fks interface
>
> actually in the fks interface, it looked reasonable to me, that one
> may ask born/real/virt_diagrams (or processes)
> so if you type display diagrams after the generation of a nlo
> process you 'll receive an error sayng to type real/virt/
> born_diagrams instead
> if you type them (also auto-completion works) you will have the ones
> that you need
> let me know if you agree with this choice
> (the same as for processes)
>
> cheers
> Marco
>
>
>
> On 20 Mar 2012, at 08:49, marco zaro wrote:
>
>> ciao olivier
>> i'll have a more detailed look at the points later
>> so far, there is no index.html/diagram drawing in madfks
>> it is something we would like to have, of course, but to which i
>> did not pay much attention so far
>> i will look at it
>>
>> i think the issue/fix was maybe related with the loop_material dir
>> that has been removed from versioning, but i am not 100% sure
>> so this morning i try to fix the vbfnnlo page, so that we can
>> continue on mg5 later
>> cheers
>> marco
>>
>>
>>
>>
>> On 19 Mar 2012, at 23:28, Olivier Mattelaer wrote:
>>
>>> Hi Valentin,
>>>
>>> Thanks for your prompt reply and fix. ( your reply didn't appear on
>>> launchpad,... don't know why....)
>>>
>>>> 1)
>>>> It is the case no? I mean, practically there is one function per
>>>> file output. The structure is a bit less trivial that at LO because
>>>> there is the possibility of putting all files relevant to
>>>> loop_matrix.f into a single fortran source code if the user asks
>>>> for
>>>> the matrix output.
>>>> Also, if the number of helas calls gets too large, there is the
>>>> possibility of splitting both the HelasCalls and the JAMP
>>>> definition
>>>> to make the compilation possible.
>>>> But, besides these complications, there is one function per file
>>>> written out.
>>>
>>> Yes and no, in fact the .inc are define in the same time as the file
>>> which calling those.
>>> But ok.
>>>
>>>
>>>> 2)
>>>> Ok, this is funny. My aim is to output the following code:
>>>
>>> Since I don't think this is f77 compatible, I don't want to include
>>> such code in LO part ;-)
>>> In your case, I would say that it makes a lot of sense to modify the
>>> FortranWriter
>>>
>>>> 4) (concerning help/completion)
>>>>
>>>> Mhh, I know they matter, but ok, later ^^.
>>>
>>>
>>> To my e...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
180. By Valentin Hirschi <email address hidden>

1. Fixed the launch standalone function.

181. By Valentin Hirschi <email address hidden>

1. Implemented special fonctions cond(a,b,c) and reglog(a) available for
   loop UFO model. It can be exported to fortran without problem but not
   to C++ (not implemented but could be without too much effort).
   The advantage is that no ill-expression like log(0) appear anymore and
   that one can easily switch from loop_sm to loop_sm-zerobmass simply with
   the corresponding restrict card.

182. By Valentin Hirschi <email address hidden>

1. Upgraded the display for the ML5 interface. The user can now ask for
   display diagrams -> display all diagrams
   display diagrams born -> display born diagrams
   display diagrams loop -> display virtuals diagrams

   And for this function, the completion and help is up to date.

183. By Valentin Hirschi <email address hidden>

1. Fixed the help of the new display_diagrams in the LoopInterface

184. By Valentin Hirschi <email address hidden>

1. Fixed an issue with the new functions 'COND' and 'REGLOG' for the
   loop UFO model which were not well behaved when dealing with
   complex arguments.

185. By Valentin Hirschi <email address hidden>

1. Fixed the definition of the fonction 'COND' in model_functions.f

186. By Valentin Hirschi <email address hidden>

1. Merged with latest revision from Marco before my push.

187. By Valentin Hirschi <email address hidden>

1. Fixed many of the first series of points from Olivier's review

188. By marco zaro

 moved the templateFKSxxxx dirs to Template/FKS-xxxx
 exporters modified accordingly

189. By marco zaro

modified the madgraph_interface.extract_process function so that now
if the orders are not defined they are set equal to the squared_orders in the process definition
with this
generate p p > t t~ QED=0 [QCD]
and
generate p p > t t~ [QCD] QED=0
return the same diagrams, as expected

190. By Valentin Hirschi <email address hidden>

1. Update commit

191. By Valentin Hirschi <email address hidden>

1. Upgraded the ML5 standalone output so that it now handles loop induced
   processes.
2. Added some warning during diagram generation for the cases where some
   non perturbed order do not factorize the same power in all born diagrams
   and when mixed QCD-QED loops are discarded because the user asked only
   for QCD corrections (of course the warning is general and not limited
   to this case.).

192. By Valentin Hirschi <email address hidden>

1. Small fix in the warnings for discarded loops.

193. By Valentin Hirschi <email address hidden>

1. Small fix for the initialization of 'GOODAMP' for the split output.

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :

Hi guys,

I started the systematics review file by file.
I hope to do one file each one/two days such that it can move quite fast on this.

So today it is loop_base_objects.py

So first a global comment: This file is quite clear and very well documented.
Good work!

23) A quite global comment. The PEP08 is not respected by far.
Using up to 80 character should be follow as much as possible.
Even if this is boring at the stage of writing the code, this is quite
usefull for
1) comparing two version of the code
2) editing on a small screen (my laptop for example)
3) for the web

In your case, a lot of comment line are bigger than 80 char.
This should be reduced to 80) Looks like you split around 120.

Also concerning PEP08 the space before/after the equal/sum/...
This improves the readibility of the code.

24) The routine next_loop_leg is very long and with a lot of sub-level (loop of loop of loop).
I think it might be interesting to re-factor it in order to have it calling multiple functions.
This might make the structure more clear. ( this is only a suggestion)

25) The name "next_loop_leg" and the way this function is call is quite confusing to me.
I don't really that a function in a if, modify/creates a lot structures. and given the name I was expecting that this returns the next leg, but this is an iterative call so clearly this should be done outside the if.

26)For the fun (I like those stupid optimization) the function get_loop_line_types can be optimized by returning
return set([abs(l['id']) for l in v['legs'] for v in self['vertices'] if l['loop_line']])

27) At line 702 you perform the following:
        # Make a local copy (since we will act on the leg object of the tag)
        revTag=copy.deepcopy(atag)
    But If I'm correct, you copy a object of the following type # [(Leg,[Structure_IDs],Vertex), (...), ...]
    That means that you duplicate all the Leg/Vertex and all the content of those.
    I would prefer that you create an optimize routine to copy only the required part.
    I don't think you need to duplicate Leg/Vertex.

28) One point that I don't understand is why you need to "recreate" the vertex for the FDstructure. I would have expect that you have to "copy" those from one of the diagram.
Why is it not working?

I like your way to code, very well documented :-)

Cheers,

Olivier

review: Needs Information
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :
Download full text (7.7 KiB)

Hi Valentin,

looks like launchpad doesn't like your email account (or your email account doesn't like launchpad)
since your message didn't pass through it. Could you check your configuration?

Otherwise, the file for today is loop_diagram (only half of it).
Nothing very deep a lot of small optimization, question, check to perform.

Cheers,

Olivier

29) One minor detail:
at line 284:
        elif argument != None:
            # call the mother routine
            super(Amplitude, self).__init__(argument)
        else:
            # call the mother routine
            super(Amplitude, self).__init__()
can be replace by:
        else:
            # call the mother routine
            super(Amplitude, self).__init__(argument)
(the elif is pointless.

30) at line 77:
    def get_sorted_keys(self):
        """Return diagram property names as a nicely sorted list."""

        return ['process', 'diagrams', 'has_mirror_process', 'born_diagrams',
                'loop_diagrams','has_born',
                'structure_repository']
    Would it makes sense to return here diagrams since this is always empty?
    Not sure what this changes in fact, could you try/check?

31) Not sure it worth the time but at line 131:
                self['born_diagrams']=base_objects.DiagramList([diag for diag in value if \
                  not isinstance(diag,loop_base_objects.LoopUVCTDiagram) and diag['type']==0])
                self['loop_diagrams']=base_objects.DiagramList([diag for diag in value if \
                  not isinstance(diag,loop_base_objects.LoopUVCTDiagram) and diag['type']!=0])
                self['loop_UVCT_diagrams']=base_objects.DiagramList([diag for diag in value if \
                  isinstance(diag,loop_base_objects.LoopUVCTDiagram)])
you loop three times over the full list, while a single loop should be enough.

32)at line 147:
            if self['process'] and self['loop_diagrams'] == None:
                self.generate_diagrams()
   This breaks PEP08(not important rule)
"Comparisons to singletons like None should always be done with 'is' or 'is not', never the equality operators.".By reading this article: http://jaredgrubb.blogspot.com/2009/04/python-is-none-vs-none.html, you will see that this is not that important but I pointed such that you will use the correct one in the future.

33)at line 188:
        # This is a bool controlling the verbosity of this subroutine only
        loopGenInfo=False

        old_logger_level=logger.getEffectiveLevel()
        if loopGenInfo:
            # Disable the basic info if using the extended one
            logger.setLevel(logging.WARNING)
        ...
                if loopGenInfo: print "LoopGenInfo:: User input born orders = ",self['process']['orders']
        if loopGenInfo: print "LoopGenInfo:: User input squared orders = ",self['process']['squared_orders']
        if loopGenInfo: print "LoopGenInfo:: User input perturbation = ",self['process']['perturbation_couplings']
        ...
        if loopGenInfo:
            logger.setLevel(old_logger_level)

        That's a weird way to treat the logger.
        I see two poss...

Read more...

review: Needs Fixing
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :

I'm back on this file, and I have only comment remaining on this one:

48) line 786, you define
    def copy_leglist(self, leglist):
        """ Returns a DGLoopLeg list instead of the default copy_leglist
            defined in base_objects.Amplitude """

        dgloopleglist=base_objects.LegList()
        for leg in leglist:
            dgloopleglist.append(loop_base_objects.DGLoopLeg(leg))

        return dgloopleglist
But this should be equivalent of base_objects.LegList(leglist)
So I don't think that you need such function.

I'm going to wait for your green light before reviewing the helas file.

Cheers,

Olivier

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
194. By Valentin Hirschi <email address hidden>

1. Merged with ML5_faster bringing in the 'loop_optimized_output' which
   brings many optimization and flexibility in the code, as:
   a. Control the initialization of the Loop and Hel filters and save them
   b. Control run time parameteres with the card MadLoopParams.dat
   c. Optimization of summing over the helicity before cuttoolizing the
      diagrams as well as constructing the loop lorentz trace directly from
   a helas wavefunction which brings a speed up factor 2 for massless fermion
   L-cut diagrams and 3 fort the massive one.
   Overall gain is usually more than a factor 5 already!

195. By Valentin Hirschi <email address hidden>

1. Fixed small bug when setting 'USELOOPFILTER' to false.

196. By Valentin Hirschi <email address hidden>

1. Merged with Marco's latest push.

197. By Valentin Hirschi <email address hidden>

1. Small fix in the definition of ML in the loop numerator.

198. By Valentin Hirschi <email address hidden>

1. Upgraded the model v4 output in order to factor out the multiple precision
   parameters and couplings and also promote mu_r to the same status as alpha_s
   meaning that UPDATE_AS_PARAM correctly update all variables depending on
   mu_r and alpha_s.

199. By Valentin Hirschi <email address hidden>

1. Small fix so that the parameter ZeroThres in the MadLoopParamCard
   is indeed used in favor of the old hardcoded value vtiny in ISZERO().

200. By Valentin Hirschi <email address hidden>

1. Fixed an issue occurring for loops with more external wavefunctions than
   loop lines.
2. Fixed the MadLoopParams.dat file which was not up to date.

201. By Valentin Hirschi <email address hidden>

1. Merged with latest push of this branch on launchpad.

202. By marco zaro

merged with FKS5_new_born branch v 323

203. By marco zaro

merged with FKS5_new_born branch v 324

204. By marco zaro

added a function to get Nf (the number of light flavors) from the model.
In this way Nf is written in coupl.inc, and does not need anymore to be specified (and changed) inside fks_singular.f
Also setcuts.f is changed so that if maxjetflavor is set in the run_card to a value > Nf, it takes the value Nf

205. By Valentin Hirschi <email address hidden>

1. Small fix for the path of the template LO banner.

206. By Valentin Hirschi <email address hidden>

1. Major upgrade of the branch including the latest developments in ML5,
   among which is the implementation of the open loop method for faster
   loop matrix element evaluation. In order to obtain such output, you
   must set the 'loop_optimized_output' flag from the madgraph interface
   to true.
2. Notice that when this flag is set to False, the default output is now
   what was the optimized one before (in which the sum over helicities is
   performed before calling CutTools) which means that the color ordered
   amplitudes for loop processes are no longer obtainable. For this reason
   the old branch which had this information with the raw output is kept
   under the name FKS5_legacy but it as its name suggests it will not be
   maintained or upgraded anymore.
3. Finally the loop-induced processes do no benefit of the loop optimized
   output for now.

207. By Valentin Hirschi <email address hidden>

1. Added Olivier's latest modification to ML5_faster_merged_1.4.6

208. By marco zaro

updated the fks exporer so that the non-optimized version of MadLoop works
also commented an harmless error in avh_olo.f90
ERROR in OneLOop box13: p12=m3, returning 0
to be done: modify fks exporter for optimized loop

209. By marco zaro

write_ajob modified so that MadLoopParams.dat is copied to the node

210. By marco zaro

 ColorNum/DenFactors.dat and HelConfigs.dat are now copied to the cluster node

211. By marco zaro

modified exporters in order to deal with optimized mode (not yet working)
Also, problem with poles cancelation in MadFKS, maybe due to points too close to threshold

212. By Valentin Hirschi <email address hidden>

1. Merged with ML5_faster which implements several improvements and bug
   fixes.
a) A new command 'check timing' for loop processes. (not loop-induced)
b) Parallel tests which can be run with './test/test_manager -p P ML5Test'
c) The other 'check' commands no also full working both for optimized and default output.
d) A new kind of Helicity filter for the optimized output which allow to set
the helicity dependence from CP for example. Normally automatically setup, but
not validated/fully-working yet. Can still easily be edited by hand though.

213. By Rikkert Frederix

DECAY and HELAS made to work with the new Template directory

214. By Paolo Torrielli

updated montecarlocounter.f

215. By marco zaro

MP is used for HELAS routines only if virtuals have been generated

216. By Rikkert Frederix

fixed a bug in the azimuthal correlations because the order of the
spinor/polarization vector and the momentum changed in the
wave-functions in the aloha/HELAS code. (Also a bug fixed in the
oxxxxx.f spinor: the order was not changed consistently there).

217. By Rikkert Frederix

1. Small fix in add_write_info.f related to the assignment of the color
information when there are 4-point interactions around.
2. Change the MC damp factors to be between 0.1 and 1 (like in v4)
3. Added the Higgs+1j virtuals to the virt.tar.gz tar-ball.

218. By Rikkert Frederix

Put the boostwdir2 subroutine in a separate file for easier linking to
the reweight_xsec_events (which doesn't need the genps_fks.f)

219. By marco zaro

fixed bug/redundancies in the computation of the color links.
now they are computed after the combination of identical matrix elements.
g g > u u~ g g [real=QCD] now does not raise errors anymore at output time

220. By marco zaro

fix in the previous commit
only half of the color links are generated, those for which #leg1 <= #leg2
updated unit tests
soft/coll tests checked for p p > 3j and p p > t t~, OK

221. By Rikkert Frederix

Added a new value for the renormalization scale (not used by default),
useful for "alphaS reweighting"

222. By marco zaro

fixed bug: Error occurring when one exported [real=QCD] with loop_optimized_mode =True

223. By Rikkert Frederix

Small fix in the setscales (for the 'alpha_s reweigting')

224. By Rikkert Frederix

small fix in the assignment of the MC masses (add_write_info.f).

225. By Rikkert Frederix

Cleaning of the Template/FKS-born/bin/ directory.
All the "hidden" compilation of files is done via a makefile.

226. By Rikkert Frederix

renamed combine_plots3.sh to combine_plots_FO.sh
renamed combine_results3.sh to combine_results_FO.sh

227. By Rikkert Frederix

Removed one file too many in the previous push

228. By Rikkert Frederix

Added a couple of cuts to the run_card.dat related to the jets and to
the leptons. The values put there are used in cuts.f to apply these
cuts as well as in set_tau_min to compute the minimal required value
for tau to pass these cuts.

229. By Rikkert Frederix

renamed ./bin/compile_madfks2.sh to ./bin/compile_amcatnlo.sh
renamed ./bin/run_madfks.sh to ./bin/run_amcatnlo.sh

230. By Rikkert Frederix

Added the 'collect_events' to the makefile

231. By Rikkert Frederix

The reweight_xsec_events.sh script now reads the event files that need
reweighting from the nevents_unweighted file. Also, after running it
updates this file so that a collect_events will get the events from
the reweighted event files.

232. By marco zaro

removed print statement in helas_objects which printed many ZERO ZERO if complex mass was activated and mass/width of a particle are=0
added ZERO=0d0 statement in couplings.f (also in MP)

233. By marco zaro

fixed small bug in cuts.f
eta cuts were applied to the center of mass momenta and not to the lab frame ones

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello guys,

This is an amazing job!

I have started slowly going through the code, and I would first like to ask about the code organization.

In Template, you now have four different directories. Looking at e.g. the Source directory in FKS-born and LO, it looks like the main differences (in the files with the same names) is that a number of updates/improvements from MG5 are not included in the FKS directory. Is there a plan for how to include developments that should be common between Lo and FKS? I could have imagined another way to do it would be to have a common Source directory for all the functionality, and try to factor out functionality that differs to use different files only where differences are really needed. Or should I interpret the present organization such that you prefer to have any modifications to the FKS code have to be explicitly implemented by you, rather than just being reviewed by you?

Another detail, but which would be nice to fix a.s.a.p. to make life easier for reviewers (i.e., me) would be to replace the useless README files (that you have just copied from the LO directory) and incomplete help texts in the mg5 interface, to include some rudimentary how-to-get-started info. I'm sure this wouldn't take more than 30 min to update, you need to do it at some point anyway, and it would save a lot of time on my side.

All the best,
Johan

review: Needs Fixing
Revision history for this message
Valentin Hirschi (valentin-hirschi) wrote :

Hi Johan,

Thanks for having started to look at the code!

On Fri, Aug 24, 2012 at 6:10 AM, Johan Alwall <email address hidden> wrote:

> Review: Needs Fixing
>
> Hello guys,
>
> This is an amazing job!
>
> I have started slowly going through the code, and I would first like to
> ask about the code organization.
>
> In Template, you now have four different directories. Looking at e.g. the
> Source directory in FKS-born and LO, it looks like the main differences (in
> the files with the same names) is that a number of updates/improvements
> from MG5 are not included in the FKS directory. Is there a plan for how to
> include developments that should be common between Lo and FKS? I could have
> imagined another way to do it would be to have a common Source directory
> for all the functionality, and try to factor out functionality that differs
> to use different files only where differences are really needed. Or should
> I interpret the present organization such that you prefer to have any
> modifications to the FKS code have to be explicitly implemented by you,
> rather than just being reviewed by you?
>
> Another detail, but which would be nice to fix a.s.a.p. to make life
> easier for reviewers (i.e., me) would be to replace the useless README
> files (that you have just copied from the LO directory) and incomplete help
> texts in the mg5 interface, to include some rudimentary how-to-get-started
> info. I'm sure this wouldn't take more than 30 min to update, you need to
> do it at some point anyway, and it would save a lot of time on my side.
>

Yes, definitely. This is the next thing on my todo list. I'm not around
later today and this weekend, but I will do it.
But already now, I can tell you that there are not many commands
NLO-related other than the generate one you already know (at list for the
virtuals only)

> display diagrams [born/loop/real]
> check timing <proc>
> check stability <nPSpoints> <proc>
> check <proc> (the default checks available also for NLO)
> launch ( for NLO SA only)

By the way, notice that you now have some virtuals-only local parallel
tests in 'test_ML5'.
I'll let you know as soon as I make progress in the user documentation
(online help + README).

Cheers,

Cheers,

> All the best,
> Johan
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch
> lp:~maddevelopers/madgraph5/FKS5.
>

--
Valentin

Revision history for this message
marco zaro (marco-zaro) wrote :

Hi Johan,

could you give a couple more details about the source files? Indeed we never updated them, so it would be nice to know which improvements of LO we can transfer also to NLO.
Thanks for the review!
Cheers
Marco

On 24 Aug 2012, at 00:10, Johan Alwall wrote:

> Review: Needs Fixing
>
> Hello guys,
>
> This is an amazing job!
>
> I have started slowly going through the code, and I would first like to ask about the code organization.
>
> In Template, you now have four different directories. Looking at e.g. the Source directory in FKS-born and LO, it looks like the main differences (in the files with the same names) is that a number of updates/improvements from MG5 are not included in the FKS directory. Is there a plan for how to include developments that should be common between Lo and FKS? I could have imagined another way to do it would be to have a common Source directory for all the functionality, and try to factor out functionality that differs to use different files only where differences are really needed. Or should I interpret the present organization such that you prefer to have any modifications to the FKS code have to be explicitly implemented by you, rather than just being reviewed by you?
>
> Another detail, but which would be nice to fix a.s.a.p. to make life easier for reviewers (i.e., me) would be to replace the useless README files (that you have just copied from the LO directory) and incomplete help texts in the mg5 interface, to include some rudimentary how-to-get-started info. I'm sure this wouldn't take more than 30 min to update, you need to do it at some point anyway, and it would save a lot of time on my side.
>
> All the best,
> Johan
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Marco,

I went through the diff of the directories, and see the following modifications that have not been included in the FKS branch. The vast majority of the files seem to be just old versions of the MG4 files. So it looks like it would be possible to use a common file repository, and have separate files only where the files necessarily differ. With an appropriate set of tests, the risk for problems from improvements should be quite minimal. My worry with the present organization is that once we decide to include improvements in both LO and FKS, it might end up being a lot of work since the files have diverged so much.

pdg2pdf.f: reuse previous call if possible.

pdg2pdf_lhapdf.f: return 0 for non-parton.

cuts.inc and setrun.f (as well as setcuts.f in SubProcesses): turning off cuts for decays.

dsample.f: set minimal number of iterations, use lumi instead of #events, some speedups by Tim. Simplified/clearer version of dsample.f underway.

gen_ximprove:
- Allow splitting channels into multiple G dirs, allow any number of conflicting BW in decays (same thing in symmetry.f)
- Using lumi instead of #events (reduces risk for 2nd refine)
- Major rework of gridpack mode after reports about problems with granularity by CMS

genps.inc: Allow any number of configs, particles, etc.
kin_functions.f: Different definitions of DJ (used in clustering for matching)

ranmar.f: major improvement to guarantee up to 900M random seeds (in latest version of MG5, not yet in FKS5 branch)

transpole.f: New transformations by Tim

I'm not sure how up-to-date the LO directory in this branch is, so there might be more from the later versions (e.g. ranmar.f).

All the best,
Johan

Revision history for this message
Rikkert Frederix (frederix) wrote :

Hi Johan,

let me also explicitly write it here. I also replied to the e-mail that I received from LP, but somehow that didn't end-up here.

Thanks for giving this quick report. Let me reply to each of them. Indeed, there is a bit of work needed from our side (mostly cleaning up parts of code that we include but are never used).

> pdg2pdf.f: reuse previous call if possible.

Ok. should be updated.

> pdg2pdf_lhapdf.f: return 0 for non-parton.

Ok. should be updated.

> cuts.inc and setrun.f (as well as setcuts.f in SubProcesses): turning off cuts for decays.

Our setrun.f is quite a bit different because many of the cuts (on jets and photons) cannot easily be transported to NLO. However, as you might notice, also here the code has not been cleaned properly.

> dsample.f: set minimal number of iterations, use lumi instead of #events, some speedups by Tim. Simplified/clearer version of dsample.f underway.

> gen_ximprove:
> - Allow splitting channels into multiple G dirs, allow any number of conflicting BW in decays (same thing in symmetry.f)
> - Using lumi instead of #events (reduces risk for 2nd refine)
> - Major rework of gridpack mode after reports about problems with granularity by CMS

The integration routines for the NLO code are completely different from the LO ones. E.g. we don't use dsample anymore (and it's just there because we never cleaned this part of the code). We are using the MINT package by Paolo Nason for the importance sampling. Also the gen_ximprove we don't have as such neither do we have support for gridpacks. Also, we don't use the 'conflicting BW' stuff; maybe we should, but for early version of the MadFKS code, this was something very complicated (and we were not yet sure how the integration channels should be defined) and was never re-instated/re-implemented.

> genps.inc: Allow any number of configs, particles, etc.

Needs to be carefully updated.

> kin_functions.f: Different definitions of DJ (used in clustering for matching)

Right now they are not yet used, but I guess we should update them when I start testing the NLO CKKW stuff.

> ranmar.f: major improvement to guarantee up to 900M random seeds (in latest version of MG5, not yet in FKS5 branch)

Ok. this needs to be updated.

> transpole.f: New transformations by Tim

Phase-space and integration routines are completely different; transpole is not used.

Cheers,
Rik

Revision history for this message
marco zaro (marco-zaro) wrote :

Hi,
I have done some modifications.
For genps.inc: maxparticle is referring to born or real emission?
Cheers
Marco

On 27 Aug 2012, at 15:12, Rikkert Frederix wrote:

> Hi Johan,
>
> let me also explicitly write it here. I also replied to the e-mail that I received from LP, but somehow that didn't end-up here.
>
>
> Thanks for giving this quick report. Let me reply to each of them. Indeed, there is a bit of work needed from our side (mostly cleaning up parts of code that we include but are never used).
>
>> pdg2pdf.f: reuse previous call if possible.
>
> Ok. should be updated.
>
>
>> pdg2pdf_lhapdf.f: return 0 for non-parton.
>
> Ok. should be updated.
>
>
>> cuts.inc and setrun.f (as well as setcuts.f in SubProcesses): turning off cuts for decays.
>
> Our setrun.f is quite a bit different because many of the cuts (on jets and photons) cannot easily be transported to NLO. However, as you might notice, also here the code has not been cleaned properly.
>
>> dsample.f: set minimal number of iterations, use lumi instead of #events, some speedups by Tim. Simplified/clearer version of dsample.f underway.
>
>> gen_ximprove:
>> - Allow splitting channels into multiple G dirs, allow any number of conflicting BW in decays (same thing in symmetry.f)
>> - Using lumi instead of #events (reduces risk for 2nd refine)
>> - Major rework of gridpack mode after reports about problems with granularity by CMS
>
>
> The integration routines for the NLO code are completely different from the LO ones. E.g. we don't use dsample anymore (and it's just there because we never cleaned this part of the code). We are using the MINT package by Paolo Nason for the importance sampling. Also the gen_ximprove we don't have as such neither do we have support for gridpacks. Also, we don't use the 'conflicting BW' stuff; maybe we should, but for early version of the MadFKS code, this was something very complicated (and we were not yet sure how the integration channels should be defined) and was never re-instated/re-implemented.
>
>> genps.inc: Allow any number of configs, particles, etc.
>
> Needs to be carefully updated.
>
>> kin_functions.f: Different definitions of DJ (used in clustering for matching)
>
>
> Right now they are not yet used, but I guess we should update them when I start testing the NLO CKKW stuff.
>
>> ranmar.f: major improvement to guarantee up to 900M random seeds (in latest version of MG5, not yet in FKS5 branch)
>
> Ok. this needs to be updated.
>
>> transpole.f: New transformations by Tim
>
> Phase-space and integration routines are completely different; transpole is not used.
>
> Cheers,
> Rik
>
>
>
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Rikkert,

Thanks for your clarification. I would suggest to remove all files that you don't actually use from the FKS directory, to avoid having different versions of files when possible. It would also be good to have some comments ("Modif for FKS" or something) in the files that are changed to comply with FKS/NLO, to simplify updating files.

Johan

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Marco,

> For genps.inc: maxparticle is referring to born or real emission?

I think you will need to have it for the real emission, since this is used for array limits. It's not a problem if it's a bit too large, but it's a big problem if it's too small :-)
The main point with this modif (in LO) is that we now allow basically unlimited length of decay chains - I have done simulation with 16 final state particles without problem. I would expect this to be possible also in NLO mode, so it's better not to have any limitation. Just make sure to go through all files and remove possible hardcoded array limits.

All the best,
Johan

Revision history for this message
marco zaro (marco-zaro) wrote :

Hi,
i have removed the fixed lmaxconfigs and maxparticles in genps.inc
now the corresponding .inc files are written when exporting
Ciao
Marco

On 27 Aug 2012, at 21:17, Johan Alwall wrote:

> Hello Marco,
>
>> For genps.inc: maxparticle is referring to born or real emission?
>
> I think you will need to have it for the real emission, since this is used for array limits. It's not a problem if it's a bit too large, but it's a big problem if it's too small :-)
> The main point with this modif (in LO) is that we now allow basically unlimited length of decay chains - I have done simulation with 16 final state particles without problem. I would expect this to be possible also in NLO mode, so it's better not to have any limitation. Just make sure to go through all files and remove possible hardcoded array limits.
>
> All the best,
> Johan
>
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :

Hi guys,

I was discussing today with Valentin (while we moved forward on the merge with 1.5.0)
And they are four point currently missing we should be present for the official release
1) a tutorial command
2) a launch command for the computation of cross-section/events at NLO
3) the auto-completion working for the process generation
4) the help command up-to-date

For the point 2, the ideal would be to have something as close as possible of what we have for madevent. In particular this should use the files cluster.py which contains all the command in order to deal with cluster management (submission/control/...)
in madevent.py you have also two command (launch_job and control) which are useful for submitting/controlling job on various cluster/mode of submission.

If you need my help for those points, don't hesitate.

Cheers,

Olivier

review: Needs Fixing
Revision history for this message
Valentin Hirschi (valentin-hirschi) wrote :

Hi all,

On Thu, Aug 30, 2012 at 9:32 PM, Olivier Mattelaer <
<email address hidden>> wrote:

> Review: Needs Fixing
>
> Hi guys,
>
> I was discussing today with Valentin (while we moved forward on the merge
> with 1.5.0)
> And they are four point currently missing we should be present for the
> official release
> 1) a tutorial command
>
I'll take care of designing one. Ideally it would walk the user through
both a aMC@NLO run and a ML5 stand-alone one.

> 2) a launch command for the computation of cross-section/events at NLO
>
Rik, you told me that you already had a master driving bash script for
event generation working locally.
With the help of existing python function for job control over various
cluster architecture, it should not be too hard too translate this script
into a python launch command in the aMC@NLO MG interface which would do
(both locally and on clusters) both fixed order cross section computation
and event-generation, no?
Marco, could you implement this with Rik's help?

> 3) the auto-completion working for the process generation
>
This one is a pain, but eventually Marco or I will attack it.

> 4) the help command up-to-date
>
There are no new commands specific to NLO, but many have additional options
(like check, generate, display and set). So I'll update the existing helps
with the corresponding NLO info. Marco go over my modifications afterwards
and add anything missing which would be FKS-specific.

>
> For the point 2, the ideal would be to have something as close as possible
> of what we have for madevent. In particular this should use the files
> cluster.py which contains all the command in order to deal with cluster
> management (submission/control/...)
> in madevent.py you have also two command (launch_job and control) which
> are useful for submitting/controlling job on various cluster/mode of
> submission.
>
> If you need my help for those points, don't hesitate.
>
>
> Cheers,
>
> Olivier
>
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch
> lp:~maddevelopers/madgraph5/FKS5.
>

--
Valentin

lp:~maddevelopers/mg5amcnlo/FKS5 updated
234. By Valentin Hirschi <email address hidden>

1. Merged with ML5_faster. Need to re-check and re-generated the
   parallel test though.

235. By Valentin Hirschi <email address hidden>

1. Intermediate commit before merge with MG5 1.5.0

236. By Valentin Hirschi <email address hidden>

1. Regenerated the ML5 parrallel tests for a model with no widths at all.

237. By Valentin Hirschi <email address hidden>

1. Fixed a typo for loop processes in loop_exporters.py
2. This shows that I have to add some tests for the loop induced processes

238. By Valentin Hirschi <email address hidden>

1. Added the possibility of a new kind of stability check at run-time based
   on the rotation of the original PS point.
2. Improved the statistics output of 'check stability' by addind the
   performance of the loop reading direction stability test.

239. By Valentin Hirschi <email address hidden>

1. Merged with Rik's modifications on avh_olo.f90

240. By Rikkert Frederix

fix in the ajob_template_condor

241. By Rikkert Frederix

Another fix in the ajob_template_condor. Now also the virtual
corrections work on the cluster

242. By Valentin Hirschi <email address hidden>

1. Fixed a bug in qp evaluations of the optimized output which was introduced in
   latest revision.

243. By Rikkert Frederix

Moved the fill_MC_mshell subroutine to a separate file: the Monte
Carlo masses used are written in the header of the event file by
collect_events.f.

244. By Rikkert Frederix

When running MINT mode equal to 1, the check that the nevts file has a
non-zero number of events is no longer there: with the fewer number of
integration channels and the automatic stop when the desired accuracy
has been reached, this stop is no longer needed.

245. By Rikkert Frederix

Fix in the makefiles for the reweight stuff. Introduced 2 revision ago.

246. By Rikkert Frederix

Removed possible FPEs due to missing 'save' statements.

247. By Rikkert Frederix

Allow for the correct reweighting of scale uncertainties also when the
flags fixed_XXX_scale are true.

248. By Rikkert Frederix

In the setscales.f file, moved the minimal allowed scale (2 GeV) from
the global scale setting function to the separate factorization scale
and renormalization scale setting function.

249. By Rikkert Frederix

Use the value '-1' in the run_card for not applying maximum cuts (same
as is done now for LO).

250. By marco zaro

start working on the launch command for aMC@NLO
It should be something like launch PATH MODE, MODE being NLO or aMC@NLO
so far it is implemented until compilation
it may beinteresting to add options such like -IRtests, -MCtests, ...

251. By marco zaro

acutally i forgot to uncomment the most important lines...

252. By Valentin Hirschi <email address hidden>

1. Added the '-reuse' command for loop check commands so that previously
   generated output from the checks can be reused.

2. Added a progressbar for the timings of the check so that the user
   does not panic for the very long one. The progress bar is also
   displayed when the color computation takes long.

253. By marco zaro

small fix in setscales. set_QES_scale now has a lower bound for the scale (2gev)
the launch command works for serial run. Type help launch to see how
to do-> reweighting
     -> change rnd seed
     -> add options to launch command (e.g to run tests at compilation)

254. By marco zaro

re written launch function in more modular way, easily extendible to the cluster case.
randinit is updated

255. By marco zaro

small changes into FKSinterface.py

256. By Marco Zaro <email address hidden>

working on implementing cluster mode.
problem with jobs monitoring

257. By Marco Zaro <email address hidden>

cluster.py replaced with latest version from mg5 1.4.8.4
still problems with jobs monitor

258. By Marco Zaro <email address hidden>

added 2 options to the launch command:
--nocompile skip the compilation
--tests compiles and run test_ME/test_MC
details with help launch

259. By marco zaro

all parameters in the run_card are read from the run_card (also showerMC and rewight info).
reweight_xsec_event is also compiled and ran by the launch command

260. By marco zaro

fixed some bugs in previous commit

261. By Marco Zaro <email address hidden>

launch in cluster mode works!
to do-> make reweighting work in cluster mode, for now it is just bypassed

262. By Marco Zaro <email address hidden>

mg5_configuration restored to serial run

263. By marco zaro

added -c option to launch, for running on cluster without modifying the mg5_configuration file

264. By Marco Zaro <email address hidden>

reweight works also on cluster

265. By marco zaro

using misc.call and misc.Popen to launch executables in serial mode. This way, hitting ctrl + c will terminate the whole run and not only the child process

266. By marco zaro

multicore mode works

267. By marco zaro

statistics are printed also in multicore mode

268. By marco zaro

some bugs fixed

269. By Rikkert Frederix

Fix in the scale setting setscales.f

270. By Rikkert Frederix

Removed some of the print statements in driver_mintMC that were no
longer up-to-date

271. By Marco Zaro <email address hidden>

fixes in the determination of the number of cores

272. By Marco Zaro <email address hidden>

fixed multicore process, p p > e+ ev runs correctly on a 4 and 3 core machine

273. By marco zaro

the launch command automatically swithces the interface if called with NLO, aMC@NLO, aMC@LO

Revision history for this message
Johan Alwall (johan-alwall) wrote :
Download full text (7.5 KiB)

Dear FKS/Loop authors,

Please excuse my long interim in this review. I have now tested running and started on the Python review (starting with the core directory). I have to say that I am quite impressed with the level of user friendliness you have achieved so far, although there is of course still work to be done in this respect, some of which is mentioned below. Please find here a first set of comments, sorted under headers.

========================
Output to FKS:
========================
1. Why does
"INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10"
come twice? Is it just that one of the lines could be changed to better reflect what it does, or is the same operation in fact done twice?

2. Scripts/programs in the PROC.../bin directory should only be relevant to the user, so e.g. clean_template should definitely not be there. (Internally used scripts should be in bin/internal). There should be a cleaning script however, which removes all compiled files (and perhaps additional files that are not needed between runs).

4. Looking at the regular matrix.f files, they have a list of all processes
C Process: g d~ > e+ e- d~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
C WEIGHTED=10
C Process: g d~ > mu+ mu- d~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
C WEIGHTED=10
C Process: g s~ > e+ e- s~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
C WEIGHTED=10
C Process: g s~ > mu+ mu- s~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
while the loop_matrix.f only has the first process listed:
C Process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
It obviously doesn't really matter, but would be clearer to list all processes whose matrix elements are identical.

5. Would it be a good idea to change the name of "LesHouches" to "Binoth" or "BinothLH"? We already have leshouches for the output to lhef format, and also use the lha format for parameter files, so it can be a bit confusing... (just a suggestion)

========================
Running FKS: (using p p > l+ l- as born process)
========================
6. What does:
"Found 16 correctly terminated jobs
random seed found in 'randinit' is 33
Total cross-section: 2.58399299e+03 +- 6.7365e+00 (2.6070e-01%)
Found 16 correctly terminated jobs
Total cross-section: 2.23890720e+03 +- 7.7439e+00 (3.4588e-01%)"
mean? (why is the cross section different between the two lines?)

7. Is this something to worry about?
"gfortran -O -fno-automatic -ffixed-line-length-132 -c -o aloha_functions.o aloha_functions.f
aloha_functions.f:2220.27:

          CALL ILXXXX(Q(0),M,-1,1,W(1))
                           1
Warning: Type mismatch in argument 'ffmass' at (1); passed COMPLEX(8) to REAL(8)"
Perhaps just pass as DBLE(M), DREAL(M), or DABS(M)?

8. Very minor point, in MadLoopParams.dat comment and value don't correspond:
! Some loop contributions my be zero for some helicities which are however
! contributing. In order to save their computing time, you can chose here to try
! to filter them out. As the gain is minimal, this option is turned off by default.
#UseLoopFilter
.TRUE.
! Default :: .TRUE.

9. I tried running with PYTHIA6PT output,...

Read more...

review: Needs Fixing
Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (10.0 KiB)

Hi Johan,
thanks for the review.
I started working on some of the points you raised (those which looked FKS-connected)
I still have to work on the interface, in order to have the possibility to generate events outside mg5
Thanks a lot
Marco

On 18 Sep 2012, at 09:43, Johan Alwall wrote:

> Review: Needs Fixing
>
> Dear FKS/Loop authors,
>
> Please excuse my long interim in this review. I have now tested running and started on the Python review (starting with the core directory). I have to say that I am quite impressed with the level of user friendliness you have achieved so far, although there is of course still work to be done in this respect, some of which is mentioned below. Please find here a first set of comments, sorted under headers.
>
> ========================
> Output to FKS:
> ========================
> 1. Why does
> "INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10"
> come twice? Is it just that one of the lines could be changed to better reflect what it does, or is the same operation in fact done twice?
INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Processing color information for process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: c c~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Reusing existing color information for process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: s s~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: u~ u > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Processing color information for process: u~ u > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: c~ c > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: d~ d > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Reusing existing color information for process: d~ d > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
INFO: Generating Helas calls for FKS process process: s~ s > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
it actually does not appear twice, what (i think) appear twice is u u~ and u~ u, which, so far, are treated as different
>
> 2. Scripts/programs in the PROC.../bin directory should only be relevant to the user, so e.g. clean_template should definitely not be there. (Internally used scripts should be in bin/internal). There should be a cleaning script however, which removes all compiled files (and perhaps additional files that are not needed between runs).
>
> 4. Looking at the regular matrix.f files, they have a list of all processes
> C Process: g d~ > e+ e- d~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
> C WEIGHTED=10
> C Process: g d~ > mu+ mu- d~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
> C WEIGHTED=10
> C Process: g s~ > e+ e- s~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
> C WEIGHTED=10
> C Process: g s~ > mu+ mu- s~ WEIGHTED=5 QED=2 QCD=1 [ QCD ]
> while the loop_matrix.f only has the first process listed:
...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
274. By marco zaro

some mainly aestethic improvements, according to Johan's review

275. By marco zaro

fixed shower list in the run_card with the showerMCs that are actually available now, so HW, HW++, PY-Q

276. By marco zaro

all scripts in bin directory (except for split/combine_jobs) are now in python, like for madevent
the executable ./aMCatNLO has also been added

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (11.2 KiB)

Hi all,
> 11. There is no equivalent to the "launch" command within the mg5 interface in a given PROCNLO... directory. Probably, the best would be to use the same pattern as in ME processes, to move all commands relating to launch into an FKS_run_interface.py (or something like that) corresponding to the madevent.py interface. That way, it's possible to launch a run directly from the PROC directory. Right now, the only script available are generate_amcatnlo_events.sh and run_amcatnlo.sh, which seems completely different from the (very user friendly!) launch command.
So, now there is bin/aMCatNLO which open an interface a la madevent, where you can run launch (as in the mg5 shell), compile, generate_events, calculate_xsect. Scripts corresponding to these commands are also in the bin dir
Cheers
Marco

On 18 Sep 2012, at 11:52, marco zaro wrote:

> Hi Johan,
> thanks for the review.
> I started working on some of the points you raised (those which looked FKS-connected)
> I still have to work on the interface, in order to have the possibility to generate events outside mg5
> Thanks a lot
> Marco
>
> On 18 Sep 2012, at 09:43, Johan Alwall wrote:
>
>> Review: Needs Fixing
>>
>> Dear FKS/Loop authors,
>>
>> Please excuse my long interim in this review. I have now tested running and started on the Python review (starting with the core directory). I have to say that I am quite impressed with the level of user friendliness you have achieved so far, although there is of course still work to be done in this respect, some of which is mentioned below. Please find here a first set of comments, sorted under headers.
>>
>> ========================
>> Output to FKS:
>> ========================
>> 1. Why does
>> "INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10"
>> come twice? Is it just that one of the lines could be changed to better reflect what it does, or is the same operation in fact done twice?
> INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Processing color information for process: u u~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: c c~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Reusing existing color information for process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: s s~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: u~ u > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Processing color information for process: u~ u > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: c~ c > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: d~ d > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Reusing existing color information for process: d~ d > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> INFO: Generating Helas calls for FKS process process: s~ s > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> it actually...

Revision history for this message
Johan Alwall (johan-alwall) wrote :
Download full text (4.2 KiB)

Hello Marco & Paolo,

Thanks a lot for your super-fast fixes! It's really awesome!

> > 1. Why does
> > "INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2
> QCD=0 [ QCD ] WEIGHTED=10"
> > come twice?
> it actually does not appear twice, what (i think) appear twice is u u~ and u~
> u, which, so far, are treated as different

You are right - I'm too used to MG5 now :-) Sorry about that!

> > while the loop_matrix.f only has the first process listed:
> > C Process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
> processes whose matrix elements are identical.
> Ok, done

Thanks!

> > 5. Would it be a good idea to change the name of "LesHouches" to "Binoth" or
> "BinothLH"? We already have leshouches for the output to lhef format, and also
> use the lha format for parameter files, so it can be a bit confusing... (just
> a suggestion)
> changed to BinothLHA.f

Great!

> > ========================
> > Running FKS: (using p p > l+ l- as born process)
> > ========================
> > 6. What does:
> > "Found 16 correctly terminated jobs
> > random seed found in 'randinit' is 33
> > Total cross-section: 2.58399299e+03 +- 6.7365e+00 (2.6070e-01%)
> > Found 16 correctly terminated jobs
> > Total cross-section: 2.23890720e+03 +- 7.7439e+00 (3.4588e-01%)"
> > mean? (why is the cross section different between the two lines?)
> The first is the integral of the absolute value of the cross-section, the
> second the integral of the cross section (They are both needed since the
> weights are not all >0)
> I have changed the output in a clearer way

Perfect.

> > 9. I tried running with PYTHIA6PT output, and got the following result:
> It looks like Pythia6pt is not implemented yet. Checking into the logs they
> all terminate with "No such MonteCarlo yet".
> Removed Pythia6pt from the run_card.dat

Ok, thanks.

> > 10. I tried running with PYTHIA6Q output, and everything went well until the
> reweight step:
> > ...
> > Note: HERWIG6 output seems to work fine.
> >
> On my laptop everything seems to run fine, i was not able to reproduce this
> error.
> Changed the error msg

When I ran just now, it worked. Sorry for the false alarm.

> > 11. There is no equivalent to the "launch" command within the mg5 interface
> in a given PROCNLO... directory. Probably, the best would be to use the same
> pattern as in ME processes, to move all commands relating to launch into an
> FKS_run_interface.py (or something like that) corresponding to the madevent.py
> interface. That way, it's possible to launch a run directly from the PROC
> directory. Right now, the only script available are
> generate_amcatnlo_events.sh and run_amcatnlo.sh, which seems completely
> different from the (very user friendly!) launch command.
> So, now there is bin/aMCatNLO which open an interface a la madevent, where you
> can run launch (as in the mg5 shell), compile, generate_events,
> calculate_xsect. Scripts corresponding to these commands are also in the bin
> dir

Very nice. Thanks a lot!

There is a problem in the aMC@NLO interface (I'll let you know if I find more):

20. aMC@NLO interface fails to open cards:
"aMC@NLO>generate_events
Will run in mode aMC@NLO
Do you...

Read more...

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
277. By marco zaro

bug related to editing the cards after launch fixed. added do_open /check_open command to the aCMatNLO_run_interface

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (4.8 KiB)

Hi Johan,
i just fixed the issue with the open command (cp-ed the do_open and check_open from madevent_interface to amcatnlo_run_interface)
the command used by launch are all from the amcatnlo_run_interface none of them is written inside the FKS one
Cheers
Marco

On 19 Sep 2012, at 09:44, Johan Alwall wrote:

> Review: Needs Fixing
>
> Hello Marco & Paolo,
>
> Thanks a lot for your super-fast fixes! It's really awesome!
>
>>> 1. Why does
>>> "INFO: Generating Helas calls for FKS process process: u u~ > e+ e- QED=2
>> QCD=0 [ QCD ] WEIGHTED=10"
>>> come twice?
>> it actually does not appear twice, what (i think) appear twice is u u~ and u~
>> u, which, so far, are treated as different
>
> You are right - I'm too used to MG5 now :-) Sorry about that!
>
>>> while the loop_matrix.f only has the first process listed:
>>> C Process: d d~ > e+ e- QED=2 QCD=0 [ QCD ] WEIGHTED=10
>> processes whose matrix elements are identical.
>> Ok, done
>
> Thanks!
>
>>> 5. Would it be a good idea to change the name of "LesHouches" to "Binoth" or
>> "BinothLH"? We already have leshouches for the output to lhef format, and also
>> use the lha format for parameter files, so it can be a bit confusing... (just
>> a suggestion)
>> changed to BinothLHA.f
>
> Great!
>
>>> ========================
>>> Running FKS: (using p p > l+ l- as born process)
>>> ========================
>>> 6. What does:
>>> "Found 16 correctly terminated jobs
>>> random seed found in 'randinit' is 33
>>> Total cross-section: 2.58399299e+03 +- 6.7365e+00 (2.6070e-01%)
>>> Found 16 correctly terminated jobs
>>> Total cross-section: 2.23890720e+03 +- 7.7439e+00 (3.4588e-01%)"
>>> mean? (why is the cross section different between the two lines?)
>> The first is the integral of the absolute value of the cross-section, the
>> second the integral of the cross section (They are both needed since the
>> weights are not all >0)
>> I have changed the output in a clearer way
>
> Perfect.
>
>>> 9. I tried running with PYTHIA6PT output, and got the following result:
>> It looks like Pythia6pt is not implemented yet. Checking into the logs they
>> all terminate with "No such MonteCarlo yet".
>> Removed Pythia6pt from the run_card.dat
>
> Ok, thanks.
>
>>> 10. I tried running with PYTHIA6Q output, and everything went well until the
>> reweight step:
>>> ...
>>> Note: HERWIG6 output seems to work fine.
>>>
>> On my laptop everything seems to run fine, i was not able to reproduce this
>> error.
>> Changed the error msg
>
> When I ran just now, it worked. Sorry for the false alarm.
>
>>> 11. There is no equivalent to the "launch" command within the mg5 interface
>> in a given PROCNLO... directory. Probably, the best would be to use the same
>> pattern as in ME processes, to move all commands relating to launch into an
>> FKS_run_interface.py (or something like that) corresponding to the madevent.py
>> interface. That way, it's possible to launch a run directly from the PROC
>> directory. Right now, the only script available are
>> generate_amcatnlo_events.sh and run_amcatnlo.sh, which seems completely
>> different from the (very user friendly!) launch command.
>> So, now there is bin/aMCat...

Read more...

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hi Marco,

Awesome, thanks!

> i just fixed the issue with the open command (cp-ed the do_open and check_open
> from madevent_interface to amcatnlo_run_interface)
> the command used by launch are all from the amcatnlo_run_interface none of
> them is written inside the FKS one
> Cheers
> Marco

Revision history for this message
Johan Alwall (johan-alwall) wrote :
Download full text (5.7 KiB)

Ok, here is my second batch of comments, sorted by header. I keep running numbering just like Olivier, so it's easy for you to tick off everything that is answered or tested. This time, I think most of the comments are to Valentin.

========================
Output to FKS:
========================

21. Where is the g g > l+ l- in the p p > l+ l- process? I see it (in the permutation check) when I run check full p p > l+ l- [QCD] in the aMC@NLO interface (inside bin/mg5), but I can't find any mention of it in the NLO output directory.

========================
Models
========================

22. "aMC@NLO>generate p p > l+ l- [QCD QED]
Command "generate p p > l+ l- [QCD QED]" interrupted with error:
InvalidCmd : Perturbation order QED is not among the perturbation orders allowed for by the loop model."
Is the plan to include QED already for the release, or do we keep that "secret" until we have done some pheno with it?

========================
Python code
========================

base_objects.py:

23.
+ #
+ # ___34_____ The ';' line is a u-quark with ID 21
+ # 45/ ; The '|' line is a gluon with ID 1
+ # ------< ; The numbers are the interactions ID
+ # \___;______ The tag for this loop would be:
+ # 12 ((21,34),(1,45),(1,12))
+ #
I believe you mean "The ';' line is a gluon with ID 21" and "The '|' line is a u quark with ID 1" :-)
I have to say though that I love your extremely clear comments. Thanks!

24.
+ # PS: Notice that in the UFO model, the tag-information is limited to
+ # the minimally relevant one which are the loop particles specified in
+ # in the attribute below.
+ # 'loop_particles' is the list of all the loops giving this same
+ # counterterm contribution. Each loop being represented by a list of the
+ # PDG of the particles (not repeated) constituting it. If the loop particles
+ # are not specified then MG5 will account for this counterterm only once
+ # per concerned vertex.
I don't understand how you get from the loop particles only to the full loop tag (or is this not needed?). I also don't fully understand the last part about MG5 accounting for the counterterm only once - what happens if the loop tag is defined?

25. Model attribute "gauge": I think this warrants a comment to describe how to interpret this information. [0, 1] is quite cryptic...

export_v4.py:

26. create_couplings_main, create_couplings_part, etc: When you have a lot of lines to write that are the same for every output, perhaps it's nicer to use a template file and a replacement dictionary?

27. Please check correspondance between comments and class names, e.g.:
+#===============================================================================
+# ProcessExporterFortranMEGroup
+#===============================================================================
+class ProcessExporterFortranMEGroupComplexMass(ProcessExporterFortranMEGroup):

helas_call_writers.py:

28. get_loop_amp_helas_calls, get_loop_amplitude_helas_calls, FortranUFOHelasCallWrite...

Read more...

review: Needs Fixing
Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (6.6 KiB)

Ciao Johan,
so a quick answer wrt two issues you pointed:

g g > l+ l- should not be there, as it is loop induced and formally NNLO (order alpha_s^2). also, if if comes from a Z boson (on shell), it is zero because of somebody's theorem (I do not remeber the name...)

I do not think we are planning to support QED as perturbation in the first release of the code, we have not developed it yet...
I'll look through the other poinst
Thanks a lot

Cheers
Marco

On 19 Sep 2012, at 11:17, Johan Alwall wrote:

> Review: Needs Fixing
>
> Ok, here is my second batch of comments, sorted by header. I keep running numbering just like Olivier, so it's easy for you to tick off everything that is answered or tested. This time, I think most of the comments are to Valentin.
>
> ========================
> Output to FKS:
> ========================
>
> 21. Where is the g g > l+ l- in the p p > l+ l- process? I see it (in the permutation check) when I run check full p p > l+ l- [QCD] in the aMC@NLO interface (inside bin/mg5), but I can't find any mention of it in the NLO output directory.
>
> ========================
> Models
> ========================
>
> 22. "aMC@NLO>generate p p > l+ l- [QCD QED]
> Command "generate p p > l+ l- [QCD QED]" interrupted with error:
> InvalidCmd : Perturbation order QED is not among the perturbation orders allowed for by the loop model."
> Is the plan to include QED already for the release, or do we keep that "secret" until we have done some pheno with it?
>
> ========================
> Python code
> ========================
>
> base_objects.py:
>
> 23.
> + #
> + # ___34_____ The ';' line is a u-quark with ID 21
> + # 45/ ; The '|' line is a gluon with ID 1
> + # ------< ; The numbers are the interactions ID
> + # \___;______ The tag for this loop would be:
> + # 12 ((21,34),(1,45),(1,12))
> + #
> I believe you mean "The ';' line is a gluon with ID 21" and "The '|' line is a u quark with ID 1" :-)
> I have to say though that I love your extremely clear comments. Thanks!
>
> 24.
> + # PS: Notice that in the UFO model, the tag-information is limited to
> + # the minimally relevant one which are the loop particles specified in
> + # in the attribute below.
> + # 'loop_particles' is the list of all the loops giving this same
> + # counterterm contribution. Each loop being represented by a list of the
> + # PDG of the particles (not repeated) constituting it. If the loop particles
> + # are not specified then MG5 will account for this counterterm only once
> + # per concerned vertex.
> I don't understand how you get from the loop particles only to the full loop tag (or is this not needed?). I also don't fully understand the last part about MG5 accounting for the counterterm only once - what happens if the loop tag is defined?
>
> 25. Model attribute "gauge": I think this warrants a comment to describe how to interpret this information. [0, 1] is quite cryptic...
>
> export_v4.py:
>
> 26. create_couplings_main, ...

Read more...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
278. By marco zaro

added MCatNLO in Template/NLO/Source, corresponding to v. 404 op lp:madfks

279. By marco zaro

moved MCatNLO folder, started automatizing also the shower part

280. By marco zaro

some MCatNLO fortran source files were marked as executables. done chmod -x on them
created a command run_mcatnlo in amcatnlo_run_interface

281. By Olivier Mattelaer

temporary fix in order to make FKS5 runable.
Please Marco check my modif and look if you agree with it.

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :

Hi,

As Johan, said this is very impressive, especially by the accuracy of the warning.

36. (I just fix it in fact) in the revision 280, Mg5 crash on loading the file (since one variable was not define) I fix it in a simple way in 281. Pleas Marco check that this is indeed what you had in mind.

37. In aMCatNLO_run_interface.
In MG mode you do:
from madgraph import InvalidCmd, aMCatNLOError
while in ME mode you import:
from internal import InvalidCmd, MadGraph5Error
meaning that aMCatNLOError is not define in that mode.

38. You use aMCatNLOError as configuration error.
Meaning that such error is not a bug but a configuration error of the machine. This was designed for no internet connection, no g77/gfortran compiler,…
But looks like you raise it for kind of large type of error:
(like line 819, 948, 983, …)
Might be better to set another error as configuration error then (since those one should ask to report a bug report and not suggest to deal the problem by themselves and if needed ask a question).

39. when compiling Cuttools. What do you think about changing the message:
INFO: Compiling CutTools
by
INFO: Compiling CutTools (this might takes a couple minutes)

40. I crash with this error:
Command "output " interrupted in sub-command:
"output" with error:
AttributeError : 'MasterCmd' object has no attribute 'fastjet_config'
Please report this bug on https://bugs.launchpad.net/madgraph5
More information is found in 'MG5_debug'.
Please attach this file to your report.

This is a typical example of Configuration error. And which require a bit of information on
1) where to find the program to use.
2) How to link it.

41. In general (also in MG5), I found that we write too many information on the screen.
But in particular here:
INFO: Writing files in P0_ucx_ucx
INFO: Creating files in directory V0_ucx_ucx
INFO: Computing diagram color coefficients
INFO: Generating born Feynman diagrams for Process: u c~ > u c~ QED=0 QCD=2 [ QCD ] WEIGHTED=6

Would it be possible to reduce to:
INFO: Generating output for Process: u c~ > u c~ QED=0 QCD=2 [ QCD ] WEIGHTED=6

42. the help of generate/add should be updated as well as the autocompletion.

Otherwise what do you think about a wiki page for this merge.
Just including the number associated to the point that Johan and I (or other made)
and the status (pending, done,…) This will need a bit of work (to keep this up-to-date) but this can help us. If you agree I will made it.

Cheers,

Olivier

review: Needs Fixing
Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Olivier, all,

So we are now using a common numbering? Ok, let's try to keep up with that. :-)

> 36. (I just fix it in fact) in the revision 280, Mg5 crash on loading the file
> (since one variable was not define) I fix it in a simple way in 281. Pleas
> Marco check that this is indeed what you had in mind.

Thanks!

> 41. In general (also in MG5), I found that we write too many information on
> the screen.
> But in particular here:
> INFO: Writing files in P0_ucx_ucx
> INFO: Creating files in directory V0_ucx_ucx
> INFO: Computing diagram color coefficients
> INFO: Generating born Feynman diagrams for Process: u c~ > u c~ QED=0 QCD=2 [
> QCD ] WEIGHTED=6
>
> Would it be possible to reduce to:
> INFO: Generating output for Process: u c~ > u c~ QED=0 QCD=2 [ QCD ]
> WEIGHTED=6

In fact I don't agree here. The full information is useful to give the user a quick overview of what is written and where to find it (it is certainly very helpful for me!). For the user who doesn't care, he won't look anyway. So I would suggest to keep it exactly as it is. Just make sure that any warning/important info messages are output at the end, so they don't disappear in the flood.

> Otherwise what do you think about a wiki page for this merge.
> Just including the number associated to the point that Johan and I (or other
> made)
> and the status (pending, done,…) This will need a bit of work (to keep this
> up-to-date) but this can help us. If you agree I will made it.

This is a very good idea. Let's keep the discussion/posting of comments here (so it's all in one place, and also for future reference), but you keep a wiki page with the progress to make sure you don't miss anything important.

Cheers,
Johan

Revision history for this message
Johan Alwall (johan-alwall) wrote :
Download full text (3.2 KiB)

Ok I'm continuing my review.

========================
Interfaces
========================

43. Commands that should be used in all interfaces (in particular open, but perhaps also the main do_set routine) should be put in a common place, most naturally extended_cmd.py.

44. Commands that are common to all process generation interfaces (madgraph_interface, FKS_interface, etc.) and where we want to switch interface depending on the command, would be most natural to keep in a common interface. Examples are do_generate, do_launch, and perhaps also do_output (or we just assume that the user is not stupid enough to switch interface between a generate and an output command). Probably also set should be defined here, since we should be able to set all options in all interfaces. I'm not sure if the best is to put these in the master_interface or to have them in a separate mother interface. What do you think, Olivier?

45. When doing "launch ./DIR" from the bin/mg5 (or other) interface, it should be possible to automatically switch interface to the correct one (by looking at the directory). Marco had written something about this in rev. 273, but it doesn't seem to work.

46. For the check timing (as well, in fact, as all other commands whose main result is to display information) we should use Olivier's technique to display the result both in the page view mode and on the screen after exiting page view. I just ran a timing check, and when I pressed "q", it disappeared and isn't saved anywhere. This is also a comment to Olivier, since I think we should have the same functionality e.g. for display diagrams_text. Olivier, I think you figured out some way to do that, right? Let's use the same standard command everywhere (defined in extended_cmd.py).

47. Let's use a common standard for the capitalization of interface names in the switch command (it's funny with ML5 but mg5). I would suggest MG5, ML5, aMC@NLO, except that at this point everything is MG5... But perhaps that is clear enough.

48. Let's use a common standard also for capitalization of python modules. It looks nicer if all modules are all-lowercase (and might possibly avoid some problems in non-case-sensitive systems?), i.e., loop_interface.py, fks_interface.py. Or did you have some other thought about this?

49. There seems to be some problem with the storing of the command history between runs - when I close and restart the bin/mg5 interface, it doesn't remember any commands I entered in the FKS5 branch directory.

fks_interface.py:

50. When I do
display diagrams_text
there is no output. This can be quite useful in certain situations.

51. When I do
display diagrams
there is nothing in the resulting ps files indicating what is born and what is real. How about something like "Real process u~ u > mu+ mu- g corresponding to born process u~ u > mu+ mu- WEIGHTED=... [QCD] WEIGHTED=..."? Also for the virtual, although it's obvious from the presence of a loop, it could still be indicated. Also, why does it say [tree=QCD] for the reals and virtuals?

52. Same as above for display processes. There is no indication which processes have which function.

Sorry for the cosmetics, but I guess this is the...

Read more...

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
282. By marco zaro

renamed FKS_interface -> amcatnlo_interface
display diagrams_text works (point 50 of the review list) in amcatnlo_interface, and, as display processes, if no other argument is given (real,born,virt), prints a line explaining if the processes are born/real/virt (point 52). To be done (I do not really know how to) for display diagrams (51)
added amcatnlo_launcher in launch external program, so that now launch PATH works from mg5> also for a NLO process (point 45)

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (3.6 KiB)

Hi,
i have fixed points 45 48 50 and 52 in rev 282 on lp
Cheers
Marco

On 20 Sep 2012, at 08:24, Johan Alwall wrote:

> Review: Needs Fixing
>
> Ok I'm continuing my review.
>
> ========================
> Interfaces
> ========================
>
> 43. Commands that should be used in all interfaces (in particular open, but perhaps also the main do_set routine) should be put in a common place, most naturally extended_cmd.py.
>
> 44. Commands that are common to all process generation interfaces (madgraph_interface, FKS_interface, etc.) and where we want to switch interface depending on the command, would be most natural to keep in a common interface. Examples are do_generate, do_launch, and perhaps also do_output (or we just assume that the user is not stupid enough to switch interface between a generate and an output command). Probably also set should be defined here, since we should be able to set all options in all interfaces. I'm not sure if the best is to put these in the master_interface or to have them in a separate mother interface. What do you think, Olivier?
>
> 45. When doing "launch ./DIR" from the bin/mg5 (or other) interface, it should be possible to automatically switch interface to the correct one (by looking at the directory). Marco had written something about this in rev. 273, but it doesn't seem to work.
>
> 46. For the check timing (as well, in fact, as all other commands whose main result is to display information) we should use Olivier's technique to display the result both in the page view mode and on the screen after exiting page view. I just ran a timing check, and when I pressed "q", it disappeared and isn't saved anywhere. This is also a comment to Olivier, since I think we should have the same functionality e.g. for display diagrams_text. Olivier, I think you figured out some way to do that, right? Let's use the same standard command everywhere (defined in extended_cmd.py).
>
> 47. Let's use a common standard for the capitalization of interface names in the switch command (it's funny with ML5 but mg5). I would suggest MG5, ML5, aMC@NLO, except that at this point everything is MG5... But perhaps that is clear enough.
>
> 48. Let's use a common standard also for capitalization of python modules. It looks nicer if all modules are all-lowercase (and might possibly avoid some problems in non-case-sensitive systems?), i.e., loop_interface.py, fks_interface.py. Or did you have some other thought about this?
>
> 49. There seems to be some problem with the storing of the command history between runs - when I close and restart the bin/mg5 interface, it doesn't remember any commands I entered in the FKS5 branch directory.
>
> fks_interface.py:
>
> 50. When I do
> display diagrams_text
> there is no output. This can be quite useful in certain situations.
>
> 51. When I do
> display diagrams
> there is nothing in the resulting ps files indicating what is born and what is real. How about something like "Real process u~ u > mu+ mu- g corresponding to born process u~ u > mu+ mu- WEIGHTED=... [QCD] WEIGHTED=..."? Also for the virtual, although it's obvious from the presence of a loop, it could still be indicated. Also, why ...

Read more...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
283. By Paolo Torrielli

updates in the scripts that run mcatnlo for pythia6 and herwig6

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (3.5 KiB)

Hi Olivier,
thanks for the fixes 36/37
they are perfect.
Can we talk a bit about the errors?In amcatnlo_run_interface i define

class aMCatNLOError(Exception):
    pass
what do you mean by configuration error?
sorry but i may have done some mistakes, still i do not know what the differences are and when to raise an Error and a ConfigurationError (or at least, what the policy is about this for mg5)
furthermore
for the issue 40
i added in input/mg5_configuration.txt two lines, one for the lhapdf-config path and one for the fastjet-config path
it may be that the your mg5_configuration that is read in your case is not the one in input/ (do you have one for mg5 in ~/.mg5) and it has not those entries
Let me know if this is the case
Cheers
Marco

On 20 Sep 2012, at 01:21, Olivier Mattelaer wrote:

> Review: Needs Fixing
>
> Hi,
>
> As Johan, said this is very impressive, especially by the accuracy of the warning.
>
> 36. (I just fix it in fact) in the revision 280, Mg5 crash on loading the file (since one variable was not define) I fix it in a simple way in 281. Pleas Marco check that this is indeed what you had in mind.
>
> 37. In aMCatNLO_run_interface.
> In MG mode you do:
> from madgraph import InvalidCmd, aMCatNLOError
> while in ME mode you import:
> from internal import InvalidCmd, MadGraph5Error
> meaning that aMCatNLOError is not define in that mode.
>
> 38. You use aMCatNLOError as configuration error.
> Meaning that such error is not a bug but a configuration error of the machine. This was designed for no internet connection, no g77/gfortran compiler,…
> But looks like you raise it for kind of large type of error:
> (like line 819, 948, 983, …)
> Might be better to set another error as configuration error then (since those one should ask to report a bug report and not suggest to deal the problem by themselves and if needed ask a question).
>
> 39. when compiling Cuttools. What do you think about changing the message:
> INFO: Compiling CutTools
> by
> INFO: Compiling CutTools (this might takes a couple minutes)
>
> 40. I crash with this error:
> Command "output " interrupted in sub-command:
> "output" with error:
> AttributeError : 'MasterCmd' object has no attribute 'fastjet_config'
> Please report this bug on https://bugs.launchpad.net/madgraph5
> More information is found in 'MG5_debug'.
> Please attach this file to your report.
>
> This is a typical example of Configuration error. And which require a bit of information on
> 1) where to find the program to use.
> 2) How to link it.
>
> 41. In general (also in MG5), I found that we write too many information on the screen.
> But in particular here:
> INFO: Writing files in P0_ucx_ucx
> INFO: Creating files in directory V0_ucx_ucx
> INFO: Computing diagram color coefficients
> INFO: Generating born Feynman diagrams for Process: u c~ > u c~ QED=0 QCD=2 [ QCD ] WEIGHTED=6
>
> Would it be possible to reduce to:
> INFO: Generating output for Process: u c~ > u c~ QED=0 QCD=2 [ QCD ] WEIGHTED=6
>
> 42. the help of generate/add should be updated as well as the autocompletion.
>
>
>
> Otherwise what do you think about a wiki page for this merge.
> Just including the numbe...

Read more...

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (4.5 KiB)

Hi all,
I just committed rev 284, in which also mcatnlo is automatized in the whole chain (only for hw6 for today).
The status for now is that the user should write his own analysis and write the filename in the input file.
Together with Paolo we were thinking to export the showered event in the stdhep format, so that the analysis can be done externally with madanalysis.
This requires the stdhep code installed on the computer (http://cepa.fnal.gov/psm/stdhep/getStdHep.shtml).
Now:
shall we assume that every user has it (and hence will put the path to the libraries in the mg5_configuration.txt as for fastjet/lhapdf....)
or shall we include this in the mg5 release (e.g. in vendor)?
Let me know
Cheers
Marco

On 20 Sep 2012, at 12:16, marco zaro wrote:

> Hi Olivier,
> thanks for the fixes 36/37
> they are perfect.
> Can we talk a bit about the errors?In amcatnlo_run_interface i define
>
> class aMCatNLOError(Exception):
> pass
> what do you mean by configuration error?
> sorry but i may have done some mistakes, still i do not know what the differences are and when to raise an Error and a ConfigurationError (or at least, what the policy is about this for mg5)
> furthermore
> for the issue 40
> i added in input/mg5_configuration.txt two lines, one for the lhapdf-config path and one for the fastjet-config path
> it may be that the your mg5_configuration that is read in your case is not the one in input/ (do you have one for mg5 in ~/.mg5) and it has not those entries
> Let me know if this is the case
> Cheers
> Marco
>
>
>
> On 20 Sep 2012, at 01:21, Olivier Mattelaer wrote:
>
>> Review: Needs Fixing
>>
>> Hi,
>>
>> As Johan, said this is very impressive, especially by the accuracy of the warning.
>>
>> 36. (I just fix it in fact) in the revision 280, Mg5 crash on loading the file (since one variable was not define) I fix it in a simple way in 281. Pleas Marco check that this is indeed what you had in mind.
>>
>> 37. In aMCatNLO_run_interface.
>> In MG mode you do:
>> from madgraph import InvalidCmd, aMCatNLOError
>> while in ME mode you import:
>> from internal import InvalidCmd, MadGraph5Error
>> meaning that aMCatNLOError is not define in that mode.
>>
>> 38. You use aMCatNLOError as configuration error.
>> Meaning that such error is not a bug but a configuration error of the machine. This was designed for no internet connection, no g77/gfortran compiler,…
>> But looks like you raise it for kind of large type of error:
>> (like line 819, 948, 983, …)
>> Might be better to set another error as configuration error then (since those one should ask to report a bug report and not suggest to deal the problem by themselves and if needed ask a question).
>>
>> 39. when compiling Cuttools. What do you think about changing the message:
>> INFO: Compiling CutTools
>> by
>> INFO: Compiling CutTools (this might takes a couple minutes)
>>
>> 40. I crash with this error:
>> Command "output " interrupted in sub-command:
>> "output" with error:
>> AttributeError : 'MasterCmd' object has no attribute 'fastjet_config'
>> Please report this bug on https://bugs.launchpad.net/madgraph5
>> More information is found in 'MG5_debug'.
>> Please attach ...

Read more...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
284. By marco zaro

added command to shower generated events (included in the launch command)
run_amcatnlo + event file will shower the given event file.
works with/without lhapdf, for now only with herwig6
the analyse has still to be written by hand and written in the input file, but the idea is to generate a hepmc file to be passed to madanalisys

285. By marco zaro

also pythia6q mode works for MCatNLO

286. By marco zaro

added check to link lhapdf when launching mcatnlo (it could happen that the libs are not there)

287. By marco zaro

fixed FKS- loop optimized output. the files in bin/internal were not cp-ed

288. By Paolo Torrielli

irrelevant change in madfks_pydriver.f

289. By Paolo Torrielli

adapting the hw++ bash scripts to those for hw6 and py6. it does not work yet, working on that.
updated the Card/mcatnlo_card.dat consequently
irrelevant changes in the scripts for hw6 and py6

290. By marco zaro

fixed bug with the -h flag of the scripts in bin/
tests are always compiled, and python checks that none of them failed
V and F event order exchanged (now V first)

291. By Paolo Torrielli

a) updated the script for HWPP in order to make it maximally similar to the others
b) removed file HWPPInput.inputs
c) fixed a previous mistake in the scripts for HW6 and PY6 linked to the name of the
   executable for default pdfs (mistake made in version 289)
d) updated the mcatnlo_card.dat, allowing also for hadronization on/off for PY6, HWPP
e) updated madfks_pydriver.f consequently

STATUS: for HWPP it does not work yet, cause I did not have time to try the changes out.
Working on that.

292. By Olivier Mattelaer

fixing the drawing of the diagram for Loop cases (following last loop format)

293. By marco zaro

bug fixed: jobs with no events in some channels made MG quit.

294. By marco zaro

aestethic changes in the way mcatnlo runs.
now one folder (named RUN_$MCMODE_1/2/..) per run is created, which contains executable, input and output

295. By marco zaro

bug fixed: after launch command, the working dir is now the same as before

296. By marco zaro

fixed bug in rev294: the event file was not linked correctly in the running dir.
also modified hw6 py6q and py6pt scripts in order to read infos in the header of the event file in its original position

297. By marco zaro

fixed ch-dir back to original dir after launch

298. By marco zaro

added quick tutorial for aMC@NLO (type tutorial_nlo) and completion for output in amcatnlo_interface

299. By marco zaro

fixed a character which lead to problems in the tutorial_nlo

300. By marco zaro

mcatnlo compiles with stdhep (need to be installed by hand and that the path is specified into MCatNLO_MadFKS.inputs)
The MCat_NLO_MadFKS.inputs_an correspond to the script needed to perform an analyse
updated the interface

301. By Paolo Torrielli

fixes in the hw++ script, now it compiles. still a few adjustments needed for it to work properly

302. By marco zaro

added StdHEP to the packages that can be installed via the install command.
If it is not installed, a nice warning will be printed to the user, and the generation of the event will terminate without running mcatnlo
PROBLEM: the original (parton level) event file is overwritten when showering with MC@NLO-PYQ, probably there is a conflict with the assigned files unit.
The run terminates when reading the second event

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Marco,

It seems something went wrong when you created the tutorial - I get tutorial text without turning it on. Also, the tutorial text is for aMC@NLO although I'm in the mg5 interface. I simply did
bin/mg5
generate p p > l+ l-

and the text appeared.

Cheers,
Johan

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
303. By Olivier Mattelaer

fix tutorial_nlo to be always printed

304. By marco zaro

removed non-NLO relevant lines from tutorial_nlo
fixed bug: error 'no amplitudes generated' was printed after display diagrams in aMC@NLO mode

305. By marco zaro

the MCatNLO folder in Template/NLO has been removed
the MCatNLO package (together with StdHep) can be installed by typing
install MCatNLO-utilities

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Comments about the event output file:

53) Adding on to comment 12 about the Events/run_01/ directory structure, I would also suggest to have a more informative name for the events_1 file. How about amcatnlo_events.lhe, since it's an lhe file that can be directly run through a shower generator? I would suggest to pretty much copy (with suitable modifications) the full machinery for event file treatment and names that Olivier has implemented for LO.

54) Please create a new xml block for any information you want to keep in the header of the .lhe file. Right now, the header starts as
<LesHouchesEvents version="1.0">
  <!--
HERWIG6
  -->
  <header>
     1000
  <MG5ProcCard>
etc.
"HERWIG6" is crucial information, so it should absolutely be within a block (e.g. <NLOMC>) so it can easily be read by your shower MC files, which can then abort (if it's the wrong MC) or select appropriate settings (if it's PYQ/PYPT). Furthermore, the "1000" which suddenly comes at the top and bottom of the header should probably be in a block similar to the <MGGenerationInfo> block in the LO files.

Many thanks,
Johan

review: Needs Fixing
lp:~maddevelopers/mg5amcnlo/FKS5 updated
306. By marco zaro

the generated events are stored in Events/run_i (as for LO)
started some (small) work to have the html available also at NLO

Revision history for this message
marco zaro (marco-zaro) wrote :

Hi Johan,
thanks for the review
for 54) the mc is also written inside the run_card in the header, and there is where we check that it is the correct one
53) i have pushed rev 306, in which the lhe and hep file are stored in the run_i dirs under events. Also some mods towards having html working are there

this is what you get at the end of a run

The /Users/marcozaro/PhD/mg5/FKS5/FKS5/wNLO12/Events/run_01/events.lhe file has been generated.
It contains 10000 NLO events to be showered
   Prepairing MCatNLO run
   Compiling MCatNLO for HERWIG6...
                     ... done
   Running MCatNLO in /Users/marcozaro/PhD/mg5/FKS5/FKS5/wNLO12/MCATNLO/RUN_HERWIG6_1 (this may take some time)...
The file /Users/marcozaro/PhD/mg5/FKS5/FKS5/wNLO12/Events/run_01/events_HERWIG6.hep has been generated.
It contains showered and hadronized events in the StdHEP format obtained showering the parton-level event file /Users/marcozaro/PhD/mg5/FKS5/FKS5/wNLO12/Events/run_01/events.lhe

On 27 Sep 2012, at 15:23, Johan Alwall wrote:

> Review: Needs Fixing
>
> Comments about the event output file:
>
> 53) Adding on to comment 12 about the Events/run_01/ directory structure, I would also suggest to have a more informative name for the events_1 file. How about amcatnlo_events.lhe, since it's an lhe file that can be directly run through a shower generator? I would suggest to pretty much copy (with suitable modifications) the full machinery for event file treatment and names that Olivier has implemented for LO.
>
> 54) Please create a new xml block for any information you want to keep in the header of the .lhe file. Right now, the header starts as
> <LesHouchesEvents version="1.0">
> <!--
> HERWIG6
> -->
> <header>
> 1000
> <MG5ProcCard>
> etc.
> "HERWIG6" is crucial information, so it should absolutely be within a block (e.g. <NLOMC>) so it can easily be read by your shower MC files, which can then abort (if it's the wrong MC) or select appropriate settings (if it's PYQ/PYPT). Furthermore, the "1000" which suddenly comes at the top and bottom of the header should probably be in a block similar to the <MGGenerationInfo> block in the LO files.
>
> Many thanks,
> Johan
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Paolo Torrielli (paolo-torrielli) wrote :

Hi Johan,

> 54) Please create a new xml block for any information you want to keep in the header of the .lhe file. Right now, the header starts as
> <LesHouchesEvents version="1.0">
> <!--
> HERWIG6
> -->
> <header>
> 1000
> <MG5ProcCard>
> etc.
> "HERWIG6" is crucial information, so it should absolutely be within a block (e.g. <NLOMC>) so it can easily be read by your shower MC files, which can then abort (if it's the wrong MC) or select appropriate settings (if it's PYQ/PYPT). Furthermore, the "1000" which suddenly comes at the top and bottom of the header should probably be in a block similar to the <MGGenerationInfo> block in the LO files.
The scripts already read the header of the lhe file and perform a series of checks on the correctness of the MC used. In particular there is a "head -3" which supposes that the MC name is at line 3, and a "head -6" to read the number of events. These are the only 'delicate' things in the scripts, but I think they are ok if one keeps this structure unchanged.
If we want to change the structure, I propose something like

HERWIG6 #monte carlo
10000 #number of events

so one could grep for the strings after the '#'. But anyway, since it works well as it is, I'm not really keen on changing...
Cheers.
Paolo

> Many thanks,
> Johan
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Paolo,

> The scripts already read the header of the lhe file and perform a series of
> checks on the correctness of the MC used. In particular there is a "head -3"
> which supposes that the MC name is at line 3, and a "head -6" to read the
> number of events. These are the only 'delicate' things in the scripts, but I
> think they are ok if one keeps this structure unchanged.

Whoa! This is very dangerous, since it's completely counterintuitive, and also completely against the whole point with the xml format that was decided upon in the LHA.

> If we want to change the structure, I propose something like
>
> HERWIG6 #monte carlo
> 10000 #number of events

You can use this, as long as you keep the two lines inside a block (e.g., <MCatNLOInfo>). Then it's up to you how you want to search for the info (but, again, the point with using xml format is to use the tags to find the relevant information). If HERWIG6 is read from the run_card line, that's also fine - in that case, the other occurrences (outside of the block structure) should simply be removed.

Cheers,
Johan

review: Needs Fixing
Revision history for this message
Paolo Torrielli (paolo-torrielli) wrote :

Hi Johan,

> If HERWIG6 is read from the run_card line, that's also fine - in that case, the other occurrences (outside of the block structure) should simply be removed.
Actually it is read twice, one from the run card, one from the third line of the file, and the two strings are compared
(to check that the file is self consistent, maybe it is useless but not bad) and also compared to the shower mode that one choses in the input file.

Anyway, if you want to change the format, I have nothing against, simply I need to know the new format soon and update the scripts.

Thank you!
Cheers.

Paolo

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Paolo,

Please change the format according to the guidelines I expressed above (e.g., <MCatNLOInfo>), or choose other block names as you wish. These names are defined by the MC authors (i.e., you), so I don't have any strong preference, as long as it follows the xml block structure.

Thanks a lot!
Johan

Revision history for this message
Paolo Torrielli (paolo-torrielli) wrote :

Hello Johan,
ok, I'll discuss with Marco and perform the changes.
Thanks!
Cheers.
Paolo

On Sep 28, 2012, at 8:14 AM, Johan Alwall <email address hidden>
 wrote:

> Hello Paolo,
>
> Please change the format according to the guidelines I expressed above (e.g., <MCatNLOInfo>), or choose other block names as you wish. These names are defined by the MC authors (i.e., you), so I don't have any strong preference, as long as it follows the xml block structure.
>
> Thanks a lot!
> Johan
> --
> https://code.launchpad.net/~maddevelopers/madgraph5/FKS5/+merge/97762
> Your team MadDevelopers is subscribed to branch lp:~maddevelopers/madgraph5/FKS5.

Revision history for this message
Johan Alwall (johan-alwall) wrote :

Hello Marco,

Some more problems (I record them here):

54. When I generate a process in the latest version of the branch, it says:
"""MCatNLO-utilities is not installed.
If you want to shower events with MC@NLO please install it by typing "install MCatNLO-utilities" and regenerate the process"""
This should obviously not be the case. I should be able to produce the events, then install the utilities, and then use the "pythia" or "herwig" (or perhaps just "shower", since the run knows already which shower is needed) command to shower whenever I want.

55. I started a launch for an FKS directory (in the bin/mg5 interface) and then interrupted it with Ctrl-C. I get the following error:
"""Using built-in libraries for PDFs
Compiling source...
^CCommand "launch " interrupted in sub-command:
"launch" with error:
aMCatNLOError : Compilation failed, check /Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/compile_amcatnlo.log for details
Please report this bug on https://bugs.launchpad.net/madgraph5
More information is found in 'MG5_debug'.
Please attach this file to your report."""

56. Then, when I restart the launch, it says:
"""Command "launch " interrupted in sub-command:
"launch" with error:
NameError : global name 'MadEventAlreadyRunning' is not defined
Please report this bug on https://bugs.launchpad.net/madgraph5
More information is found in 'MG5_debug'."""

57. This one is for Olivier I guess: I try to remove some file using the "!", but when I tab complete, it crashes:
"""aMC@NLO>!rm ./PROCNLO_loop_<TAB>
OneLinePathCompletion instance has no attribute 'completion_prefix'
Traceback (most recent call last):
  File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 61, in deco_f
    return f(*args, **opt)
  File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 117, in print_suggestions
    longest_match_length += len(self.completion_prefix)
AttributeError: OneLinePathCompletion instance has no attribute 'completion_prefix'"""

58. When I try going into the process directory and run run_mcatnlo, I get:
"""Johan-Alwalls-MacBook-Air:PROCNLO_loop_sm_1 alwall$ bin/run_mcatnlo
No module named madgraph.interface.extended_cmd
Traceback (most recent call last):
  File "bin/run_mcatnlo", line 29, in <module>
    import amcatnlo_run_interface as run
  File "/Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/bin/internal/amcatnlo_run_interface.py", line 71, in <module>
    import internal.various.gen_crossxhtml as gen_crossxhtml
ImportError: No module named various.gen_crossxhtml"""
Same thing in "calculate_xsect".

Cheers,
Johan

review: Needs Fixing
Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (3.4 KiB)

Hi Johan,
so:
On 28 Sep 2012, at 09:37, Johan Alwall wrote:

> Review: Needs Fixing
>
> Hello Marco,
>
> Some more problems (I record them here):
>
> 54. When I generate a process in the latest version of the branch, it says:
> """MCatNLO-utilities is not installed.
> If you want to shower events with MC@NLO please install it by typing "install MCatNLO-utilities" and regenerate the process"""
> This should obviously not be the case. I should be able to produce the events, then install the utilities, and then use the "pythia" or "herwig" (or perhaps just "shower", since the run knows already which shower is needed) command to shower whenever I want.
ok, this can be fixed.
however, it looks like the package_info.dat is not currently updated on the uclouvain server.
i have modified it in the www branch, and then ran the update script on the mg web page (there it correctly pulls the new revision with the modified file, but in the end the file is still the old one)

>
> 55. I started a launch for an FKS directory (in the bin/mg5 interface) and then interrupted it with Ctrl-C. I get the following error:
> """Using built-in libraries for PDFs
> Compiling source...
> ^CCommand "launch " interrupted in sub-command:
> "launch" with error:
> aMCatNLOError : Compilation failed, check /Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/compile_amcatnlo.log for details
> Please report this bug on https://bugs.launchpad.net/madgraph5
> More information is found in 'MG5_debug'.
> Please attach this file to your report."""

ok, there were many os. system used to launch programs.
moved to misc.call

>
> 56. Then, when I restart the launch, it says:
> """Command "launch " interrupted in sub-command:
> "launch" with error:
> NameError : global name 'MadEventAlreadyRunning' is not defined
> Please report this bug on https://bugs.launchpad.net/madgraph5
> More information is found in 'MG5_debug'."""
i forgot to rename it, fixed.
also added funcction do_quit to the amcatnlo_run_interface

>
> 57. This one is for Olivier I guess: I try to remove some file using the "!", but when I tab complete, it crashes:
> """aMC@NLO>!rm ./PROCNLO_loop_<TAB>
> OneLinePathCompletion instance has no attribute 'completion_prefix'
> Traceback (most recent call last):
> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 61, in deco_f
> return f(*args, **opt)
> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 117, in print_suggestions
> longest_match_length += len(self.completion_prefix)
> AttributeError: OneLinePathCompletion instance has no attribute 'completion_prefix'"""
>
> 58. When I try going into the process directory and run run_mcatnlo, I get:
> """Johan-Alwalls-MacBook-Air:PROCNLO_loop_sm_1 alwall$ bin/run_mcatnlo
> No module named madgraph.interface.extended_cmd
> Traceback (most recent call last):
> File "bin/run_mcatnlo", line 29, in <module>
> import amcatnlo_run_interface as run
> File "/Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/bin/internal/amcatnlo_run_interface.py", line 71, in <module>
> import internal.various.gen_crossxhtml as gen_crossxhtml
> ImportError: No module named various.gen...

Read more...

lp:~maddevelopers/mg5amcnlo/FKS5 updated
307. By marco zaro

fixes in mcatnlo_run interface.
in particular all calls to os.system have been replaced to misc.call

308. By marco zaro

added MCatNLO-utilities_path in mg5_configuration.
this way the run_mcatnlo command will automatically detect if these utils have been installed, also after exporting the dir

Revision history for this message
marco zaro (marco-zaro) wrote :
Download full text (3.7 KiB)

Hi,
54 is also fixed

On 28 Sep 2012, at 10:46, marco zaro wrote:

> Hi Johan,
> so:
> On 28 Sep 2012, at 09:37, Johan Alwall wrote:
>
>> Review: Needs Fixing
>>
>> Hello Marco,
>>
>> Some more problems (I record them here):
>>
>> 54. When I generate a process in the latest version of the branch, it says:
>> """MCatNLO-utilities is not installed.
>> If you want to shower events with MC@NLO please install it by typing "install MCatNLO-utilities" and regenerate the process"""
>> This should obviously not be the case. I should be able to produce the events, then install the utilities, and then use the "pythia" or "herwig" (or perhaps just "shower", since the run knows already which shower is needed) command to shower whenever I want.
> ok, this can be fixed.
> however, it looks like the package_info.dat is not currently updated on the uclouvain server.
> i have modified it in the www branch, and then ran the update script on the mg web page (there it correctly pulls the new revision with the modified file, but in the end the file is still the old one)
>
>
>>
>> 55. I started a launch for an FKS directory (in the bin/mg5 interface) and then interrupted it with Ctrl-C. I get the following error:
>> """Using built-in libraries for PDFs
>> Compiling source...
>> ^CCommand "launch " interrupted in sub-command:
>> "launch" with error:
>> aMCatNLOError : Compilation failed, check /Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/compile_amcatnlo.log for details
>> Please report this bug on https://bugs.launchpad.net/madgraph5
>> More information is found in 'MG5_debug'.
>> Please attach this file to your report."""
>
> ok, there were many os. system used to launch programs.
> moved to misc.call
>
>
>>
>> 56. Then, when I restart the launch, it says:
>> """Command "launch " interrupted in sub-command:
>> "launch" with error:
>> NameError : global name 'MadEventAlreadyRunning' is not defined
>> Please report this bug on https://bugs.launchpad.net/madgraph5
>> More information is found in 'MG5_debug'."""
> i forgot to rename it, fixed.
> also added funcction do_quit to the amcatnlo_run_interface
>
>>
>> 57. This one is for Olivier I guess: I try to remove some file using the "!", but when I tab complete, it crashes:
>> """aMC@NLO>!rm ./PROCNLO_loop_<TAB>
>> OneLinePathCompletion instance has no attribute 'completion_prefix'
>> Traceback (most recent call last):
>> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 61, in deco_f
>> return f(*args, **opt)
>> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 117, in print_suggestions
>> longest_match_length += len(self.completion_prefix)
>> AttributeError: OneLinePathCompletion instance has no attribute 'completion_prefix'"""
>>
>> 58. When I try going into the process directory and run run_mcatnlo, I get:
>> """Johan-Alwalls-MacBook-Air:PROCNLO_loop_sm_1 alwall$ bin/run_mcatnlo
>> No module named madgraph.interface.extended_cmd
>> Traceback (most recent call last):
>> File "bin/run_mcatnlo", line 29, in <module>
>> import amcatnlo_run_interface as run
>> File "/Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/bin/internal/amcatnlo_run_...

Read more...

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) wrote :
Download full text (5.1 KiB)

Hi,

> """aMC@NLO>!rm ./PROCNLO_loop_<TAB>
> OneLinePathCompletion instance has no attribute 'completion_prefix'
> Traceback (most recent call last):
> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 61, in deco_f
> return f(*args, **opt)
> File "/Users/alwall/MadGraph/FKS5/madgraph/interface/extended_cmd.py", line 117, in print_suggestions
> longest_match_length += len(self.completion_prefix)
> AttributeError: OneLinePathCompletion instance has no attribute 'completion_prefix'"""

I fix a similar problem in 1.5.0 so maybe this will be solve when the merge will be done.
Otherwise, I need to know all the command that you type (including ctrl-c and ctrl-d) in order to be able to reproduce it.
And not sure if this is usefull or not, but do you use lib edit or the one provide by mac (for the autocompletion)

Otherwise:

59: The installation of hepmc didn't detect that I'm in 64 bit (which is important for it) that g77 is not installed.
Please look at our modif to pythia-pgs and how we install it since this is mainly the same problem.

Cheers,

Olivier

On Sep 28, 2012, at 7:30 AM, marco zaro <email address hidden> wrote:

> Hi,
> 54 is also fixed
>
> On 28 Sep 2012, at 10:46, marco zaro wrote:
>
>> Hi Johan,
>> so:
>> On 28 Sep 2012, at 09:37, Johan Alwall wrote:
>>
>>> Review: Needs Fixing
>>>
>>> Hello Marco,
>>>
>>> Some more problems (I record them here):
>>>
>>> 54. When I generate a process in the latest version of the branch, it says:
>>> """MCatNLO-utilities is not installed.
>>> If you want to shower events with MC@NLO please install it by typing "install MCatNLO-utilities" and regenerate the process"""
>>> This should obviously not be the case. I should be able to produce the events, then install the utilities, and then use the "pythia" or "herwig" (or perhaps just "shower", since the run knows already which shower is needed) command to shower whenever I want.
>> ok, this can be fixed.
>> however, it looks like the package_info.dat is not currently updated on the uclouvain server.
>> i have modified it in the www branch, and then ran the update script on the mg web page (there it correctly pulls the new revision with the modified file, but in the end the file is still the old one)
>>
>>
>>>
>>> 55. I started a launch for an FKS directory (in the bin/mg5 interface) and then interrupted it with Ctrl-C. I get the following error:
>>> """Using built-in libraries for PDFs
>>> Compiling source...
>>> ^CCommand "launch " interrupted in sub-command:
>>> "launch" with error:
>>> aMCatNLOError : Compilation failed, check /Users/alwall/MadGraph/FKS5/PROCNLO_loop_sm_1/compile_amcatnlo.log for details
>>> Please report this bug on https://bugs.launchpad.net/madgraph5
>>> More information is found in 'MG5_debug'.
>>> Please attach this file to your report."""
>>
>> ok, there were many os. system used to launch programs.
>> moved to misc.call
>>
>>
>>>
>>> 56. Then, when I restart the launch, it says:
>>> """Command "launch " interrupted in sub-command:
>>> "launch" with error:
>>> NameError : global name 'MadEventAlreadyRunning' is not defined
>>> Please report this bug on https://bugs.launchpad.ne...

Read more...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'DECAY/decay.f'
2--- DECAY/decay.f 2011-06-01 21:40:33 +0000
3+++ DECAY/decay.f 2012-09-28 12:29:27 +0000
4@@ -1431,6 +1431,7 @@
5 if(calc_width.gt.0d0) then
6 diff=(calc_width-MC_width)/(calc_width+MC_width)*100d0
7 endif
8+ backspace(lunout)
9 write(lunout,'(a3,2x,i2,2x,e12.5,2x,e10.5,
10 & 1x,f5.2,3x,e10.5,3x,f5.1)')
11 & id(ip),imode,calc_width,MC_width,diff,mxwgt,eff
12
13=== modified file 'DECAY/makefile'
14--- DECAY/makefile 2011-07-19 08:50:59 +0000
15+++ DECAY/makefile 2012-09-28 12:29:27 +0000
16@@ -1,6 +1,6 @@
17 # Check for ../make_opts
18-ifeq ($(wildcard ../Template/Source/make_opts), ../Template/Source/make_opts)
19- include ../Template/Source/make_opts
20+ifeq ($(wildcard ../Template/LO/Source/make_opts), ../Template/LO/Source/make_opts)
21+ include ../Template/LO/Source/make_opts
22 else
23 include ../madevent/Source/make_opts
24 endif
25
26=== modified file 'HELAS/Makefile'
27--- HELAS/Makefile 2011-07-10 19:01:23 +0000
28+++ HELAS/Makefile 2012-09-28 12:29:27 +0000
29@@ -15,8 +15,8 @@
30 # ----------------------------------------------------------------------------
31
32 # Check for ../make_opts
33-ifeq ($(wildcard ../Template/Source/make_opts), ../Template/Source/make_opts)
34- include ../Template/Source/make_opts
35+ifeq ($(wildcard ../Template/LO/Source/make_opts), ../Template/LO/Source/make_opts)
36+ include ../Template/LO/Source/make_opts
37 else
38 include ../madevent/Source/make_opts
39 endif
40
41=== added directory 'Template'
42=== renamed directory 'Template' => 'Template/LO'
43=== modified file 'Template/LO/Cards/run_card.dat'
44--- Template/Cards/run_card.dat 2011-12-10 06:11:03 +0000
45+++ Template/LO/Cards/run_card.dat 2012-09-28 12:29:27 +0000
46@@ -27,7 +27,8 @@
47 .false. = gridpack !True = setting up the grid pack
48 #*********************************************************************
49 # Number of events and rnd seed *
50-# Warning: Do not generate more than 100K event in a single run *
51+# Warning: Do not generate more than 1M events in a single run *
52+# If you want to run Pythia, avoid more than 50k events in a run. *
53 #*********************************************************************
54 10000 = nevents ! Number of unweighted events requested
55 0 = iseed ! rnd seed (0=assigned automatically=default))
56@@ -194,6 +195,17 @@
57 1d5 = ptj4max ! maximum pt for the fourth jet in pt
58 0 = cutuse ! reject event if fails any (0) / all (1) jet pt cuts
59 #*********************************************************************
60+# Control the pt's of leptons sorted by pt *
61+#*********************************************************************
62+ 0 = ptl1min ! minimum pt for the leading lepton in pt
63+ 0 = ptl2min ! minimum pt for the second lepton in pt
64+ 0 = ptl3min ! minimum pt for the third lepton in pt
65+ 0 = ptl4min ! minimum pt for the fourth lepton in pt
66+ 1d5 = ptl1max ! maximum pt for the leading lepton in pt
67+ 1d5 = ptl2max ! maximum pt for the second lepton in pt
68+ 1d5 = ptl3max ! maximum pt for the third lepton in pt
69+ 1d5 = ptl4max ! maximum pt for the fourth lepton in pt
70+#*********************************************************************
71 # Control the Ht(k)=Sum of k leading jets *
72 #*********************************************************************
73 0 = htjmin ! minimum jet HT=Sum(jet pt)
74
75=== modified file 'Template/LO/README'
76--- Template/README 2011-07-06 23:13:41 +0000
77+++ Template/LO/README 2012-09-28 12:29:27 +0000
78@@ -1,9 +1,8 @@
79 MadGraph/MadEvent 5
80-By Fabio Maltoni, Tim Stelzer and the CP3 development team
81+By Johan Alwall, Michel Herquet, Fabio Maltoni, Olivier Mattelaer and Tim Stelzer
82
83 http://madgraph.phys.ucl.ac.be/
84 http://madgraph.hep.uiuc.edu/
85-http://madgraph.roma2.infn.it/
86
87 Information on the process to be generated is found in the file
88 index.html in this directory, which should be viewed using your web
89@@ -11,8 +10,14 @@
90 process. Please refer to the README file one directory above this
91 (MadGraph5_vx_x_x/) for instructions on how to generate a process.
92
93+This README includes information on how
94+A) generate events
95+B) how to run in cluster/multi-core mode
96+C) how to launch sequential run (called multi-run)
97+D) How to launch Pythia/PGS/Delphes
98+E) How to prevent automatic opening of html pages
99
100-To generate events:
101+A) To generate events:
102 -------------------
103
104 1) Specify the model parameters. The model parameters include masses
105@@ -32,7 +37,7 @@
106 example file.
107 **Warning!** For several reasons, avoid running more than 100,000
108 events per run. Instead perform several runs to reach the luminosity
109-you need, e.g. using the bin/multi_run script. Subsequent runs
110+you need, e.g. using the multi_run describe below. Subsequent runs
111 automatically update the random seed, so the results from different
112 runs are statistically independent.
113
114@@ -42,10 +47,88 @@
115 4) Follow the generation and look at the results in the file
116 HTML/crossx.html, using your web browser.
117
118-5) If you want to run Pythia and/or PGS/Delphes on the events,
119-download the Pythia/PGS package (and Delphes) and untar one directory
120-above this (the MadGraph5 directory) and run make. Make sure the cards
121-pythia_card.dat and pgs_card.dat are present in the Cards/ directory.
122-If this is the case, Pythia and PGS will automatically be run by
123-generate_events, or, for an existing run, use bin/run_pythia and
124-bin/run_pgs.
125+5) If you want to run Pythia and/or PGS/Delphes on the events.
126+You first need to install it. For this launch MG5 ($MG5PATH/bin/mg5)
127+and type `install pythia-pgs`/ `install Delphes`.
128+If they are detected, the first question asked when launching ./bin/generate_events
129+should be something like:
130+Which programs do you want to run?
131+ 0 / auto : running existing card
132+ 1 / parton : Madevent
133+ 2 / pythia : MadEvent + Pythia.
134+ 3 / pgs : MadEvent + Pythia + PGS.
135+ [0, 1, 2, 3, auto, parton, pythia, pgs][20s to answer]
136+if this is not that means that you need to specify the path of the new program
137+in the file Cards/me5_configuration.txt . By default they are
138+installed in the MG5 directory.
139+
140+If you need to run one of those programs on some events which are already generated
141+please see instructions below.
142+
143+
144+B) Running in cluster or multicore mode:
145+----------------------------------------
146+
147+In order to automatically run in cluster or multicore mode, please set
148+the flag run_mode in the Cards/me5_configuration.txt file (or in the
149+input/mg5_configuration.txt file before you generate your process):
150+
151+# Default Running mode
152+# 0: single machine/ 1: cluster / 2: multicore
153+run_mode = 0
154+
155+You can also specify the cluster type (for cluster mode) or your
156+preferred number of CPUs (for multicore mode - note that by default,
157+the maximum number of cores is used) by setting cluster_type and
158+nb_core.
159+
160+
161+C) Launch sequential runs for generation of large number of events:
162+-------------------------------------------------------------------
163+
164+For various reason, we recommend not to generate more than 100k events
165+per run. In order to simplify generating large numbers of events,
166+we have created a special command 'multi_run', which is equivalent to
167+running generate_events multiple times (ensuring that the random seed is
168+different for each run), and also automatically combines the resulting
169+lhe files into a single file.
170+This command can be launched via the madevent user interface
171+./bin/madevent using the following command:
172+multi_run NBRUN [RUN_NAME] [options]
173+For more information about this command (valid options), you can type
174+`help multi_run` inside the interface.
175+
176+Note that you can also launch a command whithout entering the interactive mode:
177+./bin/madevent multi_run NBRUN
178+
179+
180+D) Launching pythia/pgs/delphes on a (previously) generated sample:
181+-------------------------------------------------------------------
182+
183+In this section, I will presupose that the corresponding package is
184+already installed and configured properly. (See section how to generate
185+events if this is not the case)
186+
187+In order to launch pythia/pgs/delphes on a sample, you need first to
188+launch the interactive session of madevent `./bin/madevent`
189+and then you can enter of the following command
190+pythia RUN [--run_options]
191+pgs RUN [--run_options]
192+delphes RUN [--run_options]
193+where RUN is the run_name of the run. One of the convenient options is
194+--tag=XXXX
195+which allow to specify the tag name in case of multiple runs with
196+the same program. Note that by default, a unique run tag is generated
197+for each time you run.
198+
199+E) How to prevent automatic opening of the crossx.html page:
200+------------------------------------------------------------
201+
202+Edit the file ./Cards/me5_configuration.txt and set
203+the option automatic_html_opening to `False`.
204+You can also edit the MG5 configuration card
205+input/mg5_configuration.txt
206+in order to have this value on False by default for all subsequently
207+generated processes.
208+
209+
210
211=== modified file 'Template/LO/Source/PDF/pdfwrap.f'
212--- Template/Source/PDF/pdfwrap.f 2010-10-30 03:26:37 +0000
213+++ Template/LO/Source/PDF/pdfwrap.f 2012-09-28 12:29:27 +0000
214@@ -250,13 +250,13 @@
215 .'cteq5f3,','cteq5f4,','cteq5m1,','ctq5hq1,','cteq5l1,',
216 .'cteq6_m,','cteq6_d,','cteq6_l,','cteq6l1,'
217 c
218-c
219- write(6,*) 'Setting it to default cteq6l1'
220- pdlabel='cteq6l1'
221- asmz=0.130d0
222- nloop=1
223- Call SetCtq6(4)
224-
225+c make madgraph to stop evaluating
226+ stop 1
227+c write(6,*) 'Setting it to default cteq6l1'
228+c pdlabel='cteq6l1'
229+c asmz=0.130d0
230+c nloop=1
231+c Call SetCtq6(4)
232 endif
233 return
234 end
235
236=== modified file 'Template/LO/Source/PDF/pdfwrap_lhapdf.f'
237--- Template/Source/PDF/pdfwrap_lhapdf.f 2010-10-30 03:26:37 +0000
238+++ Template/LO/Source/PDF/pdfwrap_lhapdf.f 2012-09-28 12:29:27 +0000
239@@ -54,7 +54,7 @@
240 if(exists)return
241 enddo
242 print*,'Could not find PDFsets directory, quitting'
243- stop
244+ stop 1
245
246 return
247 end
248
249=== modified file 'Template/LO/Source/cuts.inc'
250--- Template/Source/cuts.inc 2011-06-02 20:40:32 +0000
251+++ Template/LO/Source/cuts.inc 2012-09-28 12:29:27 +0000
252@@ -29,6 +29,8 @@
253 REAL*8 cutuse
254 REAL*8 ptj1min,ptj2min,ptj3min,ptj4min
255 REAL*8 ptj1max,ptj2max,ptj3max,ptj4max
256+ REAL*8 ptl1min,ptl2min,ptl3min,ptl4min
257+ REAL*8 ptl1max,ptl2max,ptl3max,ptl4max
258 REAL*8 ht2min,ht3min,ht4min
259 REAL*8 ht2max,ht3max,ht4max
260 REAL*8 htjmin,htjmax,ihtmin,ihtmax
261@@ -48,6 +50,10 @@
262 & ptj2min,ptj2max,
263 & ptj3min,ptj3max,
264 & ptj4min,ptj4max,
265+ & ptl1min,ptl1max,
266+ & ptl2min,ptl2max,
267+ & ptl3min,ptl3max,
268+ & ptl4min,ptl4max,
269 & cutuse,
270 & ht2min,ht3min,ht4min,
271 & ht2max,ht3max,ht4max,
272
273=== modified file 'Template/LO/Source/genps.inc'
274--- Template/Source/genps.inc 2011-05-29 07:23:58 +0000
275+++ Template/LO/Source/genps.inc 2012-09-28 12:29:27 +0000
276@@ -32,4 +32,4 @@
277 REAL*8 LIMHEL
278 PARAMETER(LIMHEL=1e-6)
279 INTEGER MAXTRIES
280- PARAMETER(MAXTRIES=10)
281+ PARAMETER(MAXTRIES=100)
282
283=== modified file 'Template/LO/Source/setrun.f'
284--- Template/Source/setrun.f 2011-10-05 16:27:00 +0000
285+++ Template/LO/Source/setrun.f 2012-09-28 12:29:27 +0000
286@@ -264,6 +264,19 @@
287 call get_real (npara,param,value,"cutuse",cutuse,0d0)
288
289 c*********************************************************************
290+c Check the pt's of leptons sorted by pt *
291+c*********************************************************************
292+
293+ call get_real (npara,param,value,"ptl1min",ptl1min,0d0)
294+ call get_real (npara,param,value,"ptl1max",ptl1max,1d5)
295+ call get_real (npara,param,value,"ptl2min",ptl2min,0d0)
296+ call get_real (npara,param,value,"ptl2max",ptl2max,1d5)
297+ call get_real (npara,param,value,"ptl3min",ptl3min,0d0)
298+ call get_real (npara,param,value,"ptl3max",ptl3max,1d5)
299+ call get_real (npara,param,value,"ptl4min",ptl4min,0d0)
300+ call get_real (npara,param,value,"ptl4max",ptl4max,1d5)
301+
302+c*********************************************************************
303 c Check Ht *
304 c*********************************************************************
305
306
307=== modified file 'Template/LO/SubProcesses/addmothers.f'
308--- Template/SubProcesses/addmothers.f 2012-02-08 08:52:30 +0000
309+++ Template/LO/SubProcesses/addmothers.f 2012-09-28 12:29:27 +0000
310@@ -29,7 +29,7 @@
311 c Variables for combination of color indices (including multipart. vert)
312 integer maxcolmp
313 parameter(maxcolmp=20)
314- integer ncolmp,icolmp(2,maxcolmp)
315+ integer ncolmp,icolmp(2,maxcolmp),is_colors(2,nincoming)
316
317 double precision ZERO
318 parameter (ZERO=0d0)
319@@ -145,7 +145,19 @@
320
321 c Store original maxcolor to know if we have epsilon vertices
322 maxorg=maxcolor
323-
324+c Keep track of IS colors that go through to final state
325+c (since we shouldn't replace pop-up indices with those)
326+ do i=1,nincoming
327+ do j=1,2
328+ is_colors(j,i)=0
329+ do k=3,nexternal
330+ if (iabs(icolalt(j,i)).eq.iabs(icolalt(j,k))) then
331+c This color is going through to FS
332+ is_colors(j,i)=iabs(icolalt(j,i))
333+ endif
334+ enddo
335+ enddo
336+ enddo
337 c
338 c Get mother information from chosen graph
339 c
340@@ -212,7 +224,7 @@
341 c print *,'t-channel: ',i,ida(1),ida(2),mo_color
342 c print *,'colors: ',((icolmp(j,k),j=1,2),k=1,ncolmp)
343 maxcolor=fix_tchannel_color(mo_color,maxcolor,
344- $ ncolmp,icolmp,i,icolalt)
345+ $ ncolmp,icolmp,i,icolalt,is_colors)
346 tchannel=.true.
347 cycle
348 else
349@@ -264,17 +276,23 @@
350 c print *,'s-channel: ',i,mo_color,ida(1),ida(2)
351 c print *,'colors: ',((icolmp(j,k),j=1,2),k=1,ncolmp)
352 if(mo_color.eq.1) then ! color singlet
353- maxcolor=elim_indices(0,0,ncolmp,icolmp,i,icolalt,maxcolor)
354+ maxcolor=elim_indices(0,0,ncolmp,icolmp,i,icolalt,
355+ $ is_colors,maxcolor)
356 elseif(mo_color.eq.-3) then ! color anti-triplet
357- maxcolor=elim_indices(0,1,ncolmp,icolmp,i,icolalt,maxcolor)
358+ maxcolor=elim_indices(0,1,ncolmp,icolmp,i,icolalt,
359+ $ is_colors,maxcolor)
360 elseif(mo_color.eq.3) then ! color triplet
361- maxcolor=elim_indices(1,0,ncolmp,icolmp,i,icolalt,maxcolor)
362+ maxcolor=elim_indices(1,0,ncolmp,icolmp,i,icolalt,
363+ $ is_colors,maxcolor)
364 elseif(mo_color.eq.-6) then ! color anti-sextet
365- maxcolor=elim_indices(0,2,ncolmp,icolmp,i,icolalt,maxcolor)
366+ maxcolor=elim_indices(0,2,ncolmp,icolmp,i,icolalt,
367+ $ is_colors,maxcolor)
368 elseif(mo_color.eq.6) then ! color sextet
369- maxcolor=elim_indices(2,0,ncolmp,icolmp,i,icolalt,maxcolor)
370+ maxcolor=elim_indices(2,0,ncolmp,icolmp,i,icolalt,
371+ $ is_colors,maxcolor)
372 elseif(mo_color.eq.8) then ! color octet
373- maxcolor=elim_indices(1,1,ncolmp,icolmp,i,icolalt,maxcolor)
374+ maxcolor=elim_indices(1,1,ncolmp,icolmp,i,icolalt,
375+ $ is_colors,maxcolor)
376 else ! 2 indicates multipart. vertex
377 da_color(1) = get_color(jpart(1,ida(1)))
378 da_color(2) = get_color(jpart(1,ida(2)))
379@@ -450,7 +468,7 @@
380
381 c********************************************************************
382 function fix_tchannel_color(mo_color,maxcolor,ncolmp,icolmp,ires,
383- $ icol)
384+ $ icol,is_colors)
385 c********************************************************************
386 c Successively eliminate identical pairwise color indices from the
387 c icolmp list, until only (max) one triplet and one antitriplet remains
388@@ -461,6 +479,7 @@
389 integer fix_tchannel_color
390 integer mo_color,maxcolor,ncolmp,icolmp(2,*)
391 integer ires,icol(2,-nexternal+2:2*nexternal-3)
392+ integer is_colors(2,nincoming)
393 integer i,j,i3,i3bar,max3,max3bar,min3,min3bar,maxcol,mincol
394
395 c Successively eliminate color indices in pairs until only the wanted
396@@ -478,26 +497,18 @@
397 i3bar=0
398 icol(1,ires)=0
399 icol(2,ires)=0
400- min3=1000
401- max3=0
402- min3bar=1000
403- max3bar=0
404 do i=1,ncolmp
405 if(icolmp(1,i).gt.0)then
406 i3=i3+1
407 c color for t-channels needs to be reversed
408 if(i3.eq.1) icol(2,ires)=icolmp(1,i)
409 if(i3.eq.2) icol(1,ires)=-icolmp(1,i)
410- if(icolmp(1,i).gt.max3) max3=icolmp(1,i)
411- if(icolmp(1,i).lt.min3) min3=icolmp(1,i)
412 endif
413 if(icolmp(2,i).gt.0)then
414 i3bar=i3bar+1
415 c color for t-channels needs to be reversed
416 if(i3bar.eq.1) icol(1,ires)=icolmp(2,i)
417 if(i3bar.eq.2) icol(2,ires)=-icolmp(2,i)
418- if(icolmp(2,i).gt.max3bar) max3bar=icolmp(2,i)
419- if(icolmp(2,i).lt.min3bar) min3bar=icolmp(2,i)
420 endif
421 enddo
422
423@@ -513,7 +524,10 @@
424 if(mo_color.eq.8.and.i3.eq.1.and.i3bar.eq.1) return
425
426 c Make sure that max and min don't come from the same octet
427- call clean_max_min(icolmp,ncolmp,max3,min3,max3bar,min3bar,i3,i3bar)
428+ call find_max_min(icolmp,ncolmp,max3,min3,max3bar,min3bar,
429+ $ i3,i3bar,is_colors)
430+c print *,'After finding: ',ncolmp,((icolmp(j,i),j=1,2),i=1,ncolmp)
431+c print *,'mo_color = ',mo_color
432
433 if(mo_color.le.1.and.i3-i3bar.eq.2.or.
434 $ mo_color.le.1.and.i3bar-i3.eq.2.or.
435@@ -533,6 +547,17 @@
436 enddo
437 c print *,'Replaced ',maxcol,' by ',mincol
438 elseif(mo_color.le.1.and.i3.eq.2.and.i3bar.eq.2) then
439+c Ensure that max > min
440+ if(max3bar.lt.min3)then
441+ i=min3
442+ min3=max3bar
443+ max3bar=i
444+ endif
445+ if(max3.lt.min3bar)then
446+ i=min3bar
447+ min3bar=max3
448+ max3=i
449+ endif
450 c Replace the maximum indices with the minimum ones everywhere
451 do i=ires+1,-1
452 do j=1,2
453@@ -597,7 +622,8 @@
454 end
455
456 c*******************************************************************
457- function elim_indices(n3,n3bar,ncolmp,icolmp,ires,icol,maxcolor)
458+ function elim_indices(n3,n3bar,ncolmp,icolmp,ires,icol,
459+ $ is_colors,maxcolor)
460 c*******************************************************************
461 c Successively eliminate identical pairwise color indices from the
462 c icolmp list, until only the wanted indices remain
463@@ -614,6 +640,7 @@
464 integer elim_indices
465 integer n3,n3bar,ncolmp,icolmp(2,*),maxcolor
466 integer ires,icol(2,-nexternal+2:2*nexternal-3)
467+ integer is_colors(2,nincoming)
468 integer i,j,i3,i3bar
469
470 c Successively eliminate color indices in pairs until only the wanted
471@@ -669,7 +696,8 @@
472 $ n3.eq.1.and.n3bar.eq.1.and.i3-i3bar.eq.0.or.
473 $ n3.eq.0.and.n3bar.eq.0.and.i3-i3bar.eq.0)then
474 c We have a previous epsilon which gives the wrong pop-up index
475- call fix_s_color_indices(n3,n3bar,i3,i3bar,ncolmp,icolmp,ires,icol)
476+ call fix_s_color_indices(n3,n3bar,i3,i3bar,ncolmp,icolmp,
477+ $ ires,icol,is_colors)
478 else
479 c Don't know how to deal with this
480 call write_error(1001,n3,n3bar)
481@@ -683,7 +711,7 @@
482
483 c*******************************************************************
484 subroutine fix_s_color_indices(n3,n3bar,i3,i3bar,ncolmp,icolmp,
485- $ ires,icol)
486+ $ ires,icol,is_colors)
487 c*******************************************************************
488 c
489 c Fix color flow if some particle has got the wrong pop-up color
490@@ -694,37 +722,27 @@
491 include 'nexternal.inc'
492 integer n3,n3bar,ncolmp,icolmp(2,*),maxcolor
493 integer ires,icol(2,-nexternal+2:2*nexternal-3)
494+ integer is_colors(2,nincoming)
495 integer i,j,i3,i3bar
496 integer max_n3,max_n3bar,min_n3,min_n3bar,maxcol,mincol
497
498- max_n3=0
499- max_n3bar=0
500- min_n3=1000
501- min_n3bar=1000
502- do i=1,ncolmp
503- if(icolmp(1,i).gt.max_n3)
504- $ max_n3=icolmp(1,i)
505- if(icolmp(2,i).gt.max_n3bar)
506- $ max_n3bar=icolmp(2,i)
507- if(icolmp(1,i).gt.0.and.icolmp(1,i).lt.min_n3)
508- $ min_n3=icolmp(1,i)
509- if(icolmp(2,i).gt.0.and.icolmp(2,i).lt.min_n3bar)
510- $ min_n3bar=icolmp(2,i)
511- enddo
512-
513 icol(1,ires)=0
514 icol(2,ires)=0
515
516+c print *,'Colors: ',ncolmp,((icolmp(j,i),j=1,2),i=1,ncolmp)
517+c print *,'n3,n3bar,i3,i3bar: ',n3,n3bar,i3,i3bar
518+
519 c Make sure that max and min don't come from the same octet
520- call clean_max_min(icolmp,ncolmp,max_n3,min_n3,
521- $ max_n3bar,min_n3bar,i3,i3bar)
522+ call find_max_min(icolmp,ncolmp,max_n3,min_n3,
523+ $ max_n3bar,min_n3bar,i3,i3bar,is_colors)
524+c print *,'max3,min3bar,min3,max3bar: ',max_n3,min_n3bar,min_n3,max_n3bar
525
526 if(n3.eq.1.and.n3bar.eq.0.and.i3-i3bar.eq.n3.or.
527 $ n3bar.eq.1.and.n3.eq.0.and.i3bar-i3.eq.n3bar.or.
528 $ n3bar.eq.1.and.n3.eq.1.and.i3bar-i3.eq.0.or.
529 $ n3bar.eq.0.and.n3.eq.0.and.i3bar-i3.eq.0)then
530 c Replace the highest 3bar-index with the lowest 3-index,
531-c and vice versa
532+c or vice versa
533 maxcol=max(max_n3,max_n3bar)
534 if(maxcol.eq.max_n3) then
535 mincol=min_n3bar
536@@ -754,73 +772,117 @@
537 end
538
539 c*******************************************************************************
540- subroutine clean_max_min(icolmp,ncolmp,max3,min3,max3bar,min3bar,i3,i3bar)
541+ subroutine find_max_min(icolmp,ncolmp,max3,min3,max3bar,min3bar,
542+ $ i3,i3bar,is_colors)
543 c*******************************************************************************
544 implicit none
545+ include 'nexternal.inc'
546 integer ncolmp,icolmp(2,*)
547- integer i,j,max3,max3bar,min3,min3bar,i3,i3bar
548-
549-c Make sure that max and min don't come from the same octet
550+ integer is_colors(2,nincoming)
551+ integer i,j,k,max3,max3bar,min3,min3bar,i3,i3bar,i3now,i3barnow
552+ integer allpairs(2,nexternal),npairs,maxcol,mincol
553+
554+ i3now=i3
555+ i3barnow=i3bar
556+
557+c Create all possible pairs (3,3bar) that
558+c 1. come from different octets, 2. are different,
559+c 3. don't contain any color lines passing through the event
560+ npairs = 0
561+ do 20 i=1,ncolmp
562+ if(icolmp(1,i).eq.0) goto 20
563+ do k=1,nincoming
564+ if(icolmp(1,i).eq.is_colors(1,k)) goto 20
565+ enddo
566+ do 10 j=1,ncolmp
567+ if(i.eq.j.or.icolmp(2,j).eq.0.or.
568+ $ icolmp(1,i).eq.icolmp(2,j)) goto 10
569+ do k=1,nincoming
570+ if(icolmp(2,j).eq.is_colors(2,k)) goto 10
571+ enddo
572+ npairs=npairs+1
573+ allpairs(1,npairs)=icolmp(1,i)
574+ allpairs(2,npairs)=icolmp(2,j)
575+ 10 enddo
576+ 20 enddo
577+
578+c print *,'is_colors: ',((is_colors(i,j),i=1,2),j=1,nincoming)
579+c print *,'pairs: ',((allpairs(i,j),i=1,2),j=1,npairs)
580+
581+c Find the pairs with maximum 3 and 3bar
582+ min3=1000
583+ min3bar=1000
584+ max3=0
585+ max3bar=0
586+ do i=1,npairs
587+ if(allpairs(1,i).gt.max3.and.
588+ $ (allpairs(2,i).lt.max3bar.or.
589+ $ allpairs(1,i).gt.allpairs(2,i)))then
590+ max3=allpairs(1,i)
591+ min3bar=allpairs(2,i)
592+ else if(allpairs(2,i).gt.max3bar.and.
593+ $ (allpairs(1,i).lt.max3.or.
594+ $ allpairs(2,i).gt.allpairs(1,i)))then
595+ max3bar=allpairs(2,i)
596+ min3=allpairs(1,i)
597+ endif
598+ enddo
599+
600+c Find "maximum" pairs with minimum 3 and 3bar
601+ do i=1,npairs
602+ if(allpairs(1,i).eq.max3.and.
603+ $ allpairs(2,i).lt.min3bar.and.
604+ $ allpairs(2,i).ne.max3bar)
605+ $ min3bar=allpairs(2,i)
606+ if(allpairs(2,i).eq.max3bar.and.
607+ $ allpairs(1,i).lt.min3.and.
608+ $ allpairs(1,i).ne.max3)
609+ $ min3=allpairs(1,i)
610+ enddo
611+
612+ if (max3.gt.0.and.max3bar.gt.0) then
613+c We have found our two pairs, so we're done
614+ return
615+ endif
616+
617+ if(max3.gt.0.or.max3bar.gt.0)then
618+ i3now=i3now-1
619+ i3barnow=i3barnow-1
620+ endif
621+
622+c Find pair for non-maximum (where we allow all colors)
623+ maxcol=max(max3,max3bar)
624+ if(maxcol.eq.max3) then
625+ mincol=min3bar
626+ else
627+ mincol=min3
628+ endif
629+
630+ npairs=0
631 do i=1,ncolmp
632- if(icolmp(1,i).eq.max3.and.icolmp(2,i).eq.min3bar)then
633- min3bar=1000
634- do j=1,ncolmp
635- if(j.eq.i) cycle
636- if(icolmp(2,j).lt.min3bar) min3bar=icolmp(2,j)
637- enddo
638- endif
639- if(icolmp(2,i).eq.max3bar.and.icolmp(1,i).eq.min3)then
640- min3=1000
641- do j=1,ncolmp
642- if(j.eq.i) cycle
643- if(icolmp(1,j).lt.min3) min3=icolmp(1,j)
644- enddo
645- endif
646+ if(icolmp(1,i).eq.0.and.i3now.gt.0) cycle
647+ if(icolmp(1,i).eq.maxcol.or.icolmp(1,i).eq.mincol)
648+ $ cycle
649+ do j=1,ncolmp
650+ if(icolmp(2,j).eq.0.and.i3barnow.gt.0) cycle
651+ if(i.eq.j.or.icolmp(1,i).eq.icolmp(2,j)) cycle
652+ if(icolmp(2,j).eq.maxcol.or.icolmp(2,j).eq.mincol)
653+ $ cycle
654+ npairs=npairs+1
655+ allpairs(1,npairs)=icolmp(1,i)
656+ allpairs(2,npairs)=icolmp(2,j)
657+ enddo
658 enddo
659-
660-c ...and that max and min are different
661- if(i3.gt.1.and.max3.eq.min3.or.i3bar.gt.1.and.max3bar.eq.min3bar)then
662- if(max3.gt.max3bar)then
663-c Need to change min3, while still ensuring that max3bar is ok
664- max3bar=0
665- min3=1000
666- do i=1,ncolmp
667- if(icolmp(2,i).gt.max3bar.and.icolmp(2,i).ne.min3bar)
668- $ max3bar=icolmp(2,i)
669- if(icolmp(1,i).lt.min3.and.icolmp(1,i).ne.max3)
670- $ min3=icolmp(1,i)
671- enddo
672-c Make sure that max3bar and min3 don't come from the same octet
673- do i=1,ncolmp
674- if(icolmp(2,i).eq.max3bar.and.icolmp(1,i).eq.min3)then
675- min3=1000
676- do j=1,ncolmp
677- if(j.eq.i.or.icolmp(1,j).eq.max3) cycle
678- if(icolmp(1,j).lt.min3) min3=icolmp(1,j)
679- enddo
680- endif
681- enddo
682+ if(npairs.ge.1)then
683+ if(maxcol.eq.max3)then
684+ min3=allpairs(1,1)
685+ max3bar=allpairs(2,1)
686 else
687-c Need to change min3bar, while still ensuring that max3 is ok
688- max3=0
689- min3bar=1000
690- do i=1,ncolmp
691- if(icolmp(1,i).gt.max3.and.icolmp(1,i).ne.min3)
692- $ max3=icolmp(1,i)
693- if(icolmp(2,i).lt.min3bar.and.icolmp(2,i).ne.max3bar)
694- $ min3bar=icolmp(2,i)
695- enddo
696-c Make sure that max3 and min3bar don't come from the same octet
697- do i=1,ncolmp
698- if(icolmp(1,i).eq.max3.and.icolmp(2,i).eq.min3bar)then
699- min3bar=1000
700- do j=1,ncolmp
701- if(j.eq.i.or.icolmp(2,j).eq.max3bar) cycle
702- if(icolmp(2,j).lt.min3bar) min3bar=icolmp(2,j)
703- enddo
704- endif
705- enddo
706+ max3=allpairs(1,1)
707+ min3bar=allpairs(2,1)
708 endif
709 endif
710+
711+c print *,'allpairs: ',((allpairs(i,j),i=1,2),j=1,npairs)
712
713 end
714
715=== modified file 'Template/LO/SubProcesses/cuts.f'
716--- Template/SubProcesses/cuts.f 2011-12-13 16:49:59 +0000
717+++ Template/LO/SubProcesses/cuts.f 2012-09-28 12:29:27 +0000
718@@ -51,7 +51,7 @@
719 C
720 LOGICAL FIRSTTIME,FIRSTTIME2,pass_bw,notgood,good,foundheavy
721 LOGICAL DEBUG
722- integer i,j,njets,nheavyjets,hardj1,hardj2
723+ integer i,j,njets,nheavyjets,nleptons,hardj1,hardj2
724 REAL*8 XVAR,ptmax1,ptmax2,htj,tmp,inclht
725 real*8 ptemp(0:3), ptemp2(0:3)
726 character*20 formstr
727@@ -74,6 +74,7 @@
728
729 double precision ptjet(nexternal)
730 double precision ptheavyjet(nexternal)
731+ double precision ptlepton(nexternal)
732 double precision temp
733
734 double precision etmin(nincoming+1:nexternal),etamax(nincoming+1:nexternal)
735@@ -93,6 +94,9 @@
736 logical jetor
737 common/to_jet_cuts/ ptjmin4,ptjmax4,htjmin4,htjmax4,jetor
738
739+ double precision ptlmin4(4),ptlmax4(4)
740+ common/to_lepton_cuts/ ptlmin4,ptlmax4
741+
742 c
743 c Special cuts
744 c
745@@ -545,7 +549,66 @@
746 passcuts=.false.
747 return
748 endif
749-
750+
751+C
752+C maximal and minimal pt of the leptons sorted by pt
753+c
754+ nleptons=0
755+
756+ if(ptl1min.gt.0.or.ptl2min.gt.0.or.ptl3min.gt.0.or.ptl4min.gt.0.or.
757+ $ ptl1max.lt.1d5.or.ptl2max.lt.1d5.or.
758+ $ ptl3max.lt.1d5.or.ptl4max.lt.1d5) then
759+
760+c - fill ptlepton with the pt's of the leptons.
761+ do i=nincoming+1,nexternal
762+ if(is_a_l(i)) then
763+ nleptons=nleptons+1
764+ ptlepton(nleptons)=pt(p(0,i))
765+ endif
766+ enddo
767+ if(debug) write (*,*) 'not yet ordered ',njets,' ',ptjet
768+
769+c - check existance of leptons if lepton cuts are on
770+ if(nleptons.lt.1.and.ptl1min.gt.0.or.
771+ $ nleptons.lt.2.and.ptl2min.gt.0.or.
772+ $ nleptons.lt.3.and.ptl3min.gt.0.or.
773+ $ nleptons.lt.4.and.ptl4min.gt.0)then
774+ if(debug) write (*,*) i, ' too few leptons -> fails'
775+ passcuts=.false.
776+ return
777+ endif
778+
779+c - sort lepton pts
780+ do i=1,nleptons-1
781+ do j=i+1,nleptons
782+ if(ptlepton(j).gt.ptlepton(i)) then
783+ temp=ptlepton(i)
784+ ptlepton(i)=ptlepton(j)
785+ ptlepton(j)=temp
786+ endif
787+ enddo
788+ enddo
789+ if(debug) write (*,*) 'ordered ',nleptons,' ',ptlepton
790+
791+ if(nleptons.gt.0) then
792+
793+ notgood = .false.
794+ do i=1,nleptons
795+ if(debug) write (*,*) i,ptlepton(i), ' ',ptlmin4(min(i,4)),':',ptlmax4(min(i,4))
796+c--- if one of the leptons does not pass, the event is rejected
797+ notgood=notgood.or.(ptlepton(i).gt.ptlmax4(min(i,4))).or.
798+ $ (ptlepton(i).lt.ptlmin4(min(i,4)))
799+ if(debug) write (*,*) i,' notgood total:', notgood
800+ enddo
801+
802+
803+ if (notgood) then
804+ if(debug) write (*,*) i, ' multiple pt -> fails'
805+ passcuts=.false.
806+ return
807+ endif
808+ endif
809+ endif
810 C>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
811 C SPECIAL CUTS
812 C<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
813
814=== modified file 'Template/LO/SubProcesses/myamp.f'
815--- Template/SubProcesses/myamp.f 2011-10-10 07:34:37 +0000
816+++ Template/LO/SubProcesses/myamp.f 2012-09-28 12:29:27 +0000
817@@ -566,6 +566,10 @@
818 xo = max(xo, ht4min**2/stot)
819 xo = max(xo, misset**2/stot)
820 xo = max(xo, ptllmin**2/stot)
821+ xo = max(xo, ptl1min**2/stot)
822+ xo = max(xo, ptl2min**2/stot)
823+ xo = max(xo, ptl3min**2/stot)
824+ xo = max(xo, ptl4min**2/stot)
825 if (swidth(i).eq.0.and.xo.eq.1d0/stot) then
826 write(*,*) 'Warning: No minimum found for integration'
827 write(*,*) ' Setting minimum to ',1d0/stot
828
829=== modified file 'Template/LO/SubProcesses/setcuts.f'
830--- Template/SubProcesses/setcuts.f 2012-02-24 08:51:01 +0000
831+++ Template/LO/SubProcesses/setcuts.f 2012-09-28 12:29:27 +0000
832@@ -59,6 +59,9 @@
833 logical jetor
834 common/to_jet_cuts/ ptjmin4,ptjmax4,htjmin4,htjmax4,jetor
835
836+ double precision ptlmin4(4),ptlmax4(4)
837+ common/to_lepton_cuts/ ptlmin4,ptlmax4
838+
839 double precision xqcutij(nexternal,nexternal),xqcuti(nexternal)
840 common/to_xqcuts/xqcutij,xqcuti
841 c
842@@ -413,6 +416,20 @@
843 inclHtmax=ihtmax
844
845 jetor = cutuse.eq.0d0
846+
847+c
848+c EXTRA LEPTON CUTS
849+c
850+ ptlmin4(1)=ptl1min
851+ ptlmin4(2)=ptl2min
852+ ptlmin4(3)=ptl3min
853+ ptlmin4(4)=ptl4min
854+
855+ ptlmax4(1)=ptl1max
856+ ptlmax4(2)=ptl2max
857+ ptlmax4(3)=ptl3max
858+ ptlmax4(4)=ptl4max
859+
860 c
861 c ERROR TRAPS
862 c
863
864=== modified file 'Template/LO/bin/internal/addmasses.py'
865--- Template/bin/internal/addmasses.py 2011-07-26 16:15:01 +0000
866+++ Template/LO/bin/internal/addmasses.py 2012-09-28 12:29:27 +0000
867@@ -174,7 +174,6 @@
868 event.append(Particle(nup,t))
869 counter=counter+1
870
871-
872 #default is to skip this
873 if motherFlag:
874
875@@ -223,41 +222,20 @@
876 mySub = re.compile(s1)
877 event_description = mySub.sub(str(nup),event_description)
878
879-
880 if nAdded>0:
881- totalLength = len(event)+1
882- newPosition = []
883- iPos=0
884- while iPos<totalLength:
885- for p in event:
886- if p.mo1==iPos:
887- newPosition.append(p.no)
888- iPos=iPos+1
889-
890- iUp=1
891- event0=[]
892- for ip in newPosition:
893- event0.append(event[ip-1])
894-
895- iUp=0
896- for p in event0:
897- iUp=iUp+1
898- if p.no != iUp:
899- ip=iUp
900- while ip<totalLength-1:
901- pp=event0[ip]
902- if pp.mo1==p.no and pp.mo1>pp.no:
903- pp.mo1=pp.mo2=iUp
904- ip=ip+1
905- p.no=iUp
906-
907- iUp=0
908- for p in event0:
909- event[iUp]=event0[iUp]
910- iUp=iUp+1
911-
912-
913-
914+ for ip in range(len(event)):
915+ l=event[ip]
916+ if l.mo1 > ip + 1:
917+ nmo=l.mo1
918+ event.insert(ip, event.pop(l.mo1-1))
919+ event[ip].no = ip + 1
920+ for l2 in event[ip + 1:]:
921+ if l2.no > ip and l2.no < nmo + 1:
922+ l2.no += 1
923+ if l2.mo1 == nmo:
924+ l2.mo1 = l2.mo2 = ip + 1
925+ elif l2.mo1 > ip and l2.mo1 < nmo:
926+ l2.mo1 = l2.mo2 = l2.mo1 + 1
927
928 # identify mothers
929 particleDict={}
930@@ -268,14 +246,15 @@
931 pass
932 else:
933 if p.mo1 in particleDict:
934- l=[particleDict[p.mo1]]
935+ l=particleDict[p.mo1]
936 l.append(p.no)
937 else:
938- l=p.no
939+ l=[p.no]
940 particleDict[p.mo1]=l
941
942 # repair kinematics
943 for k in particleDict:
944+ if len(particleDict[k]) != 2: continue
945 t=particleDict[k]
946 p1=event[t[0]-1]
947 p1.mom.boost(event[k-1].mom,-1)
948
949=== modified file 'Template/LO/bin/internal/run_pythia'
950--- Template/bin/internal/run_pythia 2011-10-18 03:42:31 +0000
951+++ Template/LO/bin/internal/run_pythia 2012-09-28 12:29:27 +0000
952@@ -19,4 +19,5 @@
953 echo " LHAPATH=$pydir/PDFsets" >> ../Cards/pythia_card.dat
954 export PDG_MASS_TBL=$pydir/mass_width_2004.mc
955
956-$pydir/pythia && touch pythia.done
957\ No newline at end of file
958+$pydir/pythia && touch pythia.done
959+
960
961=== modified file 'Template/LO/bin/madevent'
962--- Template/bin/madevent 2012-02-08 05:31:40 +0000
963+++ Template/LO/bin/madevent 2012-09-28 12:29:27 +0000
964@@ -33,18 +33,44 @@
965 sys.path.insert(0, root_path)
966
967
968+
969+class MyOptParser(optparse.OptionParser):
970+
971+ class InvalidOption(Exception): pass
972+
973+ def error(self, msg=''):
974+ raise MyOptParser.InvalidOption(msg)
975+
976+
977+
978+
979 # Write out nice usage message if called with -h or --help
980 usage = "usage: %prog [options] [FILE] "
981-parser = optparse.OptionParser(usage=usage)
982+parser = MyOptParser(usage=usage)
983 parser.add_option("-l", "--logging", default='INFO',
984 help="logging level (DEBUG|INFO|WARNING|ERROR|CRITICAL) [%default]")
985-parser.add_option("-f", "--file", default='',
986- help="Use script file FILE")
987 parser.add_option("","--web", action="store_true", default=False, dest='web', \
988 help='force to be in secure mode')
989 parser.add_option("","--debug", action="store_true", default=False, dest='debug', \
990 help='force to launch debug mode')
991-(options, args) = parser.parse_args()
992+parser_error = ''
993+done = False
994+for i in range(len(sys.argv)-1):
995+ try:
996+ (options, args) = parser.parse_args(sys.argv[1:len(sys.argv)-i])
997+ done = True
998+ except MyOptParser.InvalidOption, error:
999+ pass
1000+ else:
1001+ args += sys.argv[len(sys.argv)-i:]
1002+if not done:
1003+ # raise correct error:
1004+ try:
1005+ (options, args) = parser.parse_args()
1006+ except MyOptParser.InvalidOption, error:
1007+ print error
1008+ sys.exit(2)
1009+
1010 if len(args) == 0:
1011 args = ''
1012
1013@@ -115,23 +141,33 @@
1014
1015 # Call the cmd interface main loop
1016 try:
1017- if options.file or args:
1018+ if (args and os.path.exists(args[0])):
1019 # They are an input file
1020- if args:
1021- input_file = args[0]
1022- else:
1023- input_file = options.file
1024+ input_file = args[0]
1025 if options.web:
1026 cmd_line = cmd_interface.MadEventCmd()
1027 cmd_line.debug_output = os.path.join(os.path.dirname(input_file),'generation.log')
1028 cmd_line.use_rawinput = False
1029 cmd_line.run_cmd('import command ' + input_file)
1030- sys.exit()
1031+ cmd_line.run_cmd('quit')
1032 else:
1033 cmd_line = cmd_interface.MadEventCmdShell()
1034 cmd_line.use_rawinput = False
1035 cmd_line.run_cmd('import command ' + input_file)
1036- sys.exit()
1037+ cmd_line.run_cmd('quit')
1038+ elif args:
1039+ # a single command is provided
1040+ cmd_line = cmd_interface.MadEventCmd()
1041+ if not hasattr(cmd_line, 'do_%s' % args[0]):
1042+ if parser_error:
1043+ print parser_error
1044+ print 'and %s can not be interpreted as a valid command.' % args[0]
1045+ else:
1046+ print 'ERROR: %s not a valid command. Please retry' % args[0]
1047+ else:
1048+ cmd_line.use_rawinput = False
1049+ cmd_line.run_cmd(' '.join(args))
1050+ cmd_line.run_cmd('quit')
1051 else:
1052 # Interactive mode
1053 if options.web:
1054@@ -158,11 +194,13 @@
1055 try:
1056 if cmd_line.history[-1] not in ['EOF','quit','exit']:
1057 cmd_line.results.store_result()
1058+except:
1059+ print error
1060+ pass
1061+
1062+
1063+try:
1064 # Remove lock file
1065-except:
1066- pass
1067-
1068-try:
1069 os.remove(os.path.join(root_path,os.pardir, 'RunWeb'))
1070 except:
1071 pass
1072
1073=== added directory 'Template/NLO'
1074=== added file 'Template/NLO/.DS_Store'
1075Binary files Template/NLO/.DS_Store 1970-01-01 00:00:00 +0000 and Template/NLO/.DS_Store 2012-09-28 12:29:27 +0000 differ
1076=== added directory 'Template/NLO/Cards'
1077=== added file 'Template/NLO/Cards/README'
1078--- Template/NLO/Cards/README 1970-01-01 00:00:00 +0000
1079+++ Template/NLO/Cards/README 2012-09-28 12:29:27 +0000
1080@@ -0,0 +1,13 @@
1081+This directory contains samples for all the cards which are used by
1082+MadGraph/MadEvent during the various stages of code operation.
1083+
1084+ Card: proc_card.dat
1085+ Use : This is the process generation card which is used by
1086+ MadGraph to generate the code corresponding the user
1087+ request. It can be used by all user's levels.
1088+ It now supports multi-processes to be requested at the same
1089+ time. In this case the events produced are in the right relative
1090+ ratio also for the different procs. Inclusive samples, like W+jets,
1091+ are produced starting from this option.
1092+
1093+
1094
1095=== added file 'Template/NLO/Cards/grid_card.dat'
1096--- Template/NLO/Cards/grid_card.dat 1970-01-01 00:00:00 +0000
1097+++ Template/NLO/Cards/grid_card.dat 2012-09-28 12:29:27 +0000
1098@@ -0,0 +1,32 @@
1099+#*********************************************************************
1100+# MadGraph/MadEvent *
1101+# http://madgraph.hep.uiuc.edu *
1102+# *
1103+# grid_card.dat *
1104+# *
1105+# This file is used to set the parameters of the run. *
1106+# *
1107+# Some notation/conventions: *
1108+# *
1109+# Lines starting with a '# ' are info or comments *
1110+# *
1111+# mind the format: value = variable ! comment *
1112+#*********************************************************************
1113+#
1114+#*******************
1115+# Running parameters
1116+#*******************
1117+#
1118+#*********************************************************************
1119+# Tell if this is a grid run or not, false during warm-up on the *
1120+# cluster, automatically set to true after warm-up and the gridpack *
1121+# is ready. The user should not change this. *
1122+#*********************************************************************
1123+ .false. = GridRun !True = Runs in the grid mode
1124+#*********************************************************************
1125+# Number of events and rnd seed *
1126+#*********************************************************************
1127+ 2500 = gevents ! Number of unweighted events requested
1128+ 1 = gseed ! rnd seed
1129+ -1 = ngran ! Granularity (minimum # events per channel)
1130+#*********************************************************************
1131
1132=== added file 'Template/NLO/Cards/grid_card_default.dat'
1133--- Template/NLO/Cards/grid_card_default.dat 1970-01-01 00:00:00 +0000
1134+++ Template/NLO/Cards/grid_card_default.dat 2012-09-28 12:29:27 +0000
1135@@ -0,0 +1,32 @@
1136+#*********************************************************************
1137+# MadGraph/MadEvent *
1138+# http://madgraph.hep.uiuc.edu *
1139+# *
1140+# grid_card.dat *
1141+# *
1142+# This file is used to set the parameters of the run. *
1143+# *
1144+# Some notation/conventions: *
1145+# *
1146+# Lines starting with a '# ' are info or comments *
1147+# *
1148+# mind the format: value = variable ! comment *
1149+#*********************************************************************
1150+#
1151+#*******************
1152+# Running parameters
1153+#*******************
1154+#
1155+#*********************************************************************
1156+# Tell if this is a grid run or not, false during warm-up on the *
1157+# cluster, automatically set to true after warm-up and the gridpack *
1158+# is ready. The user should not change this. *
1159+#*********************************************************************
1160+ .false. = GridRun !True = Runs in the grid mode
1161+#*********************************************************************
1162+# Number of events and rnd seed *
1163+#*********************************************************************
1164+ 2500 = gevents ! Number of unweighted events requested
1165+ 1 = gseed ! rnd seed
1166+ -1 = ngran ! Granularity (minimum # events per channel)
1167+#*********************************************************************
1168
1169=== added file 'Template/NLO/Cards/mcatnlo_card.dat'
1170--- Template/NLO/Cards/mcatnlo_card.dat 1970-01-01 00:00:00 +0000
1171+++ Template/NLO/Cards/mcatnlo_card.dat 2012-09-28 12:29:27 +0000
1172@@ -0,0 +1,34 @@
1173+##### HERWIG6
1174+LHSOFT=.FALSE. # Underlying event on (.TRUE.) or off (.FALSE.)
1175+MODBOS_1=5 # Gauge boson decay modes
1176+MODBOS_2=5 # Gauge boson decay modes
1177+B_STABLE_HW=.FALSE. # .TRUE. to let weakly-decaying B hadrons stable
1178+PI_STABLE_HW=.TRUE. # .TRUE. if one wants Pi0 stable
1179+MAXPR_HW=2 # Number of events to be printed out
1180+ERR_FR_HW=0.01 # Tolerated fraction of errors
1181+IS_BB_HW=.FALSE. # .TRUE. if it is b-bbar production
1182+RNDEVSEED1_HW=0 # First random seed (0 for default)
1183+RNDEVSEED2_HW=0 # Second random seed (0 for default)
1184+LAMBDAHERW=-1 # Lambda_5; negative for default
1185+
1186+##### HERWIGPP
1187+UE_HWPP=.FALSE. # Underlying event on (.TRUE.) or off (.FALSE.)
1188+HADRONIZE_HWPP=.TRUE. # Hadronization on (.TRUE.) or off (.FALSE.)
1189+B_STABLE_HWPP=.FALSE. # .TRUE. to let weakly-decaying B hadrons stable
1190+PI_STABLE_HWPP=.TRUE. # .TRUE. if one wants Pi0 stable
1191+MAXPR_HWPP=2 # Number of events to be printed out
1192+ERR_FR_HWPP=0.01 # Tolerated fraction of errors
1193+RNDEVSEED_HWPP=0 # Random seed (if negative it's reset to 0)
1194+
1195+##### PYTHIA6Q
1196+MSTP_81=0 # Underlying event on (1) or off (0)
1197+MSTP_111=1 # Hadronization on (1) or off (0)
1198+W_STABLE_PY=.FALSE. # .TRUE. if one wants W+/- stable
1199+Z_STABLE_PY=.FALSE. # .TRUE. if one wants Z0 stable
1200+B_STABLE_PY=.FALSE. # .TRUE. to let weakly-decaying B hadrons stable
1201+PI_STABLE_PY=.TRUE. # .TRUE. if one wants Pi0 stable
1202+MAXPR_PY=2 # Number of events to be printed out
1203+ERR_FR_PY=0.01 # Tolerated fraction of errors
1204+IS_4L_PY=.FALSE. # .TRUE. if it is four-lepton production
1205+RNDEVSEED_PY=0 # Random seed (0 for default)
1206+LAMBDAPYTH=-1 # Lambda_5; negative for default
1207
1208=== added file 'Template/NLO/Cards/param_card_default.dat'
1209--- Template/NLO/Cards/param_card_default.dat 1970-01-01 00:00:00 +0000
1210+++ Template/NLO/Cards/param_card_default.dat 2012-09-28 12:29:27 +0000
1211@@ -0,0 +1,71 @@
1212+#*********************************************************************
1213+# MadGraph/MadEvent *
1214+# http://madgraph.hep.uiuc.edu *
1215+# *
1216+# param_card.dat *
1217+# *
1218+# Les Houches friendly file for the SM parameters of MadGraph *
1219+# Spectrum and decay widths produced by SMCalc *
1220+# *
1221+# Please note the following IMPORTANT issues: *
1222+# *
1223+# 0. REFRAIN from editing this file by hand! Some of the parame- *
1224+# ters are not independent *
1225+# (such as G_Fermi, alpha_em, sin(theta_W),MZ,MW) and serious *
1226+# problems might be encountered (such as violation of unitarity *
1227+# or gauge invariance). Always use a calculator. *
1228+# *
1229+# 1. alpha_S(MZ) has been used in the calculation of the parameters *
1230+# but, for consistency, it will be reset by madgraph to the *
1231+# value expected IF the pdfs for collisions with hadrons are *
1232+# used. This value is KEPT by madgraph when no pdf are used *
1233+# lpp(i)=0 . *
1234+# *
1235+# 2. Values of the charm and bottom kinematic (pole) masses are *
1236+# those used in the matrix elements and phase space UNLESS they *
1237+# are set to ZERO from the start in the model (particles.dat) *
1238+# This happens, for example, when using 5-flavor QCD where *
1239+# charm and bottom are treated as partons in the initial state *
1240+# and a zero mass might be hardwired in the model definition. *
1241+# *
1242+##********************************************************************
1243+Block MODSEL # Select Model
1244+ 0 1 # 0 1 = SM
1245+Block SMINPUTS # Standard Model inputs
1246+ 1 1.27900000E+02 # alpha_em(MZ)(-1) SM MSbar
1247+ 2 1.16600000E-05 # G_Fermi
1248+ 3 1.18000000E-01 # alpha_s(MZ) SM MSbar
1249+ 4 9.15445065E+01 # Z mass (as input parameter)
1250+Block MGSMPARAM # Standard Model parameters for MadGraph
1251+ 1 2.31200000E-01 # sin(theta_W)^2
1252+ 2 8.02673592E+01 # W mass (as input parameter)
1253+Block MGYUKAWA # Yukawa masses m/v=y/sqrt(2)
1254+# PDG YMASS
1255+ 5 4.20000000E+00 # mbottom for the Yukawa y_b
1256+ 4 1.25000000E+00 # mcharm for the Yukawa y_c
1257+ 6 1.74300000E+02 # mtop for the Yukawa y_t
1258+ 15 1.77700000E+00 # mtau for the Yukawa y_ta
1259+Block MGCKM # CKM elements for MadGraph
1260+ 1 1 9.75000000E-01 # Vud for Cabibbo matrix
1261+Block MASS # Mass spectrum (kinematic masses)
1262+# PDG Mass
1263+ 4 1.40000000E+00 # charm pole mass
1264+ 5 4.20000000E+00 # bottom pole mass
1265+ 6 1.74300000E+02 # top pole mass
1266+ 15 1.77700000E+00 # tau mass
1267+ 23 9.15445065E+01 # Z mass
1268+ 24 8.02673592E+01 # W mass
1269+ 25 1.00000000E+02 # H mass
1270+# PDG Width
1271+DECAY 6 1.51013490E+00 # top width
1272+DECAY 23 2.44639985E+00 # Z width
1273+DECAY 24 2.03535570E+00 # W width
1274+DECAY 25 4.27608700E-03 # H width
1275+# BR NDA ID1 ID2
1276+ 7.18385415E-02 2 4 -4 # BR( H -> c cbar )
1277+ 8.03404251E-01 2 5 -5 # BR( H -> b bbar )
1278+ 0.00000000E+00 2 6 -6 # BR( H -> t tbar )
1279+ 4.83591503E-02 2 15 -15 # BR( H -> tau- tau+)
1280+ 2.69892403E-05 2 23 23 # BR( H -> Z Z^(*))
1281+ 3.67605190E-03 2 24 -24 # BR( H -> W W^(*))
1282+ 2.43358656E-02 2 21 21 # BR( H -> g g )
1283
1284=== added file 'Template/NLO/Cards/plot_card.dat'
1285--- Template/NLO/Cards/plot_card.dat 1970-01-01 00:00:00 +0000
1286+++ Template/NLO/Cards/plot_card.dat 2012-09-28 12:29:27 +0000
1287@@ -0,0 +1,203 @@
1288+#**************************************************************************
1289+# Card for MadAnalysis *
1290+# *
1291+# This file is used to set the classes and options for *
1292+# the MadAnalysis program. *
1293+# *
1294+# *
1295+# Some comments about the classes *
1296+# 1. Plots are for classes of particles. *
1297+# 2. Each particle is identified by its PDG code. *
1298+# 3. Classes names are arbitrary (4 symbols max, no spaces allowed). *
1299+# 4. Particles in the same class will be ordered with the 'ordering *
1300+# function' in the file in_func.f. *
1301+# 5. Classes can be added/edited/removed at will, and given a name *
1302+# that will then appear in the plots. *
1303+# 6. A particle can be put in one class only. Putting a particle in *
1304+# two or more classes can lead to double counting of events. *
1305+# 7. The class name mET is missing Energy and its name is reserved. *
1306+# If used, it must be put last in the classes list below. *
1307+# 8. If events contain particles not belonging to an existing class, *
1308+# a new class will automatically be generated. *
1309+# 9. For LHCO events the PDG code 21 is assigned to a jet (not *
1310+# b-tagged), 5 to a b-tagged jet and 12 to missing ET. *
1311+# *
1312+# *
1313+# Some comments about the cuts *
1314+# 1. In the file kin_func.f the functions on which cuts can be applied *
1315+# are given. *
1316+# 2. The syntax is as follows. *
1317+# etmin 1 3 30d0 *
1318+# means that from the first class the Et of the first three particles *
1319+# has to be greater than 30 GeV. *
1320+# *
1321+# etmissmin 20d0 *
1322+# means that there must be at least 20 GeV of missing Et *
1323+# *
1324+# dRmin 2 1 4 3 3d0 *
1325+# means that the distance between the first particle in the second *
1326+# class and the first three particles in the fourth class has to be *
1327+# greater than 3. *
1328+# *
1329+# ptmax 1 3 10d0 *
1330+# ptmax 1 2 15d0 *
1331+# means that the maximum pt of the third particle in the first class *
1332+# has to smaller than 10 GeV, and the first two particles of this *
1333+# class has to be smaller than 15 GeV *
1334+# 3. The ordering of the particles within a class can be set with the *
1335+# 'ordering function' in the file kin_func.f. *
1336+# 4. For all the 'min' cuts, an event will be thrown away if the particle *
1337+# does not exist. On the other hand, for all the 'max' cuts the cut *
1338+# will be ignored if the particle does not exist *
1339+# (Only dRij is an exception, for which it is the other way around) *
1340+# *
1341+# *
1342+# *
1343+# Some comments about the plotting options *
1344+# 1. In the file kin_func.f the functions can be found that can be *
1345+# plotted. (only for off-line usage) *
1346+# 2. With the plotting options one can set the number of plots for each *
1347+# of these functions. *
1348+# 3. One has to specify for each variable which particles from which *
1349+# class are used to set the plots. Syntax: *
1350+# et 2 4 *
1351+# means that the transverse energy of the first four particles in the *
1352+# second class will be plotted. *
1353+# mij 1 3 *
1354+# mij 2 2 *
1355+# means that for the invariant mass plots the first three particles *
1356+# from the first class and the first two from the second class will be *
1357+# used to plot the invariant mass of two particles. (10 plots) *
1358+# 4. The ordering of the particles in a class can be set with the *
1359+# 'ordering_function'. pt, e and et are valid functions. (For off-line *
1360+# users X1, X2 and X3 can also be used, if defined in kin_func.f.) *
1361+# 5. Max number of plots is 200. *
1362+# *
1363+# *
1364+#**************************************************************************
1365+# Put here your list of classes
1366+#**************************************************************************
1367+# Do NOT put spaces before class names!
1368+# Begin Classes # This is TAG. Do not modify this line
1369+jet 1 -1 2 -2 3 -3 4 -4 21 # Class number 1
1370+b 5 -5 # Class number 2
1371+mET 12 -12 14 -14 16 -16 1000022 # Missing ET class, name is reserved
1372+# End Classes # This is TAG. Do not modify this line
1373+#**************************************************************************
1374+ordering_function pt # orders particles in classes according to their pt
1375+normalization xsec # histogram normalization, xsec or number (e.g. 1)
1376+#**************************************************************************
1377+# Put here list of minimum pt for the classes
1378+#**************************************************************************
1379+# Begin Minpts # This is TAG. Do not modify this line
1380+#1 30
1381+#2 40
1382+#3 10
1383+# End Minpts # This is TAG. Do not modify this line
1384+#**************************************************************************
1385+# Cuts on plotted events
1386+#**************************************************************************
1387+# Modify the cuts and remove the pounds/hashes to apply those cuts
1388+# Do NOT put spaces at the beginning of the following lines!
1389+# Begin Cuts # This is TAG. Do not modify this line
1390+#etmin 2 2 40d0
1391+#etmin 2 1 80d0
1392+#etmin 1 3 20d0
1393+#etmax 2 1 200d0
1394+#ptmin 3 1 0d0
1395+#etmissmin 20d0
1396+#etmissmax 80d0
1397+#etamax 1 1 1d0
1398+#etamax 2 1 2d0
1399+#etamin 2 2 1.5d0
1400+#etamin 2 1 2d0
1401+#mijmax 2 1 2 2 200d0
1402+#mijmin 2 1 2 2 100d0
1403+#X1min 2 1 40d0
1404+#X1max 2 2 50d0
1405+#dRijmin 2 1 2 2 0.7d0
1406+#dRijmax 1 3 2 2 0.7d0
1407+#XY1min 2 2 2 2 20d0
1408+#XYZA2max 2 2 2 2 4 1 5 1 40d0
1409+# End Cuts # This is TAG. Do not modify this line
1410+#**************************************************************************
1411+# Put here the required plots
1412+#**************************************************************************
1413+# Do NOT put spaces at the beginning of the following lines!
1414+# Begin PlotDefs # This is TAG. Do not modify this line
1415+pt 1 4 # plot pt for the first four particles in class 1
1416+pt 2 4 # plot pt for the first four particles in class 2
1417+pt 3 4 # plot pt for the first four particles in class 3
1418+pt 4 4 # plot pt for the first four particles in class 4
1419+pt 5 4 # etc.
1420+pt 6 4
1421+pt 7 4
1422+#e 2 2
1423+y 1 4 # plot rapidity for the first four particles in class 1
1424+y 2 4
1425+y 3 4
1426+y 4 4
1427+y 5 4
1428+y 6 4
1429+y 7 4
1430+#eta 2 2 # plot pseudo-rapidity for the first two part in the 2nd class
1431+#mom 4 1
1432+#costh 5 1
1433+#phi 2 2
1434+#delta_eta 2 2
1435+#delta_eta 4 1
1436+mij 1 4 # use the first four particles in the 1st class to plot inv. mass
1437+mij 2 2 # use the first two particles from the second class as well
1438+mij 3 1 # etc.
1439+mij 4 1
1440+mij 5 1
1441+mij 6 1
1442+mij 7 1
1443+#cosij 1 2
1444+#cosij 2 2
1445+#cosij 3 1
1446+#cosij 4 1
1447+dRij 1 4
1448+dRij 2 2
1449+dRij 3 1
1450+dRij 4 1
1451+dRij 5 1
1452+dRij 6 1
1453+dRij 7 1
1454+#delta_phi 2 2
1455+#delta_phi 4 1
1456+#delta_phi 5 1
1457+#X1 2 2 # plot X1 (defined in kin_func.f)
1458+#XYZA1 2 2
1459+#XYZA1 4 1
1460+#XYZA1 5 1
1461+# End PlotDefs # This is TAG. Do not modify this line
1462+#**************************************************************************
1463+#**************************************************************************
1464+# Put here the plot ranges
1465+#**************************************************************************
1466+# Do NOT put spaces at the beginning of the following lines!
1467+# Begin PlotRange # This is TAG. Do not modify this line
1468+pt 10 0 500 # bin size, min value, max value
1469+et 10 0 500 # bin size, min value, max value
1470+etmiss 10 0 500 # bin size, min value, max value
1471+ht 20 0 1500
1472+y 0.2 -5 5 # etc.
1473+mij 20 0 1500
1474+dRij 0.1 0 5
1475+#delta_phi 0.1 0 3.1
1476+#X1 1 0 100
1477+#XYZA1 1 0 100
1478+# End PlotRange # This is TAG. Do not modify this line
1479+#**************************************************************************
1480+#**************************************************************************
1481+# Output for plots
1482+#**************************************************************************
1483+# Do NOT put spaces at the beginning of the following lines!
1484+# Begin PlotOutput # This is TAG. Do not modify this line
1485+output topdrawer # set to topdrawer or gnuplot
1486+plot_decayed no # plot (and cut) dec. res.? (Only for LHE events)
1487+# End PlotOutput # This is TAG. Do not modify this line
1488+#**************************************************************************
1489+#
1490+#
1491
1492=== added file 'Template/NLO/Cards/plot_card_default.dat'
1493--- Template/NLO/Cards/plot_card_default.dat 1970-01-01 00:00:00 +0000
1494+++ Template/NLO/Cards/plot_card_default.dat 2012-09-28 12:29:27 +0000
1495@@ -0,0 +1,192 @@
1496+#**************************************************************************
1497+# Card for MadAnalysis *
1498+# *
1499+# This file is used to set the classes and options for *
1500+# the MadAnalysis program. *
1501+# *
1502+# *
1503+# Some comments about the classes *
1504+# 1. Plots are for classes of particles. *
1505+# 2. Each particle is identified by its PDG code. *
1506+# 3. Classes names are arbitrary (4 symbols max, no spaces allowed). *
1507+# 4. Particles in the same class will be ordered with the 'ordering *
1508+# function' in the file in_func.f. *
1509+# 5. Classes can be added/edited/removed at will, and given a name *
1510+# that will then appear in the plots. *
1511+# 6. A particle can be put in one class only. Putting a particle in *
1512+# two or more classes can lead to double counting of events. *
1513+# 7. The class name mET is missing Energy and its name is reserved. *
1514+# If used, it must be put last in the classes list below. *
1515+# 8. If events contain particles not belonging to an existing class, *
1516+# a new class will automatically be generated. *
1517+# 9. For LHCO events the PDG code 21 is assigned to a jet (not *
1518+# b-tagged), 5 to a b-tagged jet and 12 to missing ET. *
1519+# *
1520+# *
1521+# Some comments about the cuts *
1522+# 1. In the file kin_func.f the functions on which cuts can be applied *
1523+# are given. *
1524+# 2. The syntax is as follows. *
1525+# etmin 1 3 30d0 *
1526+# means that from the first class the Et of the first three particles *
1527+# has to be greater than 30 GeV. *
1528+# *
1529+# etmissmin 20d0 *
1530+# means that there must be at least 20 GeV of missing Et *
1531+# *
1532+# dRmin 2 1 4 3 3d0 *
1533+# means that the distance between the first particle in the second *
1534+# class and the first three particles in the fourth class has to be *
1535+# greater than 3. *
1536+# *
1537+# ptmax 1 3 10d0 *
1538+# ptmax 1 2 15d0 *
1539+# means that the maximum pt of the third particle in the first class *
1540+# has to smaller than 10 GeV, and the first two particles of this *
1541+# class has to be smaller than 15 GeV *
1542+# 3. The ordering of the particles within a class can be set with the *
1543+# 'ordering function' in the file kin_func.f. *
1544+# 4. For all the 'min' cuts, an event will be thrown away if the particle *
1545+# does not exist. On the other hand, for all the 'max' cuts the cut *
1546+# will be ignored if the particle does not exist *
1547+# (Only dRij is an exception, for which it is the other way around) *
1548+# *
1549+# *
1550+# *
1551+# Some comments about the plotting options *
1552+# 1. In the file kin_func.f the functions can be found that can be *
1553+# plotted. (only for off-line usage) *
1554+# 2. With the plotting options one can set the number of plots for each *
1555+# of these functions. *
1556+# 3. One has to specify for each variable which particles from which *
1557+# class are used to set the plots. Syntax: *
1558+# et 2 4 *
1559+# means that the transverse energy of the first four particles in the *
1560+# second class will be plotted. *
1561+# mij 1 3 *
1562+# mij 2 2 *
1563+# means that for the invariant mass plots the first three particles *
1564+# from the first class and the first two from the second class will be *
1565+# used to plot the invariant mass of two particles. (10 plots) *
1566+# 4. The ordering of the particles in a class can be set with the *
1567+# 'ordering_function'. pt, e and et are valid functions. (For off-line *
1568+# users X1, X2 and X3 can also be used, if defined in kin_func.f.) *
1569+# 5. Max number of plots is 200. *
1570+# *
1571+# *
1572+#**************************************************************************
1573+# Put here your list of classes
1574+#**************************************************************************
1575+# Do NOT put spaces before class names!
1576+# Begin Classes # This is TAG. Do not modify this line
1577+jet 1 -1 2 -2 3 -3 4 -4 21 # Class number 1
1578+b 5 -5 # Class number 2
1579+mET 12 -12 14 -14 16 -16 # Missing ET class, name is reserved
1580+# End Classes # This is TAG. Do not modify this line
1581+#**************************************************************************
1582+ordering_function pt # orders particles in classes according to their pt
1583+#**************************************************************************
1584+# Cuts on plotted events
1585+#**************************************************************************
1586+# Modify the cuts and remove the pounds/hashes to apply those cuts
1587+# Do NOT put spaces at the beginning of the following lines!
1588+# Begin Cuts # This is TAG. Do not modify this line
1589+#etmin 2 2 40d0
1590+#etmin 2 1 80d0
1591+#etmin 1 3 20d0
1592+#etmax 2 1 200d0
1593+#ptmin 3 1 0d0
1594+#etmissmin 20d0
1595+#etmissmax 80d0
1596+#etamax 1 1 1d0
1597+#etamax 2 1 2d0
1598+#etamin 2 2 1.5d0
1599+#etamin 2 1 2d0
1600+#mijmax 2 1 2 2 200d0
1601+#mijmin 2 1 2 2 100d0
1602+#X1min 2 1 40d0
1603+#X1max 2 2 50d0
1604+#dRijmin 2 1 2 2 0.7d0
1605+#dRijmax 1 3 2 2 0.7d0
1606+#XY1min 2 2 2 2 20d0
1607+#XYZA2max 2 2 2 2 4 1 5 1 40d0
1608+# End Cuts # This is TAG. Do not modify this line
1609+#**************************************************************************
1610+# Put here the required plots
1611+#**************************************************************************
1612+# Do NOT put spaces at the beginning of the following lines!
1613+# Begin PlotDefs # This is TAG. Do not modify this line
1614+pt 1 4 # plot pt for the first four particles in class 1
1615+pt 2 4 # plot pt for the first four particles in class 2
1616+pt 3 4 # plot pt for the first four particles in class 3
1617+pt 4 4 # plot pt for the first four particles in class 4
1618+pt 5 4 # etc.
1619+pt 6 4
1620+pt 7 4
1621+#e 2 2
1622+y 1 4 # plot rapidity for the first four particles in class 1
1623+y 2 4
1624+y 3 4
1625+y 4 4
1626+y 5 4
1627+y 6 4
1628+y 7 4
1629+#eta 2 2 # plot pseudo-rapidity for the first two part in the 2nd class
1630+#mom 4 1
1631+#costh 5 1
1632+#phi 2 2
1633+#delta_eta 2 2
1634+#delta_eta 4 1
1635+mij 1 4 # use the first four particles in the 1st class to plot inv. mass
1636+mij 2 2 # use the first two particles from the second class as well
1637+mij 3 1 # etc.
1638+mij 4 1
1639+mij 5 1
1640+mij 6 1
1641+mij 7 1
1642+cosij 1 2
1643+cosij 2 2
1644+cosij 3 1
1645+cosij 4 1
1646+dRij 1 4
1647+dRij 2 2
1648+dRij 3 1
1649+dRij 4 1
1650+dRij 5 1
1651+dRij 6 1
1652+dRij 7 1
1653+#delta_phi 2 2
1654+#delta_phi 4 1
1655+#delta_phi 5 1
1656+#X1 2 2 # plot X1 (defined in kin_func.f)
1657+#XYZA1 2 2
1658+#XYZA1 4 1
1659+#XYZA1 5 1
1660+# End PlotDefs # This is TAG. Do not modify this line
1661+#**************************************************************************
1662+#**************************************************************************
1663+# Put here the plot ranges
1664+#**************************************************************************
1665+# Do NOT put spaces at the beginning of the following lines!
1666+# Begin PlotRange # This is TAG. Do not modify this line
1667+pt 4 0 200 # bin size, min value, max value
1668+et 4 0 200 # bin size, min value, max value
1669+y 0.2 -5 5 # etc.
1670+mij 10 0 500
1671+dRij 0.1 0 5
1672+#delta_phi 0.1 0 3.1
1673+#X1 1 0 100
1674+#XYZA1 1 0 100
1675+# End PlotRange # This is TAG. Do not modify this line
1676+#**************************************************************************
1677+#**************************************************************************
1678+# Output for plots
1679+#**************************************************************************
1680+# Do NOT put spaces at the beginning of the following lines!
1681+# Begin PlotOutput # This is TAG. Do not modify this line
1682+output topdrawer # set to topdrawer or gnuplot
1683+plot_decayed no # plot (and cut) dec. res.? (Only for LHE events)
1684+# End PlotOutput # This is TAG. Do not modify this line
1685+#**************************************************************************
1686+#
1687+#
1688
1689=== added file 'Template/NLO/Cards/pythia_card_default.dat'
1690--- Template/NLO/Cards/pythia_card_default.dat 1970-01-01 00:00:00 +0000
1691+++ Template/NLO/Cards/pythia_card_default.dat 2012-09-28 12:29:27 +0000
1692@@ -0,0 +1,12 @@
1693+!...Parton showering on or off
1694+ MSTP(61)=1
1695+ MSTP(71)=1
1696+
1697+!...Fragmentation/hadronization on or off
1698+ MSTJ(1)=1
1699+
1700+!...Multiple interactions on or off
1701+ MSTP(81)=20
1702+
1703+!...Don't stop execution after 10 errors
1704+ MSTU(21)=1
1705
1706=== added file 'Template/NLO/Cards/replace_card1.dat'
1707--- Template/NLO/Cards/replace_card1.dat 1970-01-01 00:00:00 +0000
1708+++ Template/NLO/Cards/replace_card1.dat 2012-09-28 12:29:27 +0000
1709@@ -0,0 +1,4 @@
1710+# Enter here any particles you want replaced in the event file after ME run
1711+# In the syntax PID : PID1 PID2 PID3 ...
1712+# End with "done" or <newline>
1713+
1714
1715=== added file 'Template/NLO/Cards/run_card.dat'
1716--- Template/NLO/Cards/run_card.dat 1970-01-01 00:00:00 +0000
1717+++ Template/NLO/Cards/run_card.dat 2012-09-28 12:29:27 +0000
1718@@ -0,0 +1,103 @@
1719+#*********************************************************************
1720+# MadGraph/MadEvent *
1721+# http://madgraph.hep.uiuc.edu *
1722+# *
1723+# run_card.dat *
1724+# *
1725+# This file is used to set the parameters of the run. *
1726+# *
1727+# Some notation/conventions: *
1728+# *
1729+# Lines starting with a '# ' are info or comments *
1730+# *
1731+# mind the format: value = variable ! comment *
1732+#*********************************************************************
1733+#
1734+#*******************
1735+# Running parameters
1736+#*******************
1737+#
1738+#*********************************************************************
1739+# Number of events *
1740+#*********************************************************************
1741+ 10000 = nevents ! Number of unweighted events requested
1742+ 0 = iseed ! rnd seed (0=assigned automatically=default))
1743+#*********************************************************************
1744+# Collider type and energy *
1745+#*********************************************************************
1746+ 1 = lpp1 ! beam 1 type (0 = no PDF)
1747+ 1 = lpp2 ! beam 2 type (0 = no PDF)
1748+ 4000 = ebeam1 ! beam 1 energy in GeV
1749+ 4000 = ebeam2 ! beam 2 energy in GeV
1750+#*********************************************************************
1751+# PDF choice: this automatically fixes also alpha_s(MZ) and its evol.*
1752+#*********************************************************************
1753+ 'cteq6_m' = pdlabel ! PDF set
1754+ 10042 = lhaid
1755+#*********************************************************************
1756+# Include the NLO Monte Carlo subtr. terms for the following parton *
1757+# shower (HERWIG6 | HERWIGPP | PYTHIA6Q ) *
1758+#*********************************************************************
1759+ HERWIG6 = parton_shower
1760+#*********************************************************************
1761+# Renormalization and factorization scales *
1762+# (Default functional form for the non-fixed scales is the sum of *
1763+# the transverse masses of all final state particles & partons. This *
1764+# can be changed in SubProcesses/set_scales.f) *
1765+#*********************************************************************
1766+ F = fixed_ren_scale ! if .true. use fixed ren scale
1767+ F = fixed_fac_scale ! if .true. use fixed fac scale
1768+ 91.188 = muR_ref_fixed ! fixed ren reference scale
1769+ 91.188 = muF1_ref_fixed ! fixed fact reference scale for pdf1
1770+ 91.188 = muF2_ref_fixed ! fixed fact reference scale for pdf2
1771+#*********************************************************************
1772+# Renormalization and factorization scales (advanced and NLO options)*
1773+#*********************************************************************
1774+ F = fixed_QES_scale ! if .true. use fixed Ellis-Sexton scale
1775+ 91.188 = QES_ref_fixed ! fixed Ellis-Sexton reference scale
1776+ 1 = muR_over_ref ! ratio of current muR over reference muR
1777+ 1 = muF1_over_ref ! ratio of current muF1 over reference muF1
1778+ 1 = muF2_over_ref ! ratio of current muF2 over reference muF2
1779+ 1 = QES_over_ref ! ratio of current QES over reference QES
1780+#*********************************************************************
1781+# Reweight flags to get scale dependence and PDF uncertainty *
1782+# For scale dependence: factor rw_scale_up/down around central scale *
1783+# For PDF uncertainty: use LHAPDF with supported set *
1784+#*********************************************************************
1785+ .true. = reweight_scale ! reweight to get scale dependence
1786+ 0.5 = rw_Rscale_down ! lower bound for ren scale variations
1787+ 2.0 = rw_Rscale_up ! upper bound for ren scale variations
1788+ 0.5 = rw_Fscale_down ! lower bound for fact scale variations
1789+ 2.0 = rw_Fscale_up ! upper bound for fact scale variations
1790+ .false. = reweight_PDF ! reweight to get PDF uncertainty
1791+ 21101 = PDF_set_min ! First of the error PDF sets
1792+ 21140 = PDF_set_max ! Last of the error PDF sets
1793+#*********************************************************************
1794+#
1795+#*********************************************************************
1796+# BW cutoff (M+/-bwcutoff*Gamma) *
1797+#*********************************************************************
1798+ 15 = bwcutoff
1799+#*********************************************************************
1800+# Cuts on the jets *
1801+# When matching to a parton shower, these generation cuts should be *
1802+# considerably softer than the analysis cuts. *
1803+# (more specific cuts can be specified in SubProcesses/cuts.f) *
1804+#*********************************************************************
1805+ 1 = jetalgo ! FastJet jet algorithm (1=kT, 0=C/A, -1=anti-kT)
1806+ 0.7 = jetradius ! The radius parameter for the jet algorithm
1807+ 10 = ptj ! Minimal jet transverse momentum
1808+ -1 = etaj ! Maximal jet pseudo-rapidity (absolute value)
1809+#*********************************************************************
1810+# Cuts on the charged leptons (e+, e-, mu+, mu-, tau+ and tau-) *
1811+# (more specific gen cuts can be specified in SubProcesses/cuts.f) *
1812+#*********************************************************************
1813+ 0 = ptl ! Min lepton transverse momentum
1814+ -1 = etal ! Max lepton pseudo rapidity
1815+ 0 = drll ! Min distance between opposite sign lepton pairs
1816+ 30 = mll ! Min inv. mass of all oppositely charged lepton pairs
1817+#*********************************************************************
1818+# maximal pdg code for quark to be considered as a jet *
1819+#*********************************************************************
1820+ 5 = maxjetflavor
1821+#*********************************************************************
1822
1823=== added file 'Template/NLO/Cards/run_card_default.dat'
1824--- Template/NLO/Cards/run_card_default.dat 1970-01-01 00:00:00 +0000
1825+++ Template/NLO/Cards/run_card_default.dat 2012-09-28 12:29:27 +0000
1826@@ -0,0 +1,198 @@
1827+#*********************************************************************
1828+# MadGraph/MadEvent *
1829+# http://madgraph.hep.uiuc.edu *
1830+# *
1831+# run_card.dat *
1832+# *
1833+# This file is used to set the parameters of the run. *
1834+# *
1835+# Some notation/conventions: *
1836+# *
1837+# Lines starting with a '# ' are info or comments *
1838+# *
1839+# mind the format: value = variable ! comment *
1840+#*********************************************************************
1841+#
1842+#*******************
1843+# Running parameters
1844+#*******************
1845+#
1846+#*********************************************************************
1847+# Tag name for the run (one word) *
1848+#*********************************************************************
1849+ 'fermi' = run_tag ! name of the run
1850+#*********************************************************************
1851+# Run to generate the grid pack *
1852+#*********************************************************************
1853+ .false. = gridpack !True = setting up the grid pack
1854+#*********************************************************************
1855+# Number of events and rnd seed *
1856+#*********************************************************************
1857+ 10000 = nevents ! Number of unweighted events requested
1858+ 0 = iseed ! rnd seed (0=assigned automatically=default))
1859+#*********************************************************************
1860+# Collider type and energy *
1861+#*********************************************************************
1862+ 1 = lpp1 ! beam 1 type (0=NO PDF)
1863+ 1 = lpp2 ! beam 2 type (0=NO PDF)
1864+ 7000 = ebeam1 ! beam 1 energy in GeV
1865+ 7000 = ebeam2 ! beam 2 energy in GeV
1866+#*********************************************************************
1867+# Beam polarization from -100 (left-handed) to 100 (right-handed) *
1868+#*********************************************************************
1869+ 0 = polbeam1 ! beam polarization for beam 1
1870+ 0 = polbeam2 ! beam polarization for beam 2
1871+#*********************************************************************
1872+# PDF CHOICE: this automatically fixes also alpha_s and its evol. *
1873+#*********************************************************************
1874+ 'cteq6l1' = pdlabel ! PDF set
1875+#*********************************************************************
1876+# Renormalization and factorization scales *
1877+#*********************************************************************
1878+ F = fixed_ren_scale ! if .true. use fixed ren scale
1879+ F = fixed_fac_scale ! if .true. use fixed fac scale
1880+ 91.1880 = scale ! fixed ren scale
1881+ 91.1880 = dsqrt_q2fact1 ! fixed fact scale for pdf1
1882+ 91.1880 = dsqrt_q2fact2 ! fixed fact scale for pdf2
1883+ 1 = scalefact ! scale factor for event-by-event scales
1884+#*********************************************************************
1885+# Matching - Warning! ickkw > 1 is still beta
1886+#*********************************************************************
1887+ 0 = ickkw ! 0 no matching, 1 MLM, 2 CKKW matching
1888+ 1 = highestmult ! for ickkw=2, highest mult group
1889+ 1 = ktscheme ! for ickkw=1, 1 Durham kT, 2 Pythia pTE
1890+ 1 = alpsfact ! scale factor for QCD emission vx
1891+ F = chcluster ! cluster only according to channel diag
1892+ F = pdfwgt ! for ickkw=1, perform pdf reweighting
1893+#*********************************************************************
1894+#
1895+#**********************************
1896+# BW cutoff (M+/-bwcutoff*Gamma)
1897+#**********************************
1898+ 15 = bwcutoff
1899+#*******************
1900+# Standard Cuts
1901+#*******************
1902+#
1903+#*********************************************************************
1904+# Minimum and maximum pt's *
1905+#*********************************************************************
1906+ 20 = ptj ! minimum pt for the jets
1907+ 0 = ptb ! minimum pt for the b
1908+ 10 = pta ! minimum pt for the photons
1909+ 10 = ptl ! minimum pt for the charged leptons
1910+ 0 = misset ! minimum missing Et (sum of neutrino's momenta)
1911+ 0 = ptheavy ! minimum pt for one heavy final state
1912+ 1.0 = ptonium ! minimum pt for the quarkonium states
1913+ 1d5 = ptjmax ! maximum pt for the jets
1914+ 1d5 = ptbmax ! maximum pt for the b
1915+ 1d5 = ptamax ! maximum pt for the photons
1916+ 1d5 = ptlmax ! maximum pt for the charged leptons
1917+ 1d5 = missetmax ! maximum missing Et (sum of neutrino's momenta)
1918+#*********************************************************************
1919+# Minimum and maximum E's (in the lab frame) *
1920+#*********************************************************************
1921+ 0 = ej ! minimum E for the jets
1922+ 0 = eb ! minimum E for the b
1923+ 0 = ea ! minimum E for the photons
1924+ 0 = el ! minimum E for the charged leptons
1925+ 1d5 = ejmax ! maximum E for the jets
1926+ 1d5 = ebmax ! maximum E for the b
1927+ 1d5 = eamax ! maximum E for the photons
1928+ 1d5 = elmax ! maximum E for the charged leptons
1929+#*********************************************************************
1930+# Maximum and minimum rapidity *
1931+#*********************************************************************
1932+ 5 = etaj ! max rap for the jets
1933+ 1d2 = etab ! max rap for the b
1934+ 2.5 = etaa ! max rap for the photons
1935+ 2.5 = etal ! max rap for the charged leptons
1936+ 0.6 = etaonium ! max rap for the quarkonium states
1937+ 0d0 = etajmin ! min rap for the jets
1938+ 0d0 = etabmin ! min rap for the b
1939+ 0d0 = etaamin ! min rap for the photons
1940+ 0d0 = etalmin ! main rap for the charged leptons
1941+#*********************************************************************
1942+# Minimum and maximum DeltaR distance *
1943+#*********************************************************************
1944+ 0.4 = drjj ! min distance between jets
1945+ 0 = drbb ! min distance between b's
1946+ 0.4 = drll ! min distance between leptons
1947+ 0.4 = draa ! min distance between gammas
1948+ 0 = drbj ! min distance between b and jet
1949+ 0.4 = draj ! min distance between gamma and jet
1950+ 0.4 = drjl ! min distance between jet and lepton
1951+ 0 = drab ! min distance between gamma and b
1952+ 0 = drbl ! min distance between b and lepton
1953+ 0.4 = dral ! min distance between gamma and lepton
1954+ 1d2 = drjjmax ! max distance between jets
1955+ 1d2 = drbbmax ! max distance between b's
1956+ 1d2 = drllmax ! max distance between leptons
1957+ 1d2 = draamax ! max distance between gammas
1958+ 1d2 = drbjmax ! max distance between b and jet
1959+ 1d2 = drajmax ! max distance between gamma and jet
1960+ 1d2 = drjlmax ! max distance between jet and lepton
1961+ 1d2 = drabmax ! max distance between gamma and b
1962+ 1d2 = drblmax ! max distance between b and lepton
1963+ 1d2 = dralmax ! maxdistance between gamma and lepton
1964+#*********************************************************************
1965+# Minimum and maximum invariant mass for pairs *
1966+#*********************************************************************
1967+ 0 = mmjj ! min invariant mass of a jet pair
1968+ 0 = mmbb ! min invariant mass of a b pair
1969+ 0 = mmaa ! min invariant mass of gamma gamma pair
1970+ 0 = mmll ! min invariant mass of l+l- (same flavour) lepton pair
1971+ 1d5 = mmjjmax ! max invariant mass of a jet pair
1972+ 1d5 = mmbbmax ! max invariant mass of a b pair
1973+ 1d5 = mmaamax ! max invariant mass of gamma gamma pair
1974+ 1d5 = mmllmax ! max invariant mass of l+l- (same flavour) lepton pair
1975+#*********************************************************************
1976+# Minimum and maximum invariant mass for all letpons *
1977+#*********************************************************************
1978+ 0 = mmnl ! min invariant mass for all letpons (l+- and vl)
1979+ 1d5 = mmnlmax ! max invariant mass for all letpons (l+- and vl)
1980+#*********************************************************************
1981+# Inclusive cuts *
1982+#*********************************************************************
1983+ 0 = xptj ! minimum pt for at least one jet
1984+ 0 = xptb ! minimum pt for at least one b
1985+ 0 = xpta ! minimum pt for at least one photon
1986+ 0 = xptl ! minimum pt for at least one charged lepton
1987+#*********************************************************************
1988+# Control the pt's of the jets sorted by pt *
1989+#*********************************************************************
1990+ 0 = ptj1min ! minimum pt for the leading jet in pt
1991+ 0 = ptj2min ! minimum pt for the second jet in pt
1992+ 0 = ptj3min ! minimum pt for the third jet in pt
1993+ 0 = ptj4min ! minimum pt for the fourth jet in pt
1994+ 1d5 = ptj1max ! maximum pt for the leading jet in pt
1995+ 1d5 = ptj2max ! maximum pt for the second jet in pt
1996+ 1d5 = ptj3max ! maximum pt for the third jet in pt
1997+ 1d5 = ptj4max ! maximum pt for the fourth jet in pt
1998+ 0 = cutuse ! reject event if fails any (0) / all (1) jet pt cuts
1999+#*********************************************************************
2000+# Control the Ht(k)=Sum of k leading jets *
2001+#*********************************************************************
2002+ 0 = htjmin ! minimum jet HT=Sum(jet pt)
2003+ 1d5 = htjmax ! maximum jet HT=Sum(jet pt)
2004+ 0 = ht2min ! minimum Ht for the two leading jets
2005+ 0 = ht3min ! minimum Ht for the three leading jets
2006+ 0 = ht4min ! minimum Ht for the four leading jets
2007+ 1d5 = ht2max ! maximum Ht for the two leading jets
2008+ 1d5 = ht3max ! maximum Ht for the three leading jets
2009+ 1d5 = ht4max ! maximum Ht for the four leading jets
2010+#*********************************************************************
2011+# WBF cuts *
2012+#*********************************************************************
2013+ 0 = xetamin ! minimum rapidity for two jets in the WBF case
2014+ 0 = deltaeta ! minimum rapidity for two jets in the WBF case
2015+#*********************************************************************
2016+# maximal pdg code for quark to be considered as a jet *
2017+# otherwise b cuts are applied *
2018+#*********************************************************************
2019+ 4 = maxjetflavor
2020+#*********************************************************************
2021+# Jet measure cuts *
2022+#*********************************************************************
2023+ 0 = xqcut ! minimum kt jet measure between partons
2024+#*********************************************************************
2025
2026=== added directory 'Template/NLO/Events'
2027=== added file 'Template/NLO/Events/banner_header.txt'
2028--- Template/NLO/Events/banner_header.txt 1970-01-01 00:00:00 +0000
2029+++ Template/NLO/Events/banner_header.txt 2012-09-28 12:29:27 +0000
2030@@ -0,0 +1,31 @@
2031+<LesHouchesEvents version="1.0">
2032+<header>
2033+<!--
2034+#*********************************************************************
2035+# *
2036+# MadGraph/MadEvent *
2037+# *
2038+# The new web generation *
2039+# *
2040+# http://madgraph.hep.uiuc.edu *
2041+# http://madgraph.phys.ucl.ac.be *
2042+# http://madgraph.roma2.infn.it *
2043+# *
2044+# CP3 team Tim Stelzer *
2045+# Universite de Louvain University of Illinois *
2046+# *
2047+#....................................................................*
2048+# *
2049+# This file contains all the information necessary to reproduce *
2050+# the events generated: *
2051+# *
2052+# 1. software version *
2053+# 2. proc_card.dat : code generation info including model *
2054+# 3. param_card.dat : model primary parameters in the LH format *
2055+# 4. run_card.dat : running parameters (collider and cuts) *
2056+# 5. pythia_card.dat : present only in the pythia event file *
2057+# 6. pgs_card.dat : present only in the pgs event file *
2058+# *
2059+# *
2060+#*********************************************************************
2061+-->
2062
2063=== added directory 'Template/NLO/HTML'
2064=== added file 'Template/NLO/HTML/card.jpg'
2065Binary files Template/NLO/HTML/card.jpg 1970-01-01 00:00:00 +0000 and Template/NLO/HTML/card.jpg 2012-09-28 12:29:27 +0000 differ
2066=== added file 'Template/NLO/HTML/crossx.html'
2067=== added file 'Template/NLO/HTML/info-default.html'
2068--- Template/NLO/HTML/info-default.html 1970-01-01 00:00:00 +0000
2069+++ Template/NLO/HTML/info-default.html 2012-09-28 12:29:27 +0000
2070@@ -0,0 +1,13 @@
2071+<HTML>
2072+<HEAD>
2073+<TITLE>Info file</TITLE>
2074+<META HTTP-EQUIV="EXPIRES" CONTENT="20" ></HEAD>
2075+<BODY>
2076+<P> <H2 ALIGN=CENTER> SubProcesses and Feynman diagrams </H2>
2077+<P> <H4 ALIGN=CENTER> Information not available yet: </H4>
2078+<P> <H4 ALIGN=CENTER> Process might still be generated or has failed.</H4>
2079+<P> <H4 ALIGN=CENTER> Please check the <a href="../proc_log.txt">process generation log</a> and the process information status on the
2080+<a href="../index.html">main page</a>.</H4>
2081+<P> <H4 ALIGN=CENTER> If generation failed, please check the <a href="../Cards/proc_card.dat">process card</a> for mistakes in syntax.</H4>
2082+<H4 align=center> <A HREF="card.html"> Main Page </A> </h4>
2083+</HTML>
2084
2085=== added file 'Template/NLO/HTML/mgstyle.css'
2086--- Template/NLO/HTML/mgstyle.css 1970-01-01 00:00:00 +0000
2087+++ Template/NLO/HTML/mgstyle.css 2012-09-28 12:29:27 +0000
2088@@ -0,0 +1,34 @@
2089+th a:link{
2090+ color:black;
2091+}
2092+
2093+table {
2094+ border-width: 1px;
2095+ border-spacing: 0px;
2096+ border-style: outset;
2097+ border-color: black;
2098+ border-collapse: collapse;
2099+ background-color: white;
2100+}
2101+table th {
2102+ border-width: 2px;
2103+ padding: 1px;
2104+ border-style: solid;
2105+ border-color: black;
2106+ background-color: white;
2107+}
2108+
2109+table td {
2110+ border-width: 2px;
2111+ padding: 1px;
2112+ border-style: solid;
2113+ border-color: black;
2114+}
2115+
2116+input {
2117+ display: inline;
2118+}
2119+
2120+form {
2121+ display: inline;
2122+}
2123
2124=== added file 'Template/NLO/HTML/sortable.js'
2125--- Template/NLO/HTML/sortable.js 1970-01-01 00:00:00 +0000
2126+++ Template/NLO/HTML/sortable.js 2012-09-28 12:29:27 +0000
2127@@ -0,0 +1,335 @@
2128+/*
2129+Table sorting script by Joost de Valk, check it out at http://www.joostdevalk.nl/code/sortable-table/.
2130+Based on a script from http://www.kryogenix.org/code/browser/sorttable/.
2131+Distributed under the MIT license: http://www.kryogenix.org/code/browser/licence.html .
2132+Modify by the MG team for compatibility issue
2133+
2134+Copyright (c) 1997-2007 Stuart Langridge, Joost de Valk.
2135+
2136+Version 1.5.7
2137+*/
2138+
2139+/* You can change these values */
2140+var europeandate = true;
2141+var alternate_row_colors = true;
2142+
2143+/* Don't change anything below this unless you know what you're doing */
2144+addEvent(window, "load", sortables_init);
2145+
2146+var SORT_COLUMN_INDEX;
2147+var thead = false;
2148+
2149+function sortables_init() {
2150+ // Find all tables with class sortable and make them sortable
2151+ if (!document.getElementsByTagName) return;
2152+ tbls = document.getElementsByTagName("table");
2153+ for (ti=0;ti<tbls.length;ti++) {
2154+ thisTbl = tbls[ti];
2155+ if (((' '+thisTbl.className+' ').indexOf("sortable") != -1) && (thisTbl.id)) {
2156+ ts_makeSortable(thisTbl);
2157+ // make it sortable according to the second column
2158+ if (thisTbl.tHead && thisTbl.tHead.rows.length > 0) {
2159+ var firstRow = thisTbl.tHead.rows[thisTbl.tHead.rows.length-1];
2160+ } else {
2161+ var firstRow = thisTbl.rows[0];
2162+ }
2163+
2164+ for (var ci=0;ci<firstRow.cells[1].childNodes.length;ci++) {
2165+ if (firstRow.cells[1].childNodes[ci].tagName && firstRow.cells[1].childNodes[ci].tagName.toLowerCase() == 'a') var lnk = firstRow.cells[1].childNodes[ci];
2166+ }
2167+ ts_resortTable(lnk, 1); //order by cross-section
2168+ ts_resortTable(lnk, 1); //order by cross-section
2169+ }
2170+ }
2171+}
2172+
2173+function ts_makeSortable(t) {
2174+ if (t.rows && t.rows.length > 0) {
2175+ if (t.tHead && t.tHead.rows.length > 0) {
2176+ var firstRow = t.tHead.rows[t.tHead.rows.length-1];
2177+ thead = true;
2178+ } else {
2179+ var firstRow = t.rows[0];
2180+ }
2181+ }
2182+ if (!firstRow) return;
2183+
2184+ // We have a first row: assume it's the header, and make its contents clickable links
2185+ for (var i=0;i<firstRow.cells.length;i++) {
2186+ var cell = firstRow.cells[i];
2187+ var txt = ts_getInnerText(cell);
2188+ if (cell.className != "unsortable" && cell.className.indexOf("unsortable") == -1) {
2189+ cell.innerHTML = '<a href="#" class="sortheader" onclick="ts_resortTable(this, '+i+');return false;">'+txt+'<span class="sortarrow"></span></a>';
2190+ }
2191+ }
2192+ if (alternate_row_colors) {
2193+ alternate(t);
2194+ }
2195+}
2196+
2197+function ts_getInnerText(el) {
2198+ if (typeof el == "string") return el;
2199+ if (typeof el == "undefined") { return el };
2200+ if (el.innerText) return el.innerText; //Not needed but it is faster
2201+ var str = "";
2202+
2203+ var cs = el.childNodes;
2204+ var l = cs.length;
2205+ for (var i = 0; i < l; i++) {
2206+ switch (cs[i].nodeType) {
2207+ case 1: //ELEMENT_NODE
2208+ str += ts_getInnerText(cs[i]);
2209+ break;
2210+ case 3: //TEXT_NODE
2211+ str += cs[i].nodeValue;
2212+ break;
2213+ }
2214+ }
2215+ return str;
2216+}
2217+
2218+function ts_resortTable(lnk, clid) {
2219+ var span;
2220+ for (var ci=0;ci<lnk.childNodes.length;ci++) {
2221+ if (lnk.childNodes[ci].tagName && lnk.childNodes[ci].tagName.toLowerCase() == 'span') span = lnk.childNodes[ci];
2222+ }
2223+ var spantext = ts_getInnerText(span);
2224+ var td = lnk.parentNode;
2225+ var column = clid || td.cellIndex;
2226+ var t = getParent(td,'TABLE');
2227+ // Work out a type for the column
2228+ if (t.rows.length <= 1) return;
2229+ var itm = "";
2230+ var i = 1;
2231+ while (itm == "" && i < t.tBodies[0].rows.length) {
2232+ var itm = ts_getInnerText(t.tBodies[0].rows[i].cells[column]);
2233+ itm = trim(itm);
2234+ if (itm.substr(0,4) == "<!--" || itm.length == 0) {
2235+ itm = "";
2236+ }
2237+ i++;
2238+ }
2239+ if (itm == "") return;
2240+ sortfn = ts_sort_caseinsensitive;
2241+ if (itm.match(/^\d\d[\/\.-][a-zA-z][a-zA-Z][a-zA-Z][\/\.-]\d\d\d\d$/)) sortfn = ts_sort_date;
2242+ if (itm.match(/^\d\d[\/\.-]\d\d[\/\.-]\d\d\d{2}?$/)) sortfn = ts_sort_date;
2243+ if (itm.match(/^-?[£$€Û¢´]\d/)) sortfn = ts_sort_numeric;
2244+ if (itm.match(/^-?(\d+[,\.]?)+(E[-+][\d]+)?%?$/)) sortfn = ts_sort_numeric;
2245+ if (itm.match(/^-?(\d+[,\.]?\d+e[-+][\d]+)?%?$/)) sortfn = ts_sort_numeric;
2246+ if (itm.match(/^-?(\d+[,\.]?)+([\d]+)?%?$/)) sortfn = ts_sort_numeric;
2247+ SORT_COLUMN_INDEX = column;
2248+ var firstRow = new Array();
2249+ var newRows = new Array();
2250+ for (k=0;k<t.tBodies.length;k++) {
2251+ for (i=0;i<t.tBodies[k].rows[0].length;i++) {
2252+ firstRow[i] = t.tBodies[k].rows[0][i];
2253+ }
2254+ }
2255+ for (k=0;k<t.tBodies.length;k++) {
2256+ if (!thead) {
2257+ // Skip the first row
2258+ for (j=1;j<t.tBodies[k].rows.length;j++) {
2259+ newRows[j-1] = t.tBodies[k].rows[j];
2260+ }
2261+ } else {
2262+ // Do NOT skip the first row
2263+ for (j=0;j<t.tBodies[k].rows.length;j++) {
2264+ newRows[j] = t.tBodies[k].rows[j];
2265+ }
2266+ }
2267+ }
2268+ newRows.sort(sortfn);
2269+ if (span.getAttribute("sortdir") == 'down') {
2270+ ARROW = '&nbsp;&nbsp;&darr;';
2271+ newRows.reverse();
2272+ span.setAttribute('sortdir','up');
2273+ } else {
2274+ ARROW = '&nbsp;&nbsp;&uarr;';
2275+ span.setAttribute('sortdir','down');
2276+ }
2277+ // We appendChild rows that already exist to the tbody, so it moves them rather than creating new ones
2278+ // don't do sortbottom rows
2279+ for (i=0; i<newRows.length; i++) {
2280+ if (!newRows[i].className || (newRows[i].className && (newRows[i].className.indexOf('sortbottom') == -1))) {
2281+ t.tBodies[0].appendChild(newRows[i]);
2282+ }
2283+ }
2284+ // do sortbottom rows only
2285+ for (i=0; i<newRows.length; i++) {
2286+ if (newRows[i].className && (newRows[i].className.indexOf('sortbottom') != -1))
2287+ t.tBodies[0].appendChild(newRows[i]);
2288+ }
2289+ // Delete any other arrows there may be showing
2290+ var allspans = document.getElementsByTagName("span");
2291+ for (var ci=0;ci<allspans.length;ci++) {
2292+ if (allspans[ci].className == 'sortarrow') {
2293+ if (getParent(allspans[ci],"table") == getParent(lnk,"table")) { // in the same table as us?
2294+ allspans[ci].innerHTML = '';
2295+ }
2296+ }
2297+ }
2298+ span.innerHTML = ARROW;
2299+ alternate(t);
2300+}
2301+
2302+function getParent(el, pTagName) {
2303+ if (el == null) {
2304+ return null;
2305+ } else if (el.nodeType == 1 && el.tagName.toLowerCase() == pTagName.toLowerCase()) {
2306+ return el;
2307+ } else {
2308+ return getParent(el.parentNode, pTagName);
2309+ }
2310+}
2311+
2312+function sort_date(date) {
2313+ // y2k notes: two digit years less than 50 are treated as 20XX, greater than 50 are treated as 19XX
2314+ dt = "00000000";
2315+ if (date.length == 11) {
2316+ mtstr = date.substr(3,3);
2317+ mtstr = mtstr.toLowerCase();
2318+ switch(mtstr) {
2319+ case "jan": var mt = "01"; break;
2320+ case "feb": var mt = "02"; break;
2321+ case "mar": var mt = "03"; break;
2322+ case "apr": var mt = "04"; break;
2323+ case "may": var mt = "05"; break;
2324+ case "jun": var mt = "06"; break;
2325+ case "jul": var mt = "07"; break;
2326+ case "aug": var mt = "08"; break;
2327+ case "sep": var mt = "09"; break;
2328+ case "oct": var mt = "10"; break;
2329+ case "nov": var mt = "11"; break;
2330+ case "dec": var mt = "12"; break;
2331+ // default: var mt = "00";
2332+ }
2333+ dt = date.substr(7,4)+mt+date.substr(0,2);
2334+ return dt;
2335+ } else if (date.length == 10) {
2336+ if (europeandate == false) {
2337+ dt = date.substr(6,4)+date.substr(0,2)+date.substr(3,2);
2338+ return dt;
2339+ } else {
2340+ dt = date.substr(6,4)+date.substr(3,2)+date.substr(0,2);
2341+ return dt;
2342+ }
2343+ } else if (date.length == 8) {
2344+ yr = date.substr(6,2);
2345+ if (parseInt(yr) < 50) {
2346+ yr = '20'+yr;
2347+ } else {
2348+ yr = '19'+yr;
2349+ }
2350+ if (europeandate == true) {
2351+ dt = yr+date.substr(3,2)+date.substr(0,2);
2352+ return dt;
2353+ } else {
2354+ dt = yr+date.substr(0,2)+date.substr(3,2);
2355+ return dt;
2356+ }
2357+ }
2358+ return dt;
2359+}
2360+
2361+function ts_sort_date(a,b) {
2362+ dt1 = sort_date(ts_getInnerText(a.cells[SORT_COLUMN_INDEX]));
2363+ dt2 = sort_date(ts_getInnerText(b.cells[SORT_COLUMN_INDEX]));
2364+
2365+ if (dt1==dt2) {
2366+ return 0;
2367+ }
2368+ if (dt1<dt2) {
2369+ return -1;
2370+ }
2371+ return 1;
2372+}
2373+function ts_sort_numeric(a,b) {
2374+ var aa = ts_getInnerText(a.cells[SORT_COLUMN_INDEX]);
2375+ aa = clean_num(aa);
2376+ var bb = ts_getInnerText(b.cells[SORT_COLUMN_INDEX]);
2377+ bb = clean_num(bb);
2378+ return compare_numeric(aa,bb);
2379+}
2380+function compare_numeric(a,b) {
2381+ var a = parseFloat(a);
2382+ a = (isNaN(a) ? 0 : a);
2383+ var b = parseFloat(b);
2384+ b = (isNaN(b) ? 0 : b);
2385+ return a - b;
2386+}
2387+function ts_sort_caseinsensitive(a,b) {
2388+ aa = ts_getInnerText(a.cells[SORT_COLUMN_INDEX]).toLowerCase();
2389+ bb = ts_getInnerText(b.cells[SORT_COLUMN_INDEX]).toLowerCase();
2390+ if (aa==bb) {
2391+ return 0;
2392+ }
2393+ if (aa<bb) {
2394+ return -1;
2395+ }
2396+ return 1;
2397+}
2398+function ts_sort_default(a,b) {
2399+ aa = ts_getInnerText(a.cells[SORT_COLUMN_INDEX]);
2400+ bb = ts_getInnerText(b.cells[SORT_COLUMN_INDEX]);
2401+ if (aa==bb) {
2402+ return 0;
2403+ }
2404+ if (aa<bb) {
2405+ return -1;
2406+ }
2407+ return 1;
2408+}
2409+
2410+function addEvent(elm, evType, fn, useCapture)
2411+// addEvent and removeEvent
2412+// cross-browser event handling for IE5+, NS6 and Mozilla
2413+// By Scott Andrew
2414+{
2415+ if (elm.addEventListener){
2416+ elm.addEventListener(evType, fn, useCapture);
2417+ return true;
2418+ } else if (elm.attachEvent){
2419+ var r = elm.attachEvent("on"+evType, fn);
2420+ return r;
2421+ } else {
2422+ alert("Handler could not be removed");
2423+ }
2424+}
2425+function clean_num(str) {
2426+ str = str.replace(new RegExp(/[^-?0-9.eE]/g),"");
2427+ return str;
2428+}
2429+function trim(s) {
2430+ return s.replace(/^\s+|\s+$/g, "");
2431+}
2432+function alternate(table) {
2433+ // Take object table and get all it's tbodies.
2434+ var tableBodies = table.getElementsByTagName("tbody");
2435+ // Loop through these tbodies
2436+ for (var i = 0; i < tableBodies.length; i++) {
2437+ // Take the tbody, and get all it's rows
2438+ var tableRows = tableBodies[i].getElementsByTagName("tr");
2439+ // Loop through these rows
2440+ // Start at 1 because we want to leave the heading row untouched
2441+ for (var j = 0; j < tableRows.length; j++) {
2442+ // Check if j is even, and apply classes for both possible results
2443+ if ( (j % 2) == 0 ) {
2444+ if ( !(tableRows[j].className.indexOf('odd') == -1) ) {
2445+ tableRows[j].className = tableRows[j].className.replace('odd', 'even');
2446+ } else {
2447+ if ( tableRows[j].className.indexOf('even') == -1 ) {
2448+ tableRows[j].className += " even";
2449+ }
2450+ }
2451+ } else {
2452+ if ( !(tableRows[j].className.indexOf('even') == -1) ) {
2453+ tableRows[j].className = tableRows[j].className.replace('even', 'odd');
2454+ } else {
2455+ if ( tableRows[j].className.indexOf('odd') == -1 ) {
2456+ tableRows[j].className += " odd";
2457+ }
2458+ }
2459+ }
2460+ }
2461+ }
2462+}
2463
2464=== added file 'Template/NLO/HTML/stop.jpg'
2465Binary files Template/NLO/HTML/stop.jpg 1970-01-01 00:00:00 +0000 and Template/NLO/HTML/stop.jpg 2012-09-28 12:29:27 +0000 differ
2466=== added file 'Template/NLO/HTML/thinking.gif'
2467Binary files Template/NLO/HTML/thinking.gif 1970-01-01 00:00:00 +0000 and Template/NLO/HTML/thinking.gif 2012-09-28 12:29:27 +0000 differ
2468=== added file 'Template/NLO/MGMEVersion.txt'
2469--- Template/NLO/MGMEVersion.txt 1970-01-01 00:00:00 +0000
2470+++ Template/NLO/MGMEVersion.txt 2012-09-28 12:29:27 +0000
2471@@ -0,0 +1,1 @@
2472+4.5.0
2473
2474=== added file 'Template/NLO/README'
2475--- Template/NLO/README 1970-01-01 00:00:00 +0000
2476+++ Template/NLO/README 2012-09-28 12:29:27 +0000
2477@@ -0,0 +1,69 @@
2478+MadGraph/MadEvent 4.0
2479+By Fabio Maltoni, Tim Stelzer and the CP3 development team
2480+
2481+http://madgraph.phys.ucl.ac.be/
2482+http://madgraph.hep.uiuc.edu/
2483+http://madgraph.roma2.infn.it/
2484+
2485+Information on the process to be generated is found in the file
2486+index.html in this directory, which should be viewed using your web
2487+browser. If the file index.html is missing, you need to generate a
2488+process. Please refer to the README file one directory above this
2489+(MG_ME_V?.?.?/) for instructions on how to generate a process.
2490+
2491+
2492+To generate events:
2493+-------------------
2494+
2495+1) Specify the model parameters. The model parameters include masses
2496+and widths for the particles and coupling constants. They are given by
2497+the file param_card.dat in the Cards directory. Although it is
2498+possible to edit this file manually, this is not recommended since
2499+there are dependencies among the parameters which need to be taken
2500+into account. Instead the param_card.dat should be generated using one
2501+of the Calculators found on the MG/ME homepages (stated above). Click
2502+Calculators, choose model and follow the instructions. Place the
2503+resulting param_card.dat in the Cards directory.
2504+
2505+2) Specify the run parameters. The run parameters includes collider
2506+type and energy, choice of parton distribution functions and scales.
2507+They are given by the file run_card.dat in the Cards directory. This
2508+file should be edited manually, following the syntax given in the
2509+example file.
2510+**Warning!** For several reasons, avoid running more than 100,000
2511+events per run. Instead perform several runs to reach the luminosity
2512+you need. Subsequent runs automatically update the random seed, so the
2513+results from different runs are statistically independent.
2514+
2515+3) Run bin/generate_events to generate the events and calculate the
2516+cross-section.
2517+
2518+4) Follow the generation and look at the results in the file
2519+HTML/crossx.html, using your web browser.
2520+
2521+5) If you want to run Pythia and/or PGS/Delphes on the events,
2522+download the Pythia/PGS package (and Delphes) and untar one directory
2523+above this (the MG_ME directory) and run make. Make sure the cards
2524+pythia_card.dat and pgs_card.dat are present in the Cards/ directory.
2525+If this is the case, Pythia and PGS will automatically be run by
2526+generate_events, or, for an existing run, use bin/run_pythia and
2527+bin/run_pgs.
2528+
2529+
2530+To use LHAPDF with MadGraph/MadEvent
2531+------------------------------------
2532+
2533+Please follow the steps below to run MadEvent with LHAPDF support:
2534+
2535+1) Download and compile LHAPDF
2536+
2537+2) Link (or copy) the following files from the LHAPDF directory to the lib/ directory:
2538+- libLHAPDF.a
2539+- libLHAPDF.so and libLHAPDF.so.0 (if you are running dynamic compilation for a grid pack)
2540+- PDFsets
2541+
2542+3) Set the pdlabel and define the LHA pdf number you want to use in your run_card.dat
2543+ 'lhapdf' = pdlabel ! PDF set
2544+ 10042 = lhaid ! PDF number used ONLY for LHAPDF
2545+
2546+4) Run generate_events (or run.sh/...) as usual
2547
2548=== added directory 'Template/NLO/Source'
2549=== added directory 'Template/NLO/Source/CERNLIB'
2550=== added file 'Template/NLO/Source/CERNLIB/abend.f'
2551--- Template/NLO/Source/CERNLIB/abend.f 1970-01-01 00:00:00 +0000
2552+++ Template/NLO/Source/CERNLIB/abend.f 2012-09-28 12:29:27 +0000
2553@@ -0,0 +1,19 @@
2554+*
2555+* $Id: abend.f,v 1.1 2009/07/30 22:46:16 madgraph Exp $
2556+*
2557+* $Log: abend.f,v $
2558+* Revision 1.1 2009/07/30 22:46:16 madgraph
2559+* JA: Implemented CKKW-style matching with Pythia pT-ordered showers
2560+*
2561+* Revision 1.1.1.1 1996/02/15 17:50:37 mclareni
2562+* Kernlib
2563+*
2564+*
2565+ SUBROUTINE ABEND
2566+C
2567+C CERN PROGLIB# Z035 ABEND .VERSION KERNFOR 4.31 911111
2568+C ORIG. 8/02/88 JZ
2569+C
2570+
2571+ STOP 7
2572+ END
2573
2574=== added file 'Template/NLO/Source/CERNLIB/dlsqp2.f'
2575--- Template/NLO/Source/CERNLIB/dlsqp2.f 1970-01-01 00:00:00 +0000
2576+++ Template/NLO/Source/CERNLIB/dlsqp2.f 2012-09-28 12:29:27 +0000
2577@@ -0,0 +1,69 @@
2578+*
2579+* $Id: dlsqp2.f,v 1.1 2009/07/30 22:46:16 madgraph Exp $
2580+*
2581+* $Log: dlsqp2.f,v $
2582+* Revision 1.1 2009/07/30 22:46:16 madgraph
2583+* JA: Implemented CKKW-style matching with Pythia pT-ordered showers
2584+*
2585+* Revision 1.1.1.1 1996/04/01 15:02:24 mclareni
2586+* Mathlib gen
2587+*
2588+*
2589+ SUBROUTINE DLSQP2(N,X,Y,A0,A1,A2,SD,IFAIL)
2590+ IMPLICIT DOUBLE PRECISION (A-H,O-Z)
2591+
2592+ DIMENSION X(*),Y(*)
2593+
2594+ PARAMETER (R0 = 0)
2595+
2596+ A0=0
2597+ A1=0
2598+ A2=0
2599+ SD=0
2600+ IF(N .LE. 2) THEN
2601+ IFAIL=1
2602+ ELSE
2603+ FN=N
2604+ XM=0
2605+ DO 1 K = 1,N
2606+ XM=XM+X(K)
2607+ 1 CONTINUE
2608+ XM=XM/FN
2609+ SX=0
2610+ SXX=0
2611+ SXXX=0
2612+ SXXXX=0
2613+ SY=0
2614+ SYY=0
2615+ SXY=0
2616+ SXXY=0
2617+ DO 2 K = 1,N
2618+ XK=X(K)-XM
2619+ YK=Y(K)
2620+ XK2=XK**2
2621+ SX=SX+XK
2622+ SXX=SXX+XK2
2623+ SXXX=SXXX+XK2*XK
2624+ SXXXX=SXXXX+XK2**2
2625+ SY=SY+YK
2626+ SYY=SYY+YK**2
2627+ SXY=SXY+XK*YK
2628+ SXXY=SXXY+XK2*YK
2629+ 2 CONTINUE
2630+ DET=(FN*SXXXX-SXX**2)*SXX-FN*SXXX**2
2631+ IF(DET .GT. 0) THEN
2632+ A2=(SXX*(FN*SXXY-SXX*SY)-FN*SXXX*SXY)/DET
2633+ A1=(SXY-SXXX*A2)/SXX
2634+ A0=(SY-SXX*A2)/FN
2635+ IFAIL=0
2636+ ELSE
2637+ IFAIL=-1
2638+ ENDIF
2639+ ENDIF
2640+ IF(IFAIL .EQ. 0 .AND. N .GT. 3)
2641+ 1 SD=SQRT(MAX(R0,SYY-A0*SY-A1*SXY-A2*SXXY)/(N-3))
2642+ A0=A0+XM*(XM*A2-A1)
2643+ A1=A1-2*XM*A2
2644+ RETURN
2645+ END
2646+
2647
2648=== added file 'Template/NLO/Source/CERNLIB/lenocc.f'
2649--- Template/NLO/Source/CERNLIB/lenocc.f 1970-01-01 00:00:00 +0000
2650+++ Template/NLO/Source/CERNLIB/lenocc.f 2012-09-28 12:29:27 +0000
2651@@ -0,0 +1,30 @@
2652+*
2653+* $Id: lenocc.f,v 1.1 2009/07/30 22:46:16 madgraph Exp $
2654+*
2655+* $Log: lenocc.f,v $
2656+* Revision 1.1 2009/07/30 22:46:16 madgraph
2657+* JA: Implemented CKKW-style matching with Pythia pT-ordered showers
2658+*
2659+* Revision 1.1.1.1 1996/02/15 17:49:49 mclareni
2660+* Kernlib
2661+*
2662+*
2663+ FUNCTION LENOCC (CHV)
2664+C
2665+C CERN PROGLIB# M507 LENOCC .VERSION KERNFOR 4.21 890323
2666+C ORIG. March 85, A.Petrilli, re-write 21/02/89, JZ
2667+C
2668+C- Find last non-blank character in CHV
2669+
2670+ CHARACTER CHV*(*)
2671+
2672+ N = LEN(CHV)
2673+
2674+ DO 17 JJ= N,1,-1
2675+ IF (CHV(JJ:JJ).NE.' ') GO TO 99
2676+ 17 CONTINUE
2677+ JJ = 0
2678+
2679+ 99 LENOCC = JJ
2680+ RETURN
2681+ END
2682
2683=== added file 'Template/NLO/Source/CERNLIB/makefile'
2684--- Template/NLO/Source/CERNLIB/makefile 1970-01-01 00:00:00 +0000
2685+++ Template/NLO/Source/CERNLIB/makefile 2012-09-28 12:29:27 +0000
2686@@ -0,0 +1,17 @@
2687+# Note that optimization doesn't work on all machines
2688+
2689+include ../make_opts
2690+
2691+LIBRARY = libcernlib.a
2692+LIBDIR = ../../lib/
2693+SOURCES = abend.o dlsqp2.o lenocc.o mtlprt.o mtlset.o radmul.o
2694+
2695+all: $(LIBDIR)$(LIBRARY)
2696+
2697+%.o : %.f makefile
2698+ $(F77) $(FFLAGS) -c $<
2699+
2700+$(LIBDIR)$(LIBRARY): $(SOURCES)
2701+ ar cru $(LIBRARY) $^
2702+ ranlib $(LIBRARY)
2703+ mv $(LIBRARY) $(LIBDIR)
2704
2705=== added file 'Template/NLO/Source/CERNLIB/mtlprt.f'
2706--- Template/NLO/Source/CERNLIB/mtlprt.f 1970-01-01 00:00:00 +0000
2707+++ Template/NLO/Source/CERNLIB/mtlprt.f 2012-09-28 12:29:27 +0000
2708@@ -0,0 +1,30 @@
2709+*
2710+* $Id: mtlprt.f,v 1.1 2009/07/30 22:46:16 madgraph Exp $
2711+*
2712+* $Log: mtlprt.f,v $
2713+* Revision 1.1 2009/07/30 22:46:16 madgraph
2714+* JA: Implemented CKKW-style matching with Pythia pT-ordered showers
2715+*
2716+* Revision 1.1.1.1 1996/04/01 15:02:52 mclareni
2717+* Mathlib gen
2718+*
2719+*
2720+ SUBROUTINE MTLPRT(NAME,ERC,TEXT)
2721+ CHARACTER*(*) NAME,ERC,TEXT
2722+ LOGICAL LMF,LRF
2723+
2724+ IF(ERC(5:6).NE.'.0') THEN
2725+ CALL MTLMTR(ERC,MLG,LMF,LRF)
2726+ ELSE
2727+ LMF=.TRUE.
2728+ LRF=.FALSE.
2729+ ENDIF
2730+ IF(LMF) THEN
2731+ LT=LENOCC(TEXT)
2732+ IF(MLG .LT. 1) WRITE( *,100) ERC(1:4),NAME,ERC,TEXT(1:LT)
2733+ IF(MLG .GE. 1) WRITE(MLG,100) ERC(1:4),NAME,ERC,TEXT(1:LT)
2734+ ENDIF
2735+ IF(.NOT.LRF) CALL ABEND
2736+ RETURN
2737+100 FORMAT(7X,'***** CERN ',A,1X,A,' ERROR ',A,': ',A)
2738+ END
2739
2740=== added file 'Template/NLO/Source/CERNLIB/mtlset.f'
2741--- Template/NLO/Source/CERNLIB/mtlset.f 1970-01-01 00:00:00 +0000
2742+++ Template/NLO/Source/CERNLIB/mtlset.f 2012-09-28 12:29:27 +0000
2743@@ -0,0 +1,197 @@
2744+*
2745+* $Id: mtlset.f,v 1.1 2009/07/30 22:46:16 madgraph Exp $
2746+*
2747+* $Log: mtlset.f,v $
2748+* Revision 1.1 2009/07/30 22:46:16 madgraph
2749+* JA: Implemented CKKW-style matching with Pythia pT-ordered showers
2750+*
2751+* Revision 1.1.1.1 1996/04/01 15:02:53 mclareni
2752+* Mathlib gen
2753+*
2754+*
2755+ SUBROUTINE MTLSET(ERC,NLG,MXM,MXR)
2756+
2757+ PARAMETER (KTE = 132)
2758+ CHARACTER*6 ERC,CODE(KTE)
2759+ LOGICAL LMF,LRF
2760+ DIMENSION KNTM(KTE),KNTR(KTE)
2761+
2762+ DATA ILG /0/
2763+
2764+C renumber the data statements after putting new codes in Unix with:
2765+C awk -F'[()]' '{ printf"%s(%s)%s(%s)%s(%s)%s\n",$1,NR,$3,NR,$5,NR,$7 }'
2766+C and modify KTE to the number of lines below
2767+
2768+ DATA CODE(1),KNTM(1),KNTR(1) / 'B100.1', 255, 255 /
2769+ DATA CODE(2),KNTM(2),KNTR(2) / 'B300.1', 255, 255 /
2770+ DATA CODE(3),KNTM(3),KNTR(3) / 'B300.2', 255, 255 /
2771+ DATA CODE(4),KNTM(4),KNTR(4) / 'C200.0', 255, 255 /
2772+ DATA CODE(5),KNTM(5),KNTR(5) / 'C200.1', 255, 255 /
2773+ DATA CODE(6),KNTM(6),KNTR(6) / 'C200.2', 255, 255 /
2774+ DATA CODE(7),KNTM(7),KNTR(7) / 'C200.3', 255, 255 /
2775+ DATA CODE(8),KNTM(8),KNTR(8) / 'C201.0', 255, 255 /
2776+ DATA CODE(9),KNTM(9),KNTR(9) / 'C202.0', 255, 255 /
2777+ DATA CODE(10),KNTM(10),KNTR(10) / 'C202.1', 255, 255 /
2778+ DATA CODE(11),KNTM(11),KNTR(11) / 'C202.2', 255, 255 /
2779+ DATA CODE(12),KNTM(12),KNTR(12) / 'C205.1', 255, 255 /
2780+ DATA CODE(13),KNTM(13),KNTR(13) / 'C205.2', 255, 255 /
2781+ DATA CODE(14),KNTM(14),KNTR(14) / 'C207.0', 255, 255 /
2782+ DATA CODE(15),KNTM(15),KNTR(15) / 'C208.0', 255, 255 /
2783+ DATA CODE(16),KNTM(16),KNTR(16) / 'C209.0', 255, 255 /
2784+ DATA CODE(17),KNTM(17),KNTR(17) / 'C209.1', 255, 255 /
2785+ DATA CODE(18),KNTM(18),KNTR(18) / 'C209.2', 255, 255 /
2786+ DATA CODE(19),KNTM(19),KNTR(19) / 'C209.3', 255, 255 /
2787+ DATA CODE(20),KNTM(20),KNTR(20) / 'C210.1', 255, 255 /
2788+ DATA CODE(21),KNTM(21),KNTR(21) / 'C302.1', 255, 255 /
2789+ DATA CODE(22),KNTM(22),KNTR(22) / 'C303.1', 255, 255 /
2790+ DATA CODE(23),KNTM(23),KNTR(23) / 'C304.1', 255, 255 /
2791+ DATA CODE(24),KNTM(24),KNTR(24) / 'C305.1', 255, 255 /
2792+ DATA CODE(25),KNTM(25),KNTR(25) / 'C306.1', 255, 255 /
2793+ DATA CODE(26),KNTM(26),KNTR(26) / 'C307.1', 255, 255 /
2794+ DATA CODE(27),KNTM(27),KNTR(27) / 'C312.1', 255, 255 /
2795+ DATA CODE(28),KNTM(28),KNTR(28) / 'C313.1', 255, 255 /
2796+ DATA CODE(29),KNTM(29),KNTR(29) / 'C315.1', 255, 255 /
2797+ DATA CODE(30),KNTM(30),KNTR(30) / 'C316.1', 255, 255 /
2798+ DATA CODE(31),KNTM(31),KNTR(31) / 'C316.2', 255, 255 /
2799+ DATA CODE(32),KNTM(32),KNTR(32) / 'C320.1', 255, 255 /
2800+ DATA CODE(33),KNTM(33),KNTR(33) / 'C321.1', 255, 255 /
2801+ DATA CODE(34),KNTM(34),KNTR(34) / 'C323.1', 255, 255 /
2802+ DATA CODE(35),KNTM(35),KNTR(35) / 'C327.1', 255, 255 /
2803+ DATA CODE(36),KNTM(36),KNTR(36) / 'C328.1', 255, 255 /
2804+ DATA CODE(37),KNTM(37),KNTR(37) / 'C328.2', 255, 255 /
2805+ DATA CODE(38),KNTM(38),KNTR(38) / 'C328.3', 255, 255 /
2806+ DATA CODE(39),KNTM(39),KNTR(39) / 'C330.1', 255, 255 /
2807+ DATA CODE(40),KNTM(40),KNTR(40) / 'C330.2', 255, 255 /
2808+ DATA CODE(41),KNTM(41),KNTR(41) / 'C330.3', 255, 255 /
2809+ DATA CODE(42),KNTM(42),KNTR(42) / 'C331.1', 255, 255 /
2810+ DATA CODE(43),KNTM(43),KNTR(43) / 'C331.2', 255, 255 /
2811+ DATA CODE(44),KNTM(44),KNTR(44) / 'C334.1', 255, 255 /
2812+ DATA CODE(45),KNTM(45),KNTR(45) / 'C334.2', 255, 255 /
2813+ DATA CODE(46),KNTM(46),KNTR(46) / 'C334.3', 255, 255 /
2814+ DATA CODE(47),KNTM(47),KNTR(47) / 'C334.4', 255, 255 /
2815+ DATA CODE(48),KNTM(48),KNTR(48) / 'C334.5', 255, 255 /
2816+ DATA CODE(49),KNTM(49),KNTR(49) / 'C334.6', 255, 255 /
2817+ DATA CODE(50),KNTM(50),KNTR(50) / 'C336.1', 255, 255 /
2818+ DATA CODE(51),KNTM(51),KNTR(51) / 'C337.1', 255, 255 /
2819+ DATA CODE(52),KNTM(52),KNTR(52) / 'C338.1', 255, 255 /
2820+ DATA CODE(53),KNTM(53),KNTR(53) / 'C340.1', 255, 255 /
2821+ DATA CODE(54),KNTM(54),KNTR(54) / 'C343.1', 255, 255 /
2822+ DATA CODE(55),KNTM(55),KNTR(55) / 'C343.2', 255, 255 /
2823+ DATA CODE(56),KNTM(56),KNTR(56) / 'C343.3', 255, 255 /
2824+ DATA CODE(57),KNTM(57),KNTR(57) / 'C343.4', 255, 255 /
2825+ DATA CODE(58),KNTM(58),KNTR(58) / 'C344.1', 255, 255 /
2826+ DATA CODE(59),KNTM(59),KNTR(59) / 'C344.2', 255, 255 /
2827+ DATA CODE(60),KNTM(60),KNTR(60) / 'C344.3', 255, 255 /
2828+ DATA CODE(61),KNTM(61),KNTR(61) / 'C344.4', 255, 255 /
2829+ DATA CODE(62),KNTM(62),KNTR(62) / 'C345.1', 255, 255 /
2830+ DATA CODE(63),KNTM(63),KNTR(63) / 'C346.1', 255, 255 /
2831+ DATA CODE(64),KNTM(64),KNTR(64) / 'C346.2', 255, 255 /
2832+ DATA CODE(65),KNTM(65),KNTR(65) / 'C346.3', 255, 255 /
2833+ DATA CODE(66),KNTM(66),KNTR(66) / 'C347.1', 255, 255 /
2834+ DATA CODE(67),KNTM(67),KNTR(67) / 'C347.2', 255, 255 /
2835+ DATA CODE(68),KNTM(68),KNTR(68) / 'C347.3', 255, 255 /
2836+ DATA CODE(69),KNTM(69),KNTR(69) / 'C347.4', 255, 255 /
2837+ DATA CODE(70),KNTM(70),KNTR(70) / 'C347.5', 255, 255 /
2838+ DATA CODE(71),KNTM(71),KNTR(71) / 'C347.6', 255, 255 /
2839+ DATA CODE(72),KNTM(72),KNTR(72) / 'C348.1', 255, 255 /
2840+ DATA CODE(73),KNTM(73),KNTR(73) / 'C349.1', 255, 255 /
2841+ DATA CODE(74),KNTM(74),KNTR(74) / 'C349.2', 255, 255 /
2842+ DATA CODE(75),KNTM(75),KNTR(75) / 'C349.3', 255, 255 /
2843+ DATA CODE(76),KNTM(76),KNTR(76) / 'D101.1', 255, 255 /
2844+ DATA CODE(77),KNTM(77),KNTR(77) / 'D103.1', 255, 255 /
2845+ DATA CODE(78),KNTM(78),KNTR(78) / 'D104.1', 255, 255 /
2846+ DATA CODE(79),KNTM(79),KNTR(79) / 'D104.2', 255, 255 /
2847+ DATA CODE(80),KNTM(80),KNTR(80) / 'D105.1', 255, 255 /
2848+ DATA CODE(81),KNTM(81),KNTR(81) / 'D105.2', 255, 255 /
2849+ DATA CODE(82),KNTM(82),KNTR(82) / 'D107.1', 255, 255 /
2850+ DATA CODE(83),KNTM(83),KNTR(83) / 'D110.0', 255, 255 /
2851+ DATA CODE(84),KNTM(84),KNTR(84) / 'D110.1', 255, 255 /
2852+ DATA CODE(85),KNTM(85),KNTR(85) / 'D110.2', 255, 255 /
2853+ DATA CODE(86),KNTM(86),KNTR(86) / 'D110.3', 255, 255 /
2854+ DATA CODE(87),KNTM(87),KNTR(87) / 'D110.4', 255, 255 /
2855+ DATA CODE(88),KNTM(88),KNTR(88) / 'D110.5', 255, 255 /
2856+ DATA CODE(89),KNTM(89),KNTR(89) / 'D110.6', 255, 255 /
2857+ DATA CODE(90),KNTM(90),KNTR(90) / 'D113.1', 255, 255 /
2858+ DATA CODE(91),KNTM(91),KNTR(91) / 'D201.1', 255, 255 /
2859+ DATA CODE(92),KNTM(92),KNTR(92) / 'D202.1', 255, 255 /
2860+ DATA CODE(93),KNTM(93),KNTR(93) / 'D401.1', 255, 255 /
2861+ DATA CODE(94),KNTM(94),KNTR(94) / 'D601.1', 255, 255 /
2862+ DATA CODE(95),KNTM(95),KNTR(95) / 'E210.1', 255, 255 /
2863+ DATA CODE(96),KNTM(96),KNTR(96) / 'E210.2', 255, 255 /
2864+ DATA CODE(97),KNTM(97),KNTR(97) / 'E210.3', 255, 255 /
2865+ DATA CODE(98),KNTM(98),KNTR(98) / 'E210.4', 255, 255 /
2866+ DATA CODE(99),KNTM(99),KNTR(99) / 'E210.5', 255, 255 /
2867+ DATA CODE(100),KNTM(100),KNTR(100) / 'E210.6', 255, 255 /
2868+ DATA CODE(101),KNTM(101),KNTR(101) / 'E210.7', 255, 255 /
2869+ DATA CODE(102),KNTM(102),KNTR(102) / 'E211.0', 255, 255 /
2870+ DATA CODE(103),KNTM(103),KNTR(103) / 'E211.1', 255, 255 /
2871+ DATA CODE(104),KNTM(104),KNTR(104) / 'E211.2', 255, 255 /
2872+ DATA CODE(105),KNTM(105),KNTR(105) / 'E211.3', 255, 255 /
2873+ DATA CODE(106),KNTM(106),KNTR(106) / 'E211.4', 255, 255 /
2874+ DATA CODE(107),KNTM(107),KNTR(107) / 'E406.0', 255, 255 /
2875+ DATA CODE(108),KNTM(108),KNTR(108) / 'E406.1', 255, 255 /
2876+ DATA CODE(109),KNTM(109),KNTR(109) / 'E407.0', 255, 255 /
2877+ DATA CODE(110),KNTM(110),KNTR(110) / 'E408.0', 255, 255 /
2878+ DATA CODE(111),KNTM(111),KNTR(111) / 'E408.1', 255, 255 /
2879+ DATA CODE(112),KNTM(112),KNTR(112) / 'F500.0', 255, 255 /
2880+ DATA CODE(113),KNTM(113),KNTR(113) / 'F500.1', 255, 255 /
2881+ DATA CODE(114),KNTM(114),KNTR(114) / 'F500.2', 255, 255 /
2882+ DATA CODE(115),KNTM(115),KNTR(115) / 'F500.3', 255, 255 /
2883+ DATA CODE(116),KNTM(116),KNTR(116) / 'G100.1', 255, 255 /
2884+ DATA CODE(117),KNTM(117),KNTR(117) / 'G100.2', 255, 255 /
2885+ DATA CODE(118),KNTM(118),KNTR(118) / 'G101.1', 255, 255 /
2886+ DATA CODE(119),KNTM(119),KNTR(119) / 'G101.2', 255, 255 /
2887+ DATA CODE(120),KNTM(120),KNTR(120) / 'G105.1', 255, 255 /
2888+ DATA CODE(121),KNTM(121),KNTR(121) / 'G106.1', 255, 255 /
2889+ DATA CODE(122),KNTM(122),KNTR(122) / 'G106.2', 255, 255 /
2890+ DATA CODE(123),KNTM(123),KNTR(123) / 'G116.1', 255, 255 /
2891+ DATA CODE(124),KNTM(124),KNTR(124) / 'G116.2', 255, 255 /
2892+ DATA CODE(125),KNTM(125),KNTR(125) / 'H101.0', 255, 255 /
2893+ DATA CODE(126),KNTM(126),KNTR(126) / 'H101.1', 255, 255 /
2894+ DATA CODE(127),KNTM(127),KNTR(127) / 'H101.2', 255, 255 /
2895+ DATA CODE(128),KNTM(128),KNTR(128) / 'H301.1', 255, 255 /
2896+ DATA CODE(129),KNTM(129),KNTR(129) / 'U501.1', 255, 255 /
2897+ DATA CODE(130),KNTM(130),KNTR(130) / 'V202.1', 255, 255 /
2898+ DATA CODE(131),KNTM(131),KNTR(131) / 'V202.2', 255, 255 /
2899+ DATA CODE(132),KNTM(132),KNTR(132) / 'V202.3', 255, 255 /
2900+
2901+ ILG=NLG
2902+ L=0
2903+ IF(ERC .NE. ' ') THEN
2904+ DO 10 L = 1,6
2905+ IF(ERC(1:L) .EQ. ERC) GOTO 12
2906+ 10 CONTINUE
2907+ 12 CONTINUE
2908+ ENDIF
2909+ DO 14 I = 1,KTE
2910+ IF(L .EQ. 0 .OR. CODE(I)(1:L) .EQ. ERC(1:L)) THEN
2911+ IF(MXM .GE. 0) KNTM(I)=MXM
2912+ IF(MXR .GE. 0) KNTR(I)=MXR
2913+ ENDIF
2914+ 14 CONTINUE
2915+ RETURN
2916+
2917+ ENTRY MTLMTR(ERC,MLG,LMF,LRF)
2918+
2919+ MLG=ILG
2920+ DO 20 I = 1,KTE
2921+ IF(ERC .EQ. CODE(I)) GOTO 21
2922+ 20 CONTINUE
2923+ WRITE(*,100) ERC
2924+ CALL ABEND
2925+ RETURN
2926+
2927+ 21 LMF=KNTM(I) .GE. 1
2928+ LRF=KNTR(I) .GE. 1
2929+ IF(LMF .AND. KNTM(I) .LT. 255) KNTM(I)=KNTM(I)-1
2930+ IF(LRF .AND. KNTR(I) .LT. 255) KNTR(I)=KNTR(I)-1
2931+ IF(.NOT.LRF) THEN
2932+ IF(ILG .LT. 1) WRITE( *,101) CODE(I)
2933+ IF(ILG .GE. 1) WRITE(ILG,101) CODE(I)
2934+ ENDIF
2935+ RETURN
2936+ 100 FORMAT(7X,'***** CERN N002 MTLSET ... ERROR N002: ',
2937+ 1'ERROR CODE ',A6,' NOT RECOGNIZED BY ERROR MONITOR. RUN ABORTED.')
2938+ 101 FORMAT(7X,'***** CERN N002 MTLSET ... ERROR NOO2.1: ',
2939+ 1'RUN TERMINATED BY LIBRARY ERROR CONDITION ',A6)
2940+ END
2941
2942=== added file 'Template/NLO/Source/CERNLIB/radmul.f'
2943--- Template/NLO/Source/CERNLIB/radmul.f 1970-01-01 00:00:00 +0000
2944+++ Template/NLO/Source/CERNLIB/radmul.f 2012-09-28 12:29:27 +0000
2945@@ -0,0 +1,207 @@
2946+*
2947+* $Id
2948+*
2949+* $Log
2950+*
2951+ SUBROUTINE RADMUL
2952+ 1 (F,N,A,B,MINPTS,MAXPTS,EPS,WK,IWK,RESULT,RELERR,NFNEVL,IFAIL)
2953+ CHARACTER NAME*(*)
2954+ PARAMETER (NAME = 'RADMUL')
2955+ CALL MTLPRT(NAME,'D120',
2956+ +'not available on this machine - see documentation')
2957+ RETURN
2958+ END
2959+
2960+ SUBROUTINE DADMUL
2961+ 1 (F,N,A,B,MINPTS,MAXPTS,EPS,WK,IWK,RESULT,RELERR,NFNEVL,IFAIL)
2962+ IMPLICIT DOUBLE PRECISION (A-H,O-Z)
2963+
2964+ LOGICAL LDV
2965+
2966+ DIMENSION A(*),B(*),WK(*)
2967+ DIMENSION CTR(15),WTH(15),WTHL(15),Z(15)
2968+ DIMENSION W(2:15,5),WP(2:15,3)
2969+
2970+ PARAMETER (R1 = 1, HF = R1/2)
2971+
2972+ PARAMETER (XL2 = 0.35856 85828 00318 073D0)
2973+ PARAMETER (XL4 = 0.94868 32980 50513 796D0)
2974+ PARAMETER (XL5 = 0.68824 72016 11685 289D0)
2975+
2976+ PARAMETER (W2 = 980*R1/6561, W4 = 200*R1/19683)
2977+ PARAMETER (WP2 = 245*R1/486, WP4 = 25*R1/729)
2978+
2979+ DATA (W(N,1),W(N,3),N=2,15)
2980+ 1/-0.193872885230909911D+00, 0.518213686937966768D-01,
2981+ 2 -0.555606360818980835D+00, 0.314992633236803330D-01,
2982+ 3 -0.876695625666819078D+00, 0.111771579535639891D-01,
2983+ 4 -0.115714067977442459D+01, -0.914494741655235473D-02,
2984+ 5 -0.139694152314179743D+01, -0.294670527866686986D-01,
2985+ 6 -0.159609815576893754D+01, -0.497891581567850424D-01,
2986+ 7 -0.175461057765584494D+01, -0.701112635269013768D-01,
2987+ 8 -0.187247878880251983D+01, -0.904333688970177241D-01,
2988+ 9 -0.194970278920896201D+01, -0.110755474267134071D+00,
2989+ A -0.198628257887517146D+01, -0.131077579637250419D+00,
2990+ B -0.198221815780114818D+01, -0.151399685007366752D+00,
2991+ C -0.193750952598689219D+01, -0.171721790377483099D+00,
2992+ D -0.185215668343240347D+01, -0.192043895747599447D+00,
2993+ E -0.172615963013768225D+01, -0.212366001117715794D+00/
2994+
2995+ DATA (W(N,5),W(N+1,5),N=2,14,2)
2996+ 1/ 0.871183254585174982D-01, 0.435591627292587508D-01,
2997+ 2 0.217795813646293754D-01, 0.108897906823146873D-01,
2998+ 3 0.544489534115734364D-02, 0.272244767057867193D-02,
2999+ 4 0.136122383528933596D-02, 0.680611917644667955D-03,
3000+ 5 0.340305958822333977D-03, 0.170152979411166995D-03,
3001+ 6 0.850764897055834977D-04, 0.425382448527917472D-04,
3002+ 7 0.212691224263958736D-04, 0.106345612131979372D-04/
3003+
3004+ DATA (WP(N,1),WP(N,3),N=2,15)
3005+ 1/-0.133196159122085045D+01, 0.445816186556927292D-01,
3006+ 2 -0.229218106995884763D+01, -0.240054869684499309D-01,
3007+ 3 -0.311522633744855959D+01, -0.925925925925925875D-01,
3008+ 4 -0.380109739368998611D+01, -0.161179698216735251D+00,
3009+ 5 -0.434979423868312742D+01, -0.229766803840877915D+00,
3010+ 6 -0.476131687242798352D+01, -0.298353909465020564D+00,
3011+ 7 -0.503566529492455417D+01, -0.366941015089163228D+00,
3012+ 8 -0.517283950617283939D+01, -0.435528120713305891D+00,
3013+ 9 -0.517283950617283939D+01, -0.504115226337448555D+00,
3014+ A -0.503566529492455417D+01, -0.572702331961591218D+00,
3015+ B -0.476131687242798352D+01, -0.641289437585733882D+00,
3016+ C -0.434979423868312742D+01, -0.709876543209876532D+00,
3017+ D -0.380109739368998611D+01, -0.778463648834019195D+00,
3018+ E -0.311522633744855959D+01, -0.847050754458161859D+00/
3019+
3020+ RESULT=0
3021+ ABSERR=0
3022+ IFAIL=3
3023+ IF(N .LT. 2 .OR. N .GT. 15) RETURN
3024+ IF(MINPTS .GT. MAXPTS) RETURN
3025+
3026+ IFNCLS=0
3027+ LDV=.FALSE.
3028+ TWONDM=2**N
3029+ IRGNST=2*N+3
3030+ IRLCLS=2**N+2*N*(N+1)+1
3031+ ISBRGN=IRGNST
3032+ ISBRGS=IRGNST
3033+ IF(MAXPTS .LT. IRLCLS) RETURN
3034+ DO 10 J = 1,N
3035+ CTR(J)=(B(J)+A(J))*HF
3036+ 10 WTH(J)=(B(J)-A(J))*HF
3037+
3038+ 20 RGNVOL=TWONDM
3039+ DO 30 J = 1,N
3040+ RGNVOL=RGNVOL*WTH(J)
3041+ 30 Z(J)=CTR(J)
3042+ SUM1=F(N,Z)
3043+
3044+ DIFMAX=0
3045+ SUM2=0
3046+ SUM3=0
3047+ DO 40 J = 1,N
3048+ Z(J)=CTR(J)-XL2*WTH(J)
3049+ F2=F(N,Z)
3050+ Z(J)=CTR(J)+XL2*WTH(J)
3051+ F2=F2+F(N,Z)
3052+ WTHL(J)=XL4*WTH(J)
3053+ Z(J)=CTR(J)-WTHL(J)
3054+ F3=F(N,Z)
3055+ Z(J)=CTR(J)+WTHL(J)
3056+ F3=F3+F(N,Z)
3057+ SUM2=SUM2+F2
3058+ SUM3=SUM3+F3
3059+ DIF=ABS(7*F2-F3-12*SUM1)
3060+ DIFMAX=MAX(DIF,DIFMAX)
3061+ IF(DIFMAX .EQ. DIF) IDVAXN=J
3062+ 40 Z(J)=CTR(J)
3063+
3064+ SUM4=0
3065+ DO 70 J = 2,N
3066+ J1=J-1
3067+ DO 60 K = J,N
3068+ DO 50 L = 1,2
3069+ WTHL(J1)=-WTHL(J1)
3070+ Z(J1)=CTR(J1)+WTHL(J1)
3071+ DO 50 M = 1,2
3072+ WTHL(K)=-WTHL(K)
3073+ Z(K)=CTR(K)+WTHL(K)
3074+ 50 SUM4=SUM4+F(N,Z)
3075+ 60 Z(K)=CTR(K)
3076+ 70 Z(J1)=CTR(J1)
3077+
3078+ SUM5=0
3079+ DO 80 J = 1,N
3080+ WTHL(J)=-XL5*WTH(J)
3081+ 80 Z(J)=CTR(J)+WTHL(J)
3082+ 90 SUM5=SUM5+F(N,Z)
3083+ DO 100 J = 1,N
3084+ WTHL(J)=-WTHL(J)
3085+ Z(J)=CTR(J)+WTHL(J)
3086+ IF(WTHL(J) .GT. 0) GO TO 90
3087+ 100 CONTINUE
3088+
3089+ RGNCMP=RGNVOL*(WP(N,1)*SUM1+WP2*SUM2+WP(N,3)*SUM3+WP4*SUM4)
3090+ RGNVAL=W(N,1)*SUM1+W2*SUM2+W(N,3)*SUM3+W4*SUM4+W(N,5)*SUM5
3091+ RGNVAL=RGNVOL*RGNVAL
3092+ RGNERR=ABS(RGNVAL-RGNCMP)
3093+ RESULT=RESULT+RGNVAL
3094+ ABSERR=ABSERR+RGNERR
3095+ IFNCLS=IFNCLS+IRLCLS
3096+
3097+ IF(LDV) THEN
3098+ 110 ISBTMP=2*ISBRGN
3099+ IF(ISBTMP .GT. ISBRGS) GO TO 160
3100+ IF(ISBTMP .LT. ISBRGS) THEN
3101+ ISBTPP=ISBTMP+IRGNST
3102+ IF(WK(ISBTMP) .LT. WK(ISBTPP)) ISBTMP=ISBTPP
3103+ ENDIF
3104+ IF(RGNERR .GE. WK(ISBTMP)) GO TO 160
3105+ DO 130 K = 0,IRGNST-1
3106+ 130 WK(ISBRGN-K)=WK(ISBTMP-K)
3107+ ISBRGN=ISBTMP
3108+ GO TO 110
3109+ ENDIF
3110+ 140 ISBTMP=(ISBRGN/(2*IRGNST))*IRGNST
3111+ IF(ISBTMP .GE. IRGNST .AND. RGNERR .GT. WK(ISBTMP)) THEN
3112+ DO 150 K = 0,IRGNST-1
3113+ 150 WK(ISBRGN-K)=WK(ISBTMP-K)
3114+ ISBRGN=ISBTMP
3115+ GO TO 140
3116+ ENDIF
3117+
3118+ 160 WK(ISBRGN)=RGNERR
3119+ WK(ISBRGN-1)=RGNVAL
3120+ WK(ISBRGN-2)=IDVAXN
3121+ DO 170 J = 1,N
3122+ ISBTMP=ISBRGN-2*J-2
3123+ WK(ISBTMP+1)=CTR(J)
3124+ 170 WK(ISBTMP)=WTH(J)
3125+ IF(LDV) THEN
3126+ LDV=.FALSE.
3127+ CTR(IDVAX0)=CTR(IDVAX0)+2*WTH(IDVAX0)
3128+ ISBRGS=ISBRGS+IRGNST
3129+ ISBRGN=ISBRGS
3130+ GO TO 20
3131+ ENDIF
3132+ RELERR=ABSERR/ABS(RESULT)
3133+ IF(ISBRGS+IRGNST .GT. IWK) IFAIL=2
3134+ IF(IFNCLS+2*IRLCLS .GT. MAXPTS) IFAIL=1
3135+ IF(RELERR .LT. EPS .AND. IFNCLS .GE. MINPTS) IFAIL=0
3136+ IF(IFAIL .EQ. 3) THEN
3137+ LDV=.TRUE.
3138+ ISBRGN=IRGNST
3139+ ABSERR=ABSERR-WK(ISBRGN)
3140+ RESULT=RESULT-WK(ISBRGN-1)
3141+ IDVAX0=WK(ISBRGN-2)
3142+ DO 190 J = 1,N
3143+ ISBTMP=ISBRGN-2*J-2
3144+ CTR(J)=WK(ISBTMP+1)
3145+ 190 WTH(J)=WK(ISBTMP)
3146+ WTH(IDVAX0)=HF*WTH(IDVAX0)
3147+ CTR(IDVAX0)=CTR(IDVAX0)-WTH(IDVAX0)
3148+ GO TO 20
3149+ ENDIF
3150+ NFNEVL=IFNCLS
3151+ RETURN
3152+ END
3153
3154=== added directory 'Template/NLO/Source/DHELAS'
3155=== added file 'Template/NLO/Source/DHELAS/.keepthisdir'
3156=== added directory 'Template/NLO/Source/MODEL'
3157=== added file 'Template/NLO/Source/MODEL/.keepme'
3158=== added directory 'Template/NLO/Source/PDF'
3159=== added file 'Template/NLO/Source/PDF/Ctq4Fn.f'
3160--- Template/NLO/Source/PDF/Ctq4Fn.f 1970-01-01 00:00:00 +0000
3161+++ Template/NLO/Source/PDF/Ctq4Fn.f 2012-09-28 12:29:27 +0000
3162@@ -0,0 +1,122 @@
3163+C*****Butchered by RKE to remove polint and readtbl which are common to
3164+C*****Ctq4Fn and Ctq5Pdf
3165+
3166+C============================================================================
3167+C CTEQ Parton Distribution Functions: Version 4
3168+C June 21, 1996
3169+C
3170+C By: H.L. Lai, J. Huston, S. Kuhlmann, F. Olness, J. Owens, D. Soper
3171+C W.K. Tung, H. Weerts
3172+C Ref: MSUHEP-60426, CTEQ-604, e-Print Archive: hep-ph/9606399
3173+C
3174+C This package contains 9 sets of CTEQ4 PDF's. Details are:
3175+C ---------------------------------------------------------------------------
3176+C Iset PDF Description Alpha_s(Mz) Q0(GeV) Table_File
3177+C ---------------------------------------------------------------------------
3178+C 1 CTEQ4M Standard MSbar scheme 0.116 1.6 cteq4m.tbl
3179+C 2 CTEQ4D Standard DIS scheme 0.116 1.6 cteq4d.tbl
3180+C 3 CTEQ4L Leading Order 0.116 1.6 cteq4l.tbl
3181+C 4 CTEQ4A1 Alpha_s series 0.110 1.6 cteq4a1.tbl
3182+C 5 CTEQ4A2 Alpha_s series 0.113 1.6 cteq4a2.tbl
3183+C 6 CTEQ4A3 same as CTEQ4M 0.116 1.6 cteq4m.tbl
3184+C 7 CTEQ4A4 Alpha_s series 0.119 1.6 cteq4a4.tbl
3185+C 8 CTEQ4A5 Alpha_s series 0.122 1.6 cteq4a5.tbl
3186+C 9 CTEQ4HJ High Jet 0.116 1.6 cteq4hj.tbl
3187+C 10 CTEQ4LQ Low Q0 0.114 0.7 cteq4lq.tbl
3188+C ---------------------------------------------------------------------------
3189+C
3190+C The available applied range is 10^-5 < x < 1 and 1.6 < Q < 10,000 (GeV)
3191+C except CTEQ4LQ for which Q starts at a lower value of 0.7 GeV.
3192+C The Table_Files are assumed to be in the working directory.
3193+C
3194+C The function Ctq4Fn (Iset, Iparton, X, Q)
3195+C returns the parton distribution inside the proton for parton [Iparton]
3196+C at [X] Bjorken_X and scale [Q] (GeV) in PDF set [Iset].
3197+C Iparton is the parton label (5, 4, 3, 2, 1, 0, -1, ......, -5)
3198+C for (b, c, s, d, u, g, u_bar, ..., b_bar)
3199+C
3200+C For detailed information on the parameters used, e.q. quark masses,
3201+C QCD Lambda, ... etc., see info lines at the beginning of the
3202+C Table_Files.
3203+
3204+C These programs, as provided, are in double precision. By removing the
3205+C "Implicit Double Precision" lines, they can also be run in single
3206+C precision.
3207+C
3208+C If you have detailed questions concerning these CTEQ4 distributions,
3209+C or if you find problems/bugs using this package, direct inquires to
3210+C Hung-Liang Lai(Lai_H@pa.msu.edu) or Wu-Ki Tung(Tung@pa.msu.edu).
3211+C
3212+C===========================================================================
3213+
3214+ Function Ctq4Fn (Iset, Iparton, X, Q)
3215+ Implicit Double Precision (A-H,O-Z)
3216+ Character Flnm(10)*11,TableFile*40
3217+
3218+ Common
3219+ > / CtqPar2 / Nx, Nt, NfMx
3220+ > / QCDtable / Alambda, Nfl, Iorder
3221+ Data (Flnm(I), I=1,10)
3222+ > / 'cteq4m.tbl ', 'cteq4d.tbl ', 'cteq4l.tbl '
3223+ > , 'cteq4a1.tbl', 'cteq4a2.tbl', 'cteq4m.tbl ', 'cteq4a4.tbl'
3224+ > , 'cteq4a5.tbl', 'cteq4hj.tbl', 'cteq4lq.tbl' /
3225+ Data Isetold, Isetmin, Isetmax / -987, 1, 10 /
3226+ save
3227+
3228+C If data file not initialized, do so.
3229+ If(Iset.ne.Isetold) then
3230+ If (Iset.lt.Isetmin .or. Iset.gt.Isetmax) Then
3231+ Print *, 'Invalid Iset number in Ctq4Fn :', Iset
3232+ Stop
3233+ Endif
3234+ IU= NextUt()
3235+c Open(IU, File='Pdfdata/'//Flnm(Iset), Status='OLD', Err=100)
3236+ TableFile=Flnm(Iset)
3237+ call OpenData(TableFile)
3238+c write (*,*) TableFile
3239+c write(*,*) 'iu',iu
3240+ Call ReadTbl (IU)
3241+ Close (IU)
3242+ Isetold=Iset
3243+ Endif
3244+
3245+ If (X .lt. 0D0 .or. X .gt. 1D0) Then
3246+ Print *, 'X out of range in Ctq4Fn: ', X
3247+ Stop
3248+ Endif
3249+ If (Q .lt. Alambda) Then
3250+ Print *, 'Q out of range in Ctq4Fn: ', Q
3251+ Stop
3252+ Endif
3253+ If (Iparton .lt. -NfMx .or. Iparton .gt. NfMx) Then
3254+ Print *, 'Iparton out of range in Ctq4Fn: ', Iparton
3255+ Stop
3256+ Endif
3257+
3258+ Ctq4Fn = PartonX (Iparton, X, Q)
3259+ if(Ctq4Fn.lt.0.D0) Ctq4Fn = 0.D0
3260+
3261+ Return
3262+
3263+ 100 Print *, ' Data file ', Flnm(Iset), ' cannot be opened '
3264+ >//'in Ctq4Fn!!'
3265+ Stop
3266+C ********************
3267+ End
3268+
3269+ Function NextUt()
3270+C Returns an unallocated FORTRAN i/o unit.
3271+ Logical EX
3272+C
3273+ Do 10 N = 10, 300
3274+ INQUIRE (UNIT=N, OPENED=EX)
3275+ If (.NOT. EX) then
3276+ NextUt = N
3277+ Return
3278+ Endif
3279+ 10 Continue
3280+ Stop ' There is no available I/O unit. '
3281+C *************************
3282+ End
3283+C
3284+
3285
3286=== added file 'Template/NLO/Source/PDF/Ctq5Par.f'
3287--- Template/NLO/Source/PDF/Ctq5Par.f 1970-01-01 00:00:00 +0000
3288+++ Template/NLO/Source/PDF/Ctq5Par.f 2012-09-28 12:29:27 +0000
3289@@ -0,0 +1,711 @@
3290+C CTEQ5M1 and CTEQ5L Parton Distribution Functions in Parametrized Form
3291+C
3292+C September 15, 1999
3293+C
3294+C Ref: "GLOBAL QCD ANALYSIS OF PARTON STRUCTURE OF THE NUCLEON:
3295+C CTEQ5 PPARTON DISTRIBUTIONS"
3296+C hep-ph/9903282
3297+C
3298+C The CTEQ5M1 set given here is an updated version of the original CTEQ5M
3299+C set posted, in the table version, on the Web page of CTEQ.
3300+C The differences between CTEQ5M and CTEQ5M1 are insignificant for almost
3301+C all applications.
3302+C The improvement is in the QCD evolution which is now more accurate, and
3303+C which agrees completely with the benchmark work of the HERA 96/97 Workshop.
3304+
3305+C The differences between the parametrized and the corresponding table ver-
3306+C sions (on which it is based) are of similar order as between the two version.
3307+C
3308+C!! Because accurate parametrizations over a wide range of (x,Q) is hard to
3309+C obtain, only the most widely used sets CTEQ5M and CTEQ5L are available
3310+C in parametrized form for now.
3311+
3312+C These parametrizations were obtained by Jon Pumplin.
3313+C
3314+C ******************************
3315+C Iset PDF Description Alpha_s(Mz) Lam4 Lam5
3316+C ---------------------------------------------------------------------------
3317+C 1 CTEQ5M1 Standard NLO MSbar scheme 0.118 326 226
3318+C 3 CTEQ5L Leading Order 0.127 192 146
3319+C ---------------------------------------------------------------------------
3320+C Note the Qcd-lambda values given for CTEQ5L is for the leading order
3321+C form of Alpha_s!! Alpha_s(Mz) gives the absolute calibration.
3322+
3323+C The two Iset value are adopted to agree with the standard table versions.
3324+
3325+C The following user-callable routines are provided:
3326+C
3327+C FUNCTION Ctq5Pd (Iset, Iprtn, X, Q, Irt)
3328+C returns the PROBABILITY density for a GIVEN flavor;
3329+C
3330+C FUNCTION Ctq5df (Iset, Iprtn, X, Q, Irt)
3331+C returns the MOMENTUM density of a GIVEN valence or sea distribution.
3332+C
3333+C SUBROUTINE Ctq5Pds(Iset, Pdf, X, Q, Irt)
3334+C returns an array of MOMENTUM densities for ALL flavors;
3335+C****************************************************************************
3336+C Added by Tim Stelzer
3337+c subroutine pftopdg(x,Q,pdf)
3338+c subroutine pdfset(parm,val)
3339+c
3340+c
3341+C
3342+C The arguments of these routines are as follows:
3343+C
3344+C Iset is the set number: 1 for CTEQ5M1 or 3 for CTEQ5L
3345+C
3346+C Iprtn is the parton label (6, 5, 4, 3, 2, 1, 0, -1, ......, -6)
3347+C for (t, b, c, s, d, u, g, u_bar, ..., t_bar)
3348+C *** WARNING: We use the parton label 2 as D-quark and 1 as U-quark,
3349+C which might be different from your labels.
3350+C
3351+C X, Q are the usual x, Q;
3352+C
3353+C Irt is an error code: 0 if there was no error; 1 or more if (x,q) was
3354+C outside the range of validity of the parametrization.
3355+C
3356+C Range of validity:
3357+C
3358+C The range of (x, Q) covered by this parametrization of the QCD evolved
3359+C parton distributions is 1E-6 < x < 1 ; 1.1 GeV < Q < 10 TeV. Of course,
3360+C the PDF's are constrained by data only in a subset of that region; and
3361+C the assumed DGLAP evolution is unlikely to be valid for all of it either.
3362+C
3363+C The range of (x, Q) used in the CTEQ5 round of global analysis is
3364+C approximately 0.01 < x < 0.75 ; and 4 GeV^2 < Q^2 < 400 GeV^2 for
3365+C fixed target experiments; 0.0001 < x < 0.3 from HERA data; and
3366+C Q^2 up to 40,000 GeV^2 from Tevatron inclusive Jet data.
3367+C
3368+C DOUBLE PRECISION is used throughout in these routines, but conversion to
3369+C SINGLE PRECISION is possible by removing the Implicit Double Precision statements.
3370+C
3371+C **************************************************************************
3372+
3373+
3374+C ********************************************************
3375+ FUNCTION CTQ5PD(ISET, IPARTON, X, Q, IRT)
3376+C ********************************************************
3377+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
3378+
3379+c if called at a point (x,q) that is outside the region that was
3380+c actually parametrized, return a value of 0, and set the error code IRT=1.
3381+c The user can remove the following IF statement to receive instead an
3382+c extrapolated value, which may be wildly unphysical.
3383+ if((x .lt. 1.e-6). or. (x .gt. 1.)
3384+ & .or. (q .lt. .99) .or. (q .gt. 10000.)) then
3385+ ctq5pd = 0.d0
3386+ irt = 1
3387+ return
3388+ endif
3389+
3390+ irt = 0
3391+ if(iset .eq. 3) then
3392+ ctq5pd = ctq5L(iparton,x,q)
3393+ elseif(iset .eq. 1) then
3394+ ctq5pd = ctq5Mi(iparton,x,q)
3395+ else
3396+ print *,'iset=',iset,' has not been parametrized.'
3397+ print '(/A)', 'Use the interpolation-table version instead.'
3398+ stop
3399+ endif
3400+
3401+ return
3402+ end
3403+
3404+C ********************************************************
3405+ FUNCTION CTQ5DF(ISET, IFL, X, Q, IRT)
3406+C ********************************************************
3407+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
3408+
3409+ CTQ5DF = X * CTQ5PD(ISET, IPARTON, X, Q, IRT)
3410+
3411+ RETURN
3412+ END
3413+
3414+C ********************************************************
3415+ SUBROUTINE CTQ5PDS(ISET, PDF, X, Q, IRT)
3416+C ********************************************************
3417+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
3418+ DIMENSION PDF (-6:6)
3419+
3420+ IRT = 0
3421+
3422+ DO IFL= -6,2
3423+ PDF(IFL) = CTQ5PD(ISET,IFL,X,Q,IRT1)
3424+ IRT = IRT + IRT1
3425+
3426+ IF (IFL .LE. -3) THEN
3427+ PDF(-IFL) = PDF(IFL)
3428+ ENDIF
3429+
3430+ ENDDO
3431+
3432+ RETURN
3433+ END
3434+
3435+c --------------------------------------------------------------------------
3436+ double precision function ctq5MI(ifl,x,q)
3437+c Parametrization of cteq5MI parton distribution functions (J. Pumplin 9/99).
3438+c ifl: 1=u,2=d,3=s,4=c,5=b;0=gluon;-1=ubar,-2=dbar,-3=sbar,-4=cbar,-5=bbar.
3439+c --------------------------------------------------------------------------
3440+ implicit double precision (a-h,o-z)
3441+ integer ifl
3442+
3443+ ii = ifl
3444+ if(ii .gt. 2) then
3445+ ii = -ii
3446+ endif
3447+
3448+ if(ii .eq. -1) then
3449+ sum = faux5MI(-1,x,q)
3450+ ratio = faux5MI(-2,x,q)
3451+ ctq5MI = sum/(1.d0 + ratio)
3452+
3453+ elseif(ii .eq. -2) then
3454+ sum = faux5MI(-1,x,q)
3455+ ratio = faux5MI(-2,x,q)
3456+ ctq5MI = sum*ratio/(1.d0 + ratio)
3457+
3458+ elseif(ii .ge. -5) then
3459+ ctq5MI = faux5MI(ii,x,q)
3460+
3461+ else
3462+ ctq5MI = 0.d0
3463+
3464+ endif
3465+
3466+ return
3467+ end
3468+
3469+c ---------------------------------------------------------------------
3470+ double precision function faux5MI(ifl,x,q)
3471+c auxiliary function for parametrization of CTEQ5MI (J. Pumplin 9/99).
3472+c ---------------------------------------------------------------------
3473+ implicit double precision (a-h,o-z)
3474+ integer ifl
3475+
3476+ parameter (nex=8, nlf=2)
3477+ dimension am(0:nex,0:nlf,-5:2)
3478+ dimension alfvec(-5:2), qmavec(-5:2)
3479+ dimension mexvec(-5:2), mlfvec(-5:2)
3480+ dimension ut1vec(-5:2), ut2vec(-5:2)
3481+ dimension af(0:nex)
3482+
3483+ data mexvec( 2) / 8 /
3484+ data mlfvec( 2) / 2 /
3485+ data ut1vec( 2) / 0.5141718E+01 /
3486+ data ut2vec( 2) / -0.1346944E+01 /
3487+ data alfvec( 2) / 0.5260555E+00 /
3488+ data qmavec( 2) / 0.0000000E+00 /
3489+ data (am( 0,k, 2),k=0, 2)
3490+ & / 0.4289071E+01, -0.2536870E+01, -0.1259948E+01 /
3491+ data (am( 1,k, 2),k=0, 2)
3492+ & / 0.9839410E+00, 0.4168426E-01, -0.5018952E-01 /
3493+ data (am( 2,k, 2),k=0, 2)
3494+ & / -0.1651961E+02, 0.9246261E+01, 0.5996400E+01 /
3495+ data (am( 3,k, 2),k=0, 2)
3496+ & / -0.2077936E+02, 0.9786469E+01, 0.7656465E+01 /
3497+ data (am( 4,k, 2),k=0, 2)
3498+ & / 0.3054926E+02, 0.1889536E+01, 0.1380541E+01 /
3499+ data (am( 5,k, 2),k=0, 2)
3500+ & / 0.3084695E+02, -0.1212303E+02, -0.1053551E+02 /
3501+ data (am( 6,k, 2),k=0, 2)
3502+ & / -0.1426778E+02, 0.6239537E+01, 0.5254819E+01 /
3503+ data (am( 7,k, 2),k=0, 2)
3504+ & / -0.1909811E+02, 0.3695678E+01, 0.5495729E+01 /
3505+ data (am( 8,k, 2),k=0, 2)
3506+ & / 0.1889751E-01, 0.5027193E-02, 0.6624896E-03 /
3507+
3508+ data mexvec( 1) / 8 /
3509+ data mlfvec( 1) / 2 /
3510+ data ut1vec( 1) / 0.4138426E+01 /
3511+ data ut2vec( 1) / -0.3221374E+01 /
3512+ data alfvec( 1) / 0.4960962E+00 /
3513+ data qmavec( 1) / 0.0000000E+00 /
3514+ data (am( 0,k, 1),k=0, 2)
3515+ & / 0.1332497E+01, -0.3703718E+00, 0.1288638E+00 /
3516+ data (am( 1,k, 1),k=0, 2)
3517+ & / 0.7544687E+00, 0.3255075E-01, -0.4706680E-01 /
3518+ data (am( 2,k, 1),k=0, 2)
3519+ & / -0.7638814E+00, 0.5008313E+00, -0.9237374E-01 /
3520+ data (am( 3,k, 1),k=0, 2)
3521+ & / -0.3689889E+00, -0.1055098E+01, -0.4645065E+00 /
3522+ data (am( 4,k, 1),k=0, 2)
3523+ & / 0.3991610E+02, 0.1979881E+01, 0.1775814E+01 /
3524+ data (am( 5,k, 1),k=0, 2)
3525+ & / 0.6201080E+01, 0.2046288E+01, 0.3804571E+00 /
3526+ data (am( 6,k, 1),k=0, 2)
3527+ & / -0.8027900E+00, -0.7011688E+00, -0.8049612E+00 /
3528+ data (am( 7,k, 1),k=0, 2)
3529+ & / -0.8631305E+01, -0.3981200E+01, 0.6970153E+00 /
3530+ data (am( 8,k, 1),k=0, 2)
3531+ & / 0.2371230E-01, 0.5372683E-02, 0.1118701E-02 /
3532+
3533+ data mexvec( 0) / 8 /
3534+ data mlfvec( 0) / 2 /
3535+ data ut1vec( 0) / -0.1026789E+01 /
3536+ data ut2vec( 0) / -0.9051707E+01 /
3537+ data alfvec( 0) / 0.9462977E+00 /
3538+ data qmavec( 0) / 0.0000000E+00 /
3539+ data (am( 0,k, 0),k=0, 2)
3540+ & / 0.1191990E+03, -0.8548739E+00, -0.1963040E+01 /
3541+ data (am( 1,k, 0),k=0, 2)
3542+ & / -0.9449972E+02, 0.1074771E+01, 0.2056055E+01 /
3543+ data (am( 2,k, 0),k=0, 2)
3544+ & / 0.3701064E+01, -0.1167947E-02, 0.1933573E+00 /
3545+ data (am( 3,k, 0),k=0, 2)
3546+ & / 0.1171345E+03, -0.1064540E+01, -0.1875312E+01 /
3547+ data (am( 4,k, 0),k=0, 2)
3548+ & / -0.1014453E+03, -0.5707427E+00, 0.4511242E-01 /
3549+ data (am( 5,k, 0),k=0, 2)
3550+ & / 0.6365168E+01, 0.1275354E+01, -0.4964081E+00 /
3551+ data (am( 6,k, 0),k=0, 2)
3552+ & / -0.3370693E+01, -0.1122020E+01, 0.5947751E-01 /
3553+ data (am( 7,k, 0),k=0, 2)
3554+ & / -0.5327270E+01, -0.9293556E+00, 0.6629940E+00 /
3555+ data (am( 8,k, 0),k=0, 2)
3556+ & / 0.2437513E-01, 0.1600939E-02, 0.6855336E-03 /
3557+
3558+ data mexvec(-1) / 8 /
3559+ data mlfvec(-1) / 2 /
3560+ data ut1vec(-1) / 0.5243571E+01 /
3561+ data ut2vec(-1) / -0.2870513E+01 /
3562+ data alfvec(-1) / 0.6701448E+00 /
3563+ data qmavec(-1) / 0.0000000E+00 /
3564+ data (am( 0,k,-1),k=0, 2)
3565+ & / 0.2428863E+02, 0.1907035E+01, -0.4606457E+00 /
3566+ data (am( 1,k,-1),k=0, 2)
3567+ & / 0.2006810E+01, -0.1265915E+00, 0.7153556E-02 /
3568+ data (am( 2,k,-1),k=0, 2)
3569+ & / -0.1884546E+02, -0.2339471E+01, 0.5740679E+01 /
3570+ data (am( 3,k,-1),k=0, 2)
3571+ & / -0.2527892E+02, -0.2044124E+01, 0.1280470E+02 /
3572+ data (am( 4,k,-1),k=0, 2)
3573+ & / -0.1013824E+03, -0.1594199E+01, 0.2216401E+00 /
3574+ data (am( 5,k,-1),k=0, 2)
3575+ & / 0.8070930E+02, 0.1792072E+01, -0.2164364E+02 /
3576+ data (am( 6,k,-1),k=0, 2)
3577+ & / -0.4641050E+02, 0.1977338E+00, 0.1273014E+02 /
3578+ data (am( 7,k,-1),k=0, 2)
3579+ & / -0.3910568E+02, 0.1719632E+01, 0.1086525E+02 /
3580+ data (am( 8,k,-1),k=0, 2)
3581+ & / -0.1185496E+01, -0.1905847E+00, -0.8744118E-03 /
3582+
3583+ data mexvec(-2) / 7 /
3584+ data mlfvec(-2) / 2 /
3585+ data ut1vec(-2) / 0.4782210E+01 /
3586+ data ut2vec(-2) / -0.1976856E+02 /
3587+ data alfvec(-2) / 0.7558374E+00 /
3588+ data qmavec(-2) / 0.0000000E+00 /
3589+ data (am( 0,k,-2),k=0, 2)
3590+ & / -0.6216935E+00, 0.2369963E+00, -0.7909949E-02 /
3591+ data (am( 1,k,-2),k=0, 2)
3592+ & / 0.1245440E+01, -0.1031510E+00, 0.4916523E-02 /
3593+ data (am( 2,k,-2),k=0, 2)
3594+ & / -0.7060824E+01, -0.3875283E-01, 0.1784981E+00 /
3595+ data (am( 3,k,-2),k=0, 2)
3596+ & / -0.7430595E+01, 0.1964572E+00, -0.1284999E+00 /
3597+ data (am( 4,k,-2),k=0, 2)
3598+ & / -0.6897810E+01, 0.2620543E+01, 0.8012553E-02 /
3599+ data (am( 5,k,-2),k=0, 2)
3600+ & / 0.1507713E+02, 0.2340307E-01, 0.2482535E+01 /
3601+ data (am( 6,k,-2),k=0, 2)
3602+ & / -0.1815341E+01, -0.1538698E+01, -0.2014208E+01 /
3603+ data (am( 7,k,-2),k=0, 2)
3604+ & / -0.2571932E+02, 0.2903941E+00, -0.2848206E+01 /
3605+
3606+ data mexvec(-3) / 7 /
3607+ data mlfvec(-3) / 2 /
3608+ data ut1vec(-3) / 0.4518239E+01 /
3609+ data ut2vec(-3) / -0.2690590E+01 /
3610+ data alfvec(-3) / 0.6124079E+00 /
3611+ data qmavec(-3) / 0.0000000E+00 /
3612+ data (am( 0,k,-3),k=0, 2)
3613+ & / -0.2734458E+01, -0.7245673E+00, -0.6351374E+00 /
3614+ data (am( 1,k,-3),k=0, 2)
3615+ & / 0.2927174E+01, 0.4822709E+00, -0.1088787E-01 /
3616+ data (am( 2,k,-3),k=0, 2)
3617+ & / -0.1771017E+02, -0.1416635E+01, 0.8467622E+01 /
3618+ data (am( 3,k,-3),k=0, 2)
3619+ & / -0.4972782E+02, -0.3348547E+01, 0.1767061E+02 /
3620+ data (am( 4,k,-3),k=0, 2)
3621+ & / -0.7102770E+01, -0.3205337E+01, 0.4101704E+00 /
3622+ data (am( 5,k,-3),k=0, 2)
3623+ & / 0.7169698E+02, -0.2205985E+01, -0.2463931E+02 /
3624+ data (am( 6,k,-3),k=0, 2)
3625+ & / -0.4090347E+02, 0.2103486E+01, 0.1416507E+02 /
3626+ data (am( 7,k,-3),k=0, 2)
3627+ & / -0.2952639E+02, 0.5376136E+01, 0.7825585E+01 /
3628+
3629+ data mexvec(-4) / 7 /
3630+ data mlfvec(-4) / 2 /
3631+ data ut1vec(-4) / 0.2783230E+01 /
3632+ data ut2vec(-4) / -0.1746328E+01 /
3633+ data alfvec(-4) / 0.1115653E+01 /
3634+ data qmavec(-4) / 0.1300000E+01 /
3635+ data (am( 0,k,-4),k=0, 2)
3636+ & / -0.1743872E+01, -0.1128921E+01, -0.2841969E+00 /
3637+ data (am( 1,k,-4),k=0, 2)
3638+ & / 0.3345755E+01, 0.3187765E+00, 0.1378124E+00 /
3639+ data (am( 2,k,-4),k=0, 2)
3640+ & / -0.2037615E+02, 0.4121687E+01, 0.2236520E+00 /
3641+ data (am( 3,k,-4),k=0, 2)
3642+ & / -0.4703104E+02, 0.5353087E+01, -0.1455347E+01 /
3643+ data (am( 4,k,-4),k=0, 2)
3644+ & / -0.1060230E+02, -0.1551122E+01, -0.1078863E+01 /
3645+ data (am( 5,k,-4),k=0, 2)
3646+ & / 0.5088892E+02, -0.8197304E+01, 0.8083451E+01 /
3647+ data (am( 6,k,-4),k=0, 2)
3648+ & / -0.2819070E+02, 0.4554086E+01, -0.5890995E+01 /
3649+ data (am( 7,k,-4),k=0, 2)
3650+ & / -0.1098238E+02, 0.2590096E+01, -0.8062879E+01 /
3651+
3652+ data mexvec(-5) / 6 /
3653+ data mlfvec(-5) / 2 /
3654+ data ut1vec(-5) / 0.1619654E+02 /
3655+ data ut2vec(-5) / -0.3367346E+01 /
3656+ data alfvec(-5) / 0.5109891E-02 /
3657+ data qmavec(-5) / 0.4500000E+01 /
3658+ data (am( 0,k,-5),k=0, 2)
3659+ & / -0.6800138E+01, 0.2493627E+01, -0.1075724E+01 /
3660+ data (am( 1,k,-5),k=0, 2)
3661+ & / 0.3036555E+01, 0.3324733E+00, 0.2008298E+00 /
3662+ data (am( 2,k,-5),k=0, 2)
3663+ & / -0.5203879E+01, -0.8493476E+01, -0.4523208E+01 /
3664+ data (am( 3,k,-5),k=0, 2)
3665+ & / -0.1524239E+01, -0.3411912E+01, -0.1771867E+02 /
3666+ data (am( 4,k,-5),k=0, 2)
3667+ & / -0.1099444E+02, 0.1320930E+01, -0.2353831E+01 /
3668+ data (am( 5,k,-5),k=0, 2)
3669+ & / 0.1699299E+02, -0.3565802E+02, 0.3566872E+02 /
3670+ data (am( 6,k,-5),k=0, 2)
3671+ & / -0.1465793E+02, 0.2703365E+02, -0.2176372E+02 /
3672+
3673+ if(q .le. qmavec(ifl)) then
3674+ faux5MI = 0.d0
3675+ return
3676+ endif
3677+
3678+ if(x .ge. 1.d0) then
3679+ faux5MI = 0.d0
3680+ return
3681+ endif
3682+
3683+ tmp = log(q/alfvec(ifl))
3684+ if(tmp .le. 0.d0) then
3685+ faux5MI = 0.d0
3686+ return
3687+ endif
3688+
3689+ sb = log(tmp)
3690+ sb1 = sb - 1.2d0
3691+ sb2 = sb1*sb1
3692+
3693+ do i = 0, nex
3694+ af(i) = 0.d0
3695+ sbx = 1.d0
3696+ do k = 0, mlfvec(ifl)
3697+ af(i) = af(i) + sbx*am(i,k,ifl)
3698+ sbx = sb1*sbx
3699+ enddo
3700+ enddo
3701+
3702+ y = -log(x)
3703+ u = log(x/0.00001d0)
3704+
3705+ part1 = af(1)*y**(1.d0+0.01d0*af(4))*(1.d0+ af(8)*u)
3706+ part2 = af(0)*(1.d0 - x) + af(3)*x
3707+ part3 = x*(1.d0-x)*(af(5)+af(6)*(1.d0-x)+af(7)*x*(1.d0-x))
3708+ part4 = ut1vec(ifl)*log(1.d0-x) +
3709+ & AF(2)*log(1.d0+exp(ut2vec(ifl))-x)
3710+
3711+ faux5MI = exp(log(x) + part1 + part2 + part3 + part4)
3712+
3713+c include threshold factor...
3714+ faux5MI = faux5MI * (1.d0 - qmavec(ifl)/q)
3715+
3716+ return
3717+ end
3718+c --------------------------------------------------------------------------
3719+ double precision function ctq5L(ifl,x,q)
3720+c Parametrization of cteq5L parton distribution functions (J. Pumplin 9/99).
3721+c ifl: 1=u,2=d,3=s,4=c,5=b;0=gluon;-1=ubar,-2=dbar,-3=sbar,-4=cbar,-5=bbar.
3722+c --------------------------------------------------------------------------
3723+ implicit double precision (a-h,o-z)
3724+ integer ifl
3725+
3726+ ii = ifl
3727+ if(ii .gt. 2) then
3728+ ii = -ii
3729+ endif
3730+
3731+ if(ii .eq. -1) then
3732+ sum = faux5L(-1,x,q)
3733+ ratio = faux5L(-2,x,q)
3734+ ctq5L = sum/(1.d0 + ratio)
3735+
3736+ elseif(ii .eq. -2) then
3737+ sum = faux5L(-1,x,q)
3738+ ratio = faux5L(-2,x,q)
3739+ ctq5L = sum*ratio/(1.d0 + ratio)
3740+
3741+ elseif(ii .ge. -5) then
3742+ ctq5L = faux5L(ii,x,q)
3743+
3744+ else
3745+ ctq5L = 0.d0
3746+
3747+ endif
3748+
3749+ return
3750+ end
3751+
3752+c ---------------------------------------------------------------------
3753+ double precision function faux5L(ifl,x,q)
3754+c auxiliary function for parametrization of CTEQ5L (J. Pumplin 9/99).
3755+c ---------------------------------------------------------------------
3756+ implicit double precision (a-h,o-z)
3757+ integer ifl
3758+
3759+ parameter (nex=8, nlf=2)
3760+ dimension am(0:nex,0:nlf,-5:2)
3761+ dimension alfvec(-5:2), qmavec(-5:2)
3762+ dimension mexvec(-5:2), mlfvec(-5:2)
3763+ dimension ut1vec(-5:2), ut2vec(-5:2)
3764+ dimension af(0:nex)
3765+
3766+ data mexvec( 2) / 8 /
3767+ data mlfvec( 2) / 2 /
3768+ data ut1vec( 2) / 0.4971265E+01 /
3769+ data ut2vec( 2) / -0.1105128E+01 /
3770+ data alfvec( 2) / 0.2987216E+00 /
3771+ data qmavec( 2) / 0.0000000E+00 /
3772+ data (am( 0,k, 2),k=0, 2)
3773+ & / 0.5292616E+01, -0.2751910E+01, -0.2488990E+01 /
3774+ data (am( 1,k, 2),k=0, 2)
3775+ & / 0.9714424E+00, 0.1011827E-01, -0.1023660E-01 /
3776+ data (am( 2,k, 2),k=0, 2)
3777+ & / -0.1651006E+02, 0.7959721E+01, 0.8810563E+01 /
3778+ data (am( 3,k, 2),k=0, 2)
3779+ & / -0.1643394E+02, 0.5892854E+01, 0.9348874E+01 /
3780+ data (am( 4,k, 2),k=0, 2)
3781+ & / 0.3067422E+02, 0.4235796E+01, -0.5112136E+00 /
3782+ data (am( 5,k, 2),k=0, 2)
3783+ & / 0.2352526E+02, -0.5305168E+01, -0.1169174E+02 /
3784+ data (am( 6,k, 2),k=0, 2)
3785+ & / -0.1095451E+02, 0.3006577E+01, 0.5638136E+01 /
3786+ data (am( 7,k, 2),k=0, 2)
3787+ & / -0.1172251E+02, -0.2183624E+01, 0.4955794E+01 /
3788+ data (am( 8,k, 2),k=0, 2)
3789+ & / 0.1662533E-01, 0.7622870E-02, -0.4895887E-03 /
3790+
3791+ data mexvec( 1) / 8 /
3792+ data mlfvec( 1) / 2 /
3793+ data ut1vec( 1) / 0.2612618E+01 /
3794+ data ut2vec( 1) / -0.1258304E+06 /
3795+ data alfvec( 1) / 0.3407552E+00 /
3796+ data qmavec( 1) / 0.0000000E+00 /
3797+ data (am( 0,k, 1),k=0, 2)
3798+ & / 0.9905300E+00, -0.4502235E+00, 0.1624441E+00 /
3799+ data (am( 1,k, 1),k=0, 2)
3800+ & / 0.8867534E+00, 0.1630829E-01, -0.4049085E-01 /
3801+ data (am( 2,k, 1),k=0, 2)
3802+ & / 0.8547974E+00, 0.3336301E+00, 0.1371388E+00 /
3803+ data (am( 3,k, 1),k=0, 2)
3804+ & / 0.2941113E+00, -0.1527905E+01, 0.2331879E+00 /
3805+ data (am( 4,k, 1),k=0, 2)
3806+ & / 0.3384235E+02, 0.3715315E+01, 0.8276930E+00 /
3807+ data (am( 5,k, 1),k=0, 2)
3808+ & / 0.6230115E+01, 0.3134639E+01, -0.1729099E+01 /
3809+ data (am( 6,k, 1),k=0, 2)
3810+ & / -0.1186928E+01, -0.3282460E+00, 0.1052020E+00 /
3811+ data (am( 7,k, 1),k=0, 2)
3812+ & / -0.8545702E+01, -0.6247947E+01, 0.3692561E+01 /
3813+ data (am( 8,k, 1),k=0, 2)
3814+ & / 0.1724598E-01, 0.7120465E-02, 0.4003646E-04 /
3815+
3816+ data mexvec( 0) / 8 /
3817+ data mlfvec( 0) / 2 /
3818+ data ut1vec( 0) / -0.4656819E+00 /
3819+ data ut2vec( 0) / -0.2742390E+03 /
3820+ data alfvec( 0) / 0.4491863E+00 /
3821+ data qmavec( 0) / 0.0000000E+00 /
3822+ data (am( 0,k, 0),k=0, 2)
3823+ & / 0.1193572E+03, -0.3886845E+01, -0.1133965E+01 /
3824+ data (am( 1,k, 0),k=0, 2)
3825+ & / -0.9421449E+02, 0.3995885E+01, 0.1607363E+01 /
3826+ data (am( 2,k, 0),k=0, 2)
3827+ & / 0.4206383E+01, 0.2485954E+00, 0.2497468E+00 /
3828+ data (am( 3,k, 0),k=0, 2)
3829+ & / 0.1210557E+03, -0.3015765E+01, -0.1423651E+01 /
3830+ data (am( 4,k, 0),k=0, 2)
3831+ & / -0.1013897E+03, -0.7113478E+00, 0.2621865E+00 /
3832+ data (am( 5,k, 0),k=0, 2)
3833+ & / -0.1312404E+01, -0.9297691E+00, -0.1562531E+00 /
3834+ data (am( 6,k, 0),k=0, 2)
3835+ & / 0.1627137E+01, 0.4954111E+00, -0.6387009E+00 /
3836+ data (am( 7,k, 0),k=0, 2)
3837+ & / 0.1537698E+00, -0.2487878E+00, 0.8305947E+00 /
3838+ data (am( 8,k, 0),k=0, 2)
3839+ & / 0.2496448E-01, 0.2457823E-02, 0.8234276E-03 /
3840+
3841+ data mexvec(-1) / 8 /
3842+ data mlfvec(-1) / 2 /
3843+ data ut1vec(-1) / 0.3862583E+01 /
3844+ data ut2vec(-1) / -0.1265969E+01 /
3845+ data alfvec(-1) / 0.2457668E+00 /
3846+ data qmavec(-1) / 0.0000000E+00 /
3847+ data (am( 0,k,-1),k=0, 2)
3848+ & / 0.2647441E+02, 0.1059277E+02, -0.9176654E+00 /
3849+ data (am( 1,k,-1),k=0, 2)
3850+ & / 0.1990636E+01, 0.8558918E-01, 0.4248667E-01 /
3851+ data (am( 2,k,-1),k=0, 2)
3852+ & / -0.1476095E+02, -0.3276255E+02, 0.1558110E+01 /
3853+ data (am( 3,k,-1),k=0, 2)
3854+ & / -0.2966889E+01, -0.3649037E+02, 0.1195914E+01 /
3855+ data (am( 4,k,-1),k=0, 2)
3856+ & / -0.1000519E+03, -0.2464635E+01, 0.1964849E+00 /
3857+ data (am( 5,k,-1),k=0, 2)
3858+ & / 0.3718331E+02, 0.4700389E+02, -0.2772142E+01 /
3859+ data (am( 6,k,-1),k=0, 2)
3860+ & / -0.1872722E+02, -0.2291189E+02, 0.1089052E+01 /
3861+ data (am( 7,k,-1),k=0, 2)
3862+ & / -0.1628146E+02, -0.1823993E+02, 0.2537369E+01 /
3863+ data (am( 8,k,-1),k=0, 2)
3864+ & / -0.1156300E+01, -0.1280495E+00, 0.5153245E-01 /
3865+
3866+ data mexvec(-2) / 7 /
3867+ data mlfvec(-2) / 2 /
3868+ data ut1vec(-2) / 0.1895615E+00 /
3869+ data ut2vec(-2) / -0.3069097E+01 /
3870+ data alfvec(-2) / 0.5293999E+00 /
3871+ data qmavec(-2) / 0.0000000E+00 /
3872+ data (am( 0,k,-2),k=0, 2)
3873+ & / -0.6556775E+00, 0.2490190E+00, 0.3966485E-01 /
3874+ data (am( 1,k,-2),k=0, 2)
3875+ & / 0.1305102E+01, -0.1188925E+00, -0.4600870E-02 /
3876+ data (am( 2,k,-2),k=0, 2)
3877+ & / -0.2371436E+01, 0.3566814E+00, -0.2834683E+00 /
3878+ data (am( 3,k,-2),k=0, 2)
3879+ & / -0.6152826E+01, 0.8339877E+00, -0.7233230E+00 /
3880+ data (am( 4,k,-2),k=0, 2)
3881+ & / -0.8346558E+01, 0.2892168E+01, 0.2137099E+00 /
3882+ data (am( 5,k,-2),k=0, 2)
3883+ & / 0.1279530E+02, 0.1021114E+00, 0.5787439E+00 /
3884+ data (am( 6,k,-2),k=0, 2)
3885+ & / 0.5858816E+00, -0.1940375E+01, -0.4029269E+00 /
3886+ data (am( 7,k,-2),k=0, 2)
3887+ & / -0.2795725E+02, -0.5263392E+00, 0.1290229E+01 /
3888+
3889+ data mexvec(-3) / 7 /
3890+ data mlfvec(-3) / 2 /
3891+ data ut1vec(-3) / 0.3753257E+01 /
3892+ data ut2vec(-3) / -0.1113085E+01 /
3893+ data alfvec(-3) / 0.3713141E+00 /
3894+ data qmavec(-3) / 0.0000000E+00 /
3895+ data (am( 0,k,-3),k=0, 2)
3896+ & / 0.1580931E+01, -0.2273826E+01, -0.1822245E+01 /
3897+ data (am( 1,k,-3),k=0, 2)
3898+ & / 0.2702644E+01, 0.6763243E+00, 0.7231586E-02 /
3899+ data (am( 2,k,-3),k=0, 2)
3900+ & / -0.1857924E+02, 0.3907500E+01, 0.5850109E+01 /
3901+ data (am( 3,k,-3),k=0, 2)
3902+ & / -0.3044793E+02, 0.2639332E+01, 0.5566644E+01 /
3903+ data (am( 4,k,-3),k=0, 2)
3904+ & / -0.4258011E+01, -0.5429244E+01, 0.4418946E+00 /
3905+ data (am( 5,k,-3),k=0, 2)
3906+ & / 0.3465259E+02, -0.5532604E+01, -0.4904153E+01 /
3907+ data (am( 6,k,-3),k=0, 2)
3908+ & / -0.1658858E+02, 0.2923275E+01, 0.2266286E+01 /
3909+ data (am( 7,k,-3),k=0, 2)
3910+ & / -0.1149263E+02, 0.2877475E+01, -0.7999105E+00 /
3911+
3912+ data mexvec(-4) / 7 /
3913+ data mlfvec(-4) / 2 /
3914+ data ut1vec(-4) / 0.4400772E+01 /
3915+ data ut2vec(-4) / -0.1356116E+01 /
3916+ data alfvec(-4) / 0.3712017E-01 /
3917+ data qmavec(-4) / 0.1300000E+01 /
3918+ data (am( 0,k,-4),k=0, 2)
3919+ & / -0.8293661E+00, -0.3982375E+01, -0.6494283E-01 /
3920+ data (am( 1,k,-4),k=0, 2)
3921+ & / 0.2754618E+01, 0.8338636E+00, -0.6885160E-01 /
3922+ data (am( 2,k,-4),k=0, 2)
3923+ & / -0.1657987E+02, 0.1439143E+02, -0.6887240E+00 /
3924+ data (am( 3,k,-4),k=0, 2)
3925+ & / -0.2800703E+02, 0.1535966E+02, -0.7377693E+00 /
3926+ data (am( 4,k,-4),k=0, 2)
3927+ & / -0.6460216E+01, -0.4783019E+01, 0.4913297E+00 /
3928+ data (am( 5,k,-4),k=0, 2)
3929+ & / 0.3141830E+02, -0.3178031E+02, 0.7136013E+01 /
3930+ data (am( 6,k,-4),k=0, 2)
3931+ & / -0.1802509E+02, 0.1862163E+02, -0.4632843E+01 /
3932+ data (am( 7,k,-4),k=0, 2)
3933+ & / -0.1240412E+02, 0.2565386E+02, -0.1066570E+02 /
3934+
3935+ data mexvec(-5) / 6 /
3936+ data mlfvec(-5) / 2 /
3937+ data ut1vec(-5) / 0.5562568E+01 /
3938+ data ut2vec(-5) / -0.1801317E+01 /
3939+ data alfvec(-5) / 0.4952010E-02 /
3940+ data qmavec(-5) / 0.4500000E+01 /
3941+ data (am( 0,k,-5),k=0, 2)
3942+ & / -0.6031237E+01, 0.1992727E+01, -0.1076331E+01 /
3943+ data (am( 1,k,-5),k=0, 2)
3944+ & / 0.2933912E+01, 0.5839674E+00, 0.7509435E-01 /
3945+ data (am( 2,k,-5),k=0, 2)
3946+ & / -0.8284919E+01, 0.1488593E+01, -0.8251678E+00 /
3947+ data (am( 3,k,-5),k=0, 2)
3948+ & / -0.1925986E+02, 0.2805753E+01, -0.3015446E+01 /
3949+ data (am( 4,k,-5),k=0, 2)
3950+ & / -0.9480483E+01, -0.9767837E+00, -0.1165544E+01 /
3951+ data (am( 5,k,-5),k=0, 2)
3952+ & / 0.2193195E+02, -0.1788518E+02, 0.9460908E+01 /
3953+ data (am( 6,k,-5),k=0, 2)
3954+ & / -0.1327377E+02, 0.1201754E+02, -0.6277844E+01 /
3955+
3956+ if(q .le. qmavec(ifl)) then
3957+ faux5L = 0.d0
3958+ return
3959+ endif
3960+
3961+ if(x .ge. 1.d0) then
3962+ faux5L = 0.d0
3963+ return
3964+ endif
3965+
3966+ tmp = log(q/alfvec(ifl))
3967+ if(tmp .le. 0.d0) then
3968+ faux5L = 0.d0
3969+ return
3970+ endif
3971+
3972+ sb = log(tmp)
3973+ sb1 = sb - 1.2d0
3974+ sb2 = sb1*sb1
3975+
3976+ do i = 0, nex
3977+ af(i) = 0.d0
3978+ sbx = 1.d0
3979+ do k = 0, mlfvec(ifl)
3980+ af(i) = af(i) + sbx*am(i,k,ifl)
3981+ sbx = sb1*sbx
3982+ enddo
3983+ enddo
3984+
3985+ y = -log(x)
3986+ u = log(x/0.00001d0)
3987+
3988+ part1 = af(1)*y**(1.d0+0.01d0*af(4))*(1.d0+ af(8)*u)
3989+ part2 = af(0)*(1.d0 - x) + af(3)*x
3990+ part3 = x*(1.d0-x)*(af(5)+af(6)*(1.d0-x)+af(7)*x*(1.d0-x))
3991+ part4 = ut1vec(ifl)*log(1.d0-x) +
3992+ & AF(2)*log(1.d0+exp(ut2vec(ifl))-x)
3993+
3994+ faux5L = exp(log(x) + part1 + part2 + part3 + part4)
3995+
3996+c include threshold factor...
3997+ faux5L = faux5L * (1.d0 - qmavec(ifl)/q)
3998+
3999+ return
4000+ end
4001
4002=== added file 'Template/NLO/Source/PDF/Ctq5Pdf.f'
4003--- Template/NLO/Source/PDF/Ctq5Pdf.f 1970-01-01 00:00:00 +0000
4004+++ Template/NLO/Source/PDF/Ctq5Pdf.f 2012-09-28 12:29:27 +0000
4005@@ -0,0 +1,344 @@
4006+C============================================================================
4007+C CTEQ Parton Distribution Functions: Version 5.0
4008+C Nov. 1, 1999
4009+C
4010+C Ref: "GLOBAL QCD ANALYSIS OF PARTON STRUCTURE OF THE NUCLEON:
4011+C CTEQ5 PPARTON DISTRIBUTIONS"
4012+C
4013+C hep-ph/9903282; to be published in Eur. Phys. J. C 1999.
4014+C
4015+C These PDF's use quadratic interpolation of attached tables. A parametrized
4016+C version of the same PDF's without external tables is under construction.
4017+C They will become available later.
4018+C
4019+C This package contains 7 sets of CTEQ5 PDF's; plus two updated ones.
4020+C The undated CTEQ5M1 and CTEQHQ1 use an improved evolution code.
4021+C Both the original and the updated ones fit current data with comparable
4022+C accuracy. The CTEQHQ1 set also involve a different choice of scale,
4023+C hence differs from CTEQHQ slightly more. It is preferred over CTEQ5HQ.
4024+
4025+C Details are:
4026+C ---------------------------------------------------------------------------
4027+C Iset PDF Description Alpha_s(Mz) Lam4 Lam5 Table_File
4028+C ---------------------------------------------------------------------------
4029+C 1 CTEQ5M Standard MSbar scheme 0.118 326 226 cteq5m.tbl
4030+C 2 CTEQ5D Standard DIS scheme 0.118 326 226 cteq5d.tbl
4031+C 3 CTEQ5L Leading Order 0.127 192 146 cteq5l.tbl
4032+C 4 CTEQ5HJ Large-x gluon enhanced 0.118 326 226 cteq5hj.tbl
4033+C 5 CTEQ5HQ Heavy Quark 0.118 326 226 cteq5hq.tbl
4034+C 6 CTEQ5F3 Nf=3 FixedFlavorNumber 0.106 (Lam3=395) cteq5f3.tbl
4035+C 7 CTEQ5F4 Nf=4 FixedFlavorNumber 0.112 309 XXX cteq5f4.tbl
4036+C --------------------------------------------------------
4037+C 8 CTEQ5M1 Improved CTEQ5M 0.118 326 226 cteq5m1.tbl
4038+C 9 CTEQ5HQ1 Improved CTEQ5HQ 0.118 326 226 ctq5hq1.tbl
4039+C ---------------------------------------------------------------------------
4040+C
4041+C The available applied range is 10^-5 << x << 1 and 1.0 << Q << 10,000 (GeV).
4042+C Lam5 (Lam4, Lam3) represents Lambda value (in MeV) for 5 (4,3) flavors.
4043+C The matching alpha_s between 4 and 5 flavors takes place at Q=4.5 GeV,
4044+C which is defined as the bottom quark mass, whenever it can be applied.
4045+C
4046+C The Table_Files are assumed to be in the working directory.
4047+C
4048+C Before using the PDF, it is necessary to do the initialization by
4049+C Call SetCtq5(Iset)
4050+C where Iset is the desired PDF specified in the above table.
4051+C
4052+C The function Ctq5Pdf (Iparton, X, Q)
4053+C returns the parton distribution inside the proton for parton [Iparton]
4054+C at [X] Bjorken_X and scale [Q] (GeV) in PDF set [Iset].
4055+C Iparton is the parton label (5, 4, 3, 2, 1, 0, -1, ......, -5)
4056+C for (b, c, s, d, u, g, u_bar, ..., b_bar),
4057+C whereas CTEQ5F3 has, by definition, only 3 flavors and gluon;
4058+C CTEQ5F4 has only 4 flavors and gluon.
4059+C
4060+C For detailed information on the parameters used, e.q. quark masses,
4061+C QCD Lambda, ... etc., see info lines at the beginning of the
4062+C Table_Files.
4063+C
4064+C These programs, as provided, are in double precision. By removing the
4065+C "Implicit Double Precision" lines, they can also be run in single
4066+C precision.
4067+C
4068+C If you have detailed questions concerning these CTEQ5 distributions,
4069+C or if you find problems/bugs using this package, direct inquires to
4070+C Hung-Liang Lai(lai@phys.nthu.edu.tw) or Wu-Ki Tung(Tung@pa.msu.edu).
4071+C
4072+C===========================================================================
4073+
4074+ Function Ctq5Pdf (Iparton, X, Q)
4075+ Implicit Double Precision (A-H,O-Z)
4076+ Logical Warn
4077+ Common
4078+ > / CtqPar2 / Nx, Nt, NfMx
4079+ > / QCDtable / Alambda, Nfl, Iorder
4080+
4081+ Data Warn /.true./
4082+ save Warn
4083+
4084+ If (X .lt. 0D0 .or. X .gt. 1D0) Then
4085+ Print *, 'X out of range in Ctq5Pdf: ', X
4086+ Stop
4087+ Endif
4088+ If (Q .lt. Alambda) Then
4089+ Print *, 'Q out of range in Ctq5Pdf: ', Q
4090+ Stop
4091+ Endif
4092+ If ((Iparton .lt. -NfMx .or. Iparton .gt. NfMx)) Then
4093+ If (Warn) Then
4094+C put a warning for calling extra flavor.
4095+ Warn = .false.
4096+ Print *, 'Warning: Iparton out of range in Ctq5Pdf: '
4097+ > , Iparton
4098+ Endif
4099+ Ctq5Pdf = 0D0
4100+ Return
4101+ Endif
4102+
4103+ Ctq5Pdf = PartonX (Iparton, X, Q)
4104+ if(Ctq5Pdf.lt.0.D0) Ctq5Pdf = 0.D0
4105+
4106+ Return
4107+
4108+C ********************
4109+ End
4110+
4111+ FUNCTION PartonX_orig (IPRTN, X, Q)
4112+C
4113+C Given the parton distribution function in the array Upd in
4114+C COMMON / CtqPar1 / , this routine fetches u(fl, x, q) at any value of
4115+C x and q using Mth-order polynomial interpolation for x and Ln(Q/Lambda).
4116+C
4117+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
4118+C
4119+ PARAMETER (MXX = 105, MXQ = 25, MXF = 6)
4120+ PARAMETER (MXPQX = (MXF *2 +2) * MXQ * MXX)
4121+ PARAMETER (M= 2, M1 = M + 1)
4122+C
4123+ Logical First
4124+ Common
4125+ > / CtqPar1 / Al, XV(0:MXX), QL(0:MXQ), UPD(MXPQX)
4126+ > / CtqPar2 / Nx, Nt, NfMx
4127+ > / XQrange / Qini, Qmax, Xmin
4128+C
4129+ Dimension Fq(M1), Df(M1)
4130+
4131+ Data First /.true./
4132+ save First
4133+C Work with Log (Q)
4134+ QG = LOG (Q/AL)
4135+
4136+C Find lower end of interval containing X
4137+ JL = -1
4138+ JU = Nx+1
4139+ 11 If (JU-JL .GT. 1) Then
4140+ JM = (JU+JL) / 2
4141+ If (X .GT. XV(JM)) Then
4142+ JL = JM
4143+ Else
4144+ JU = JM
4145+ Endif
4146+ Goto 11
4147+ Endif
4148+
4149+ Jx = JL - (M-1)/2
4150+ If (X .lt. Xmin .and. First ) Then
4151+ First = .false.
4152+ Print '(A, 2(1pE12.4))',
4153+ > ' WARNING: X << Xmin, extrapolation used; X, Xmin =', X, Xmin
4154+ If (Jx .LT. 0) Jx = 0
4155+ Elseif (Jx .GT. Nx-M) Then
4156+ Jx = Nx - M
4157+ Endif
4158+C Find the interval where Q lies
4159+ JL = -1
4160+ JU = NT+1
4161+ 12 If (JU-JL .GT. 1) Then
4162+ JM = (JU+JL) / 2
4163+ If (QG .GT. QL(JM)) Then
4164+ JL = JM
4165+ Else
4166+ JU = JM
4167+ Endif
4168+ Goto 12
4169+ Endif
4170+
4171+ Jq = JL - (M-1)/2
4172+ If (Jq .LT. 0) Then
4173+ Jq = 0
4174+ If (Q .lt. Qini) Print '(A, 2(1pE12.4))',
4175+ > ' WARNING: Q << Qini, extrapolation used; Q, Qini =', Q, Qini
4176+ Elseif (Jq .GT. Nt-M) Then
4177+ Jq = Nt - M
4178+ If (Q .gt. Qmax) Print '(A, 2(1pE12.4))',
4179+ > ' WARNING: Q > Qmax, extrapolation used; Q, Qmax =', Q, Qmax
4180+ Endif
4181+
4182+ If (Iprtn .GE. 3) Then
4183+ Ip = - Iprtn
4184+ Else
4185+ Ip = Iprtn
4186+ EndIf
4187+C Find the off-set in the linear array Upd
4188+ JFL = Ip + NfMx
4189+ J0 = (JFL * (NT+1) + Jq) * (NX+1) + Jx
4190+C
4191+C Now interpolate in x for M1 Q's
4192+ Do 21 Iq = 1, M1
4193+ J1 = J0 + (Nx+1)*(Iq-1) + 1
4194+ Call Polint (XV(Jx), Upd(J1), M1, X, Fq(Iq), Df(Iq))
4195+ 21 Continue
4196+C Finish off by interpolating in Q
4197+ Call Polint (QL(Jq), Fq(1), M1, QG, Ftmp, Ddf)
4198+
4199+ PartonX_orig = Ftmp
4200+C
4201+ RETURN
4202+C ****************************
4203+ END
4204+
4205+ Subroutine SetCtq5 (Iset)
4206+ Implicit Double Precision (A-H,O-Z)
4207+ Parameter (Isetmax=9)
4208+ Character Flnm(Isetmax)*12, Tablefile*40
4209+ Data (Flnm(I), I=1,Isetmax)
4210+ > / 'cteq5m.tbl', 'cteq5d.tbl', 'cteq5l.tbl', 'cteq5hj.tbl'
4211+ > , 'cteq5hq.tbl', 'cteq5f3.tbl', 'cteq5f4.tbl'
4212+ > , 'cteq5m1.tbl', 'ctq5hq1.tbl' /
4213+ Data Tablefile / 'test.tbl' /
4214+ Data Isetold, Isetmin, Isettest / -987, 1, 911 /
4215+ save
4216+
4217+C If data file not initialized, do so.
4218+ If(Iset.ne.Isetold) then
4219+ IU= NextUn()
4220+ If (Iset .eq. Isettest) then
4221+ Print* ,'Opening ', Tablefile
4222+ 21 Open(IU, File=Tablefile, Status='OLD', Err=101)
4223+ GoTo 22
4224+ 101 Print*, Tablefile, ' cannot be opened '
4225+ Print*, 'Please input the .tbl file:'
4226+ Read (*,'(A)') Tablefile
4227+ Goto 21
4228+ 22 Continue
4229+ ElseIf (Iset.lt.Isetmin .or. Iset.gt.Isetmax) Then
4230+ Print *, 'Invalid Iset number in SetCtq5 :', Iset
4231+ Stop
4232+ Else
4233+ Tablefile=Flnm(Iset)
4234+c Open(IU, File='Pdfdata/'//Tablefile, Status='OLD', Err=100)
4235+ call OpenData(TableFile)
4236+ Endif
4237+ Call ReadTbl (IU)
4238+ Close (IU)
4239+ Isetold=Iset
4240+ Endif
4241+ Return
4242+
4243+ 100 Print *, ' Data file ', Tablefile, ' cannot be opened '
4244+ >//'in SetCtq5!!'
4245+ Stop
4246+C ********************
4247+ End
4248+
4249+ Subroutine ReadTbl (Nu)
4250+ Implicit Double Precision (A-H,O-Z)
4251+ Character Line*80
4252+ PARAMETER (MXX = 105, MXQ = 25, MXF = 6)
4253+ PARAMETER (MXPQX = (MXF *2 +2) * MXQ * MXX)
4254+ Common
4255+ > / CtqPar1 / Al, XV(0:MXX), QL(0:MXQ), UPD(MXPQX)
4256+ > / CtqPar2 / Nx, Nt, NfMx
4257+ > / XQrange / Qini, Qmax, Xmin
4258+ > / QCDtable / Alambda, Nfl, Iorder
4259+ > / Masstbl / Amass(6)
4260+
4261+ Read (Nu, '(A)') Line
4262+ Read (Nu, '(A)') Line
4263+ Read (Nu, *) Dr, Fl, Al, (Amass(I),I=1,6)
4264+ Iorder = Nint(Dr)
4265+ Nfl = Nint(Fl)
4266+ Alambda = Al
4267+
4268+ Read (Nu, '(A)') Line
4269+ Read (Nu, *) NX, NT, NfMx
4270+
4271+ Read (Nu, '(A)') Line
4272+ Read (Nu, *) QINI, QMAX, (QL(I), I =0, NT)
4273+
4274+ Read (Nu, '(A)') Line
4275+ Read (Nu, *) XMIN, (XV(I), I =0, NX)
4276+
4277+ Do 11 Iq = 0, NT
4278+ QL(Iq) = Log (QL(Iq) /Al)
4279+ 11 Continue
4280+C
4281+C Since quark = anti-quark for nfl>2 at this stage,
4282+C we Read out only the non-redundent data points
4283+C No of flavors = NfMx (sea) + 1 (gluon) + 2 (valence)
4284+
4285+ Nblk = (NX+1) * (NT+1)
4286+ Npts = Nblk * (NfMx+3)
4287+ Read (Nu, '(A)') Line
4288+ Read (Nu, *, IOSTAT=IRET) (UPD(I), I=1,Npts)
4289+
4290+ Return
4291+C ****************************
4292+ End
4293+
4294+ Function NextUn()
4295+C Returns an unallocated FORTRAN i/o unit.
4296+ Logical EX
4297+C
4298+ Do 10 N = 10, 300
4299+ INQUIRE (UNIT=N, OPENED=EX)
4300+ If (.NOT. EX) then
4301+ NextUn = N
4302+ Return
4303+ Endif
4304+ 10 Continue
4305+ Stop ' There is no available I/O unit. '
4306+C *************************
4307+ End
4308+C
4309+
4310+ SUBROUTINE POLINT (XA,YA,N,X,Y,DY)
4311+
4312+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
4313+C Adapted from "Numerical Recipes"
4314+ PARAMETER (NMAX=10)
4315+ DIMENSION XA(N),YA(N),C(NMAX),D(NMAX)
4316+ NS=1
4317+ DIF=ABS(X-XA(1))
4318+ DO 11 I=1,N
4319+ DIFT=ABS(X-XA(I))
4320+ IF (DIFT.LT.DIF) THEN
4321+ NS=I
4322+ DIF=DIFT
4323+ ENDIF
4324+ C(I)=YA(I)
4325+ D(I)=YA(I)
4326+11 CONTINUE
4327+ Y=YA(NS)
4328+ NS=NS-1
4329+ DO 13 M=1,N-1
4330+ DO 12 I=1,N-M
4331+ HO=XA(I)-X
4332+ HP=XA(I+M)-X
4333+ W=C(I+1)-D(I)
4334+ DEN=HO-HP
4335+ IF(DEN.EQ.0.) STOP
4336+ DEN=W/DEN
4337+ D(I)=HP*DEN
4338+ C(I)=HO*DEN
4339+12 CONTINUE
4340+ IF (2*NS.LT.N-M)THEN
4341+ DY=C(NS+1)
4342+ ELSE
4343+ DY=D(NS)
4344+ NS=NS-1
4345+ ENDIF
4346+ Y=Y+DY
4347+13 CONTINUE
4348+ RETURN
4349+ END
4350
4351=== added file 'Template/NLO/Source/PDF/Ctq6Pdf.f'
4352--- Template/NLO/Source/PDF/Ctq6Pdf.f 1970-01-01 00:00:00 +0000
4353+++ Template/NLO/Source/PDF/Ctq6Pdf.f 2012-09-28 12:29:27 +0000
4354@@ -0,0 +1,480 @@
4355+C============================================================================
4356+C CTEQ Parton Distribution Functions: Version 6
4357+C January 24, 2002, v6.0
4358+C April 10, 2002, v6.1
4359+C
4360+C Ref: "New Generation of Parton Distributions with
4361+C Uncertainties from Global QCD Analysis"
4362+C By: J. Pumplin, D.R. Stump, J.Huston, H.L. Lai, P. Nadolsky, W.K. Tung
4363+C hep-ph/0201195
4364+C
4365+C This package contains 3 standard sets of CTEQ6 PDF's and 40 up/down sets
4366+C with respect to CTEQ6M PDF's. Details are:
4367+C ---------------------------------------------------------------------------
4368+C Iset PDF Description Alpha_s(Mz)**Lam4 Lam5 Table_File
4369+C ---------------------------------------------------------------------------
4370+C 1 CTEQ6M Standard MSbar scheme 0.118 326 226 cteq6m.tbl
4371+C 2 CTEQ6D Standard DIS scheme 0.118 326 226 cteq6d.tbl
4372+C 3 CTEQ6L Leading Order 0.118** 326** 226 cteq6l.tbl
4373+C 4 CTEQ6L1 Leading Order 0.130 215 165 cteq6l1.tbl
4374+C ------------------------------
4375+C 1xx CTEQ6M1xx +/- w.r.t. CTEQ6M 0.118 326 226 cteq6m1xx.tbl
4376+C (where xx=01--40)
4377+C ---------------------------------------------------------------------------
4378+C ** ALL fits are obtained by using the same coupling strength
4379+C \alpha_s(Mz)=0.118 and the NLO running \alpha_s formula, except CTEQ6L1
4380+C which uses the LO running \alpha_s and its value determined from the fit.
4381+C For the LO fits, the evolution of the PDF and the hard cross sections are
4382+C calculated at LO. More detailed discussions are given in hep-ph/0201195.
4383+C
4384+C The table grids are generated for 10^-6 < x < 1 and 1.3 < Q < 10,000 (GeV).
4385+C PDF values outside of the above range are returned using extrapolation.
4386+C Lam5 (Lam4) represents Lambda value (in MeV) for 5 (4) flavors.
4387+C The matching alpha_s between 4 and 5 flavors takes place at Q=4.5 GeV,
4388+C which is defined as the bottom quark mass, whenever it can be applied.
4389+C
4390+C The Table_Files are assumed to be in the working directory.
4391+C
4392+C Before using the PDF, it is necessary to do the initialization by
4393+C Call SetCtq6(Iset)
4394+C where Iset is the desired PDF specified in the above table.
4395+C
4396+C The function Ctq6Pdf (Iparton, X, Q)
4397+C returns the parton distribution inside the proton for parton [Iparton]
4398+C at [X] Bjorken_X and scale [Q] (GeV) in PDF set [Iset].
4399+C Iparton is the parton label (5, 4, 3, 2, 1, 0, -1, ......, -5)
4400+C for (b, c, s, d, u, g, u_bar, ..., b_bar),
4401+C
4402+C For detailed information on the parameters used, e.q. quark masses,
4403+C QCD Lambda, ... etc., see info lines at the beginning of the
4404+C Table_Files.
4405+C
4406+C These programs, as provided, are in double precision. By removing the
4407+C "Implicit Double Precision" lines, they can also be run in single
4408+C precision.
4409+C
4410+C If you have detailed questions concerning these CTEQ6 distributions,
4411+C or if you find problems/bugs using this package, direct inquires to
4412+C Pumplin@pa.msu.edu or Tung@pa.msu.edu.
4413+C
4414+C===========================================================================
4415+
4416+ Function Ctq6Pdf (Iparton, X, Q)
4417+ Implicit Double Precision (A-H,O-Z)
4418+ Logical Warn
4419+ Common
4420+ > / CtqPar2 / Nx, Nt, NfMx
4421+ > / QCDtable / Alambda, Nfl, Iorder
4422+
4423+ Data Warn /.true./
4424+ save Warn
4425+
4426+ If (X .lt. 0D0 .or. X .gt. 1D0) Then
4427+ Print *, 'X out of range in Ctq6Pdf: ', X
4428+ Stop
4429+ Endif
4430+ If (Q .lt. Alambda) Then
4431+ Print *, 'Q out of range in Ctq6Pdf: ', Q
4432+ Stop
4433+ Endif
4434+ If ((Iparton .lt. -NfMx .or. Iparton .gt. NfMx)) Then
4435+ If (Warn) Then
4436+C put a warning for calling extra flavor.
4437+ Warn = .false.
4438+ Print *, 'Warning: Iparton out of range in Ctq6Pdf: '
4439+ > , Iparton
4440+ Endif
4441+ Ctq6Pdf = 0D0
4442+ Return
4443+ Endif
4444+
4445+ Ctq6Pdf = PartonX6 (Iparton, X, Q)
4446+ if(Ctq6Pdf.lt.0.D0) Ctq6Pdf = 0.D0
4447+
4448+ Return
4449+
4450+C ********************
4451+ End
4452+
4453+ Subroutine SetCtq6 (Iset)
4454+ Implicit Double Precision (A-H,O-Z)
4455+ Parameter (Isetmax0=4)
4456+ Character Flnm(Isetmax0)*6, nn*3, Tablefile*40
4457+ Data (Flnm(I), I=1,Isetmax0)
4458+ > / 'cteq6m', 'cteq6d', 'cteq6l', 'cteq6l'/
4459+ Data Isetold, Isetmin0, Isetmin1, Isetmax1 /-987,1,101,140/
4460+ save
4461+
4462+C If data file not initialized, do so.
4463+ If(Iset.ne.Isetold) then
4464+ IU= NextUn6()
4465+ If (Iset.ge.Isetmin0 .and. Iset.le.3) Then
4466+ Tablefile=Flnm(Iset)//'.tbl'
4467+ Elseif (Iset.eq.Isetmax0) Then
4468+ Tablefile=Flnm(Iset)//'1.tbl'
4469+ Elseif (Iset.ge.Isetmin1 .and. Iset.le.Isetmax1) Then
4470+ write(nn,'(I3)') Iset
4471+ Tablefile=Flnm(1)//nn//'.tbl'
4472+ Else
4473+ Print *, 'Invalid Iset number in SetCtq6 :', Iset
4474+ Stop
4475+ Endif
4476+c Open(IU, File='Pdfdata/'//Tablefile, Status='OLD', Err=100)
4477+ call OpenData(TableFile)
4478+ 21 Call ReadTbl6 (IU)
4479+ Close (IU)
4480+ Isetold=Iset
4481+ Endif
4482+ Return
4483+
4484+ 100 Print *, ' Data file ', Tablefile, ' cannot be opened '
4485+ >//'in SetCtq6!!'
4486+ Stop
4487+C ********************
4488+ End
4489+
4490+ Subroutine ReadTbl6 (Nu)
4491+ Implicit Double Precision (A-H,O-Z)
4492+ Character Line*80
4493+ PARAMETER (MXX = 96, MXQ = 20, MXF = 5)
4494+ PARAMETER (MXPQX = (MXF + 3) * MXQ * MXX)
4495+ Common
4496+ > / CtqPar1 / Al, XV(0:MXX), TV(0:MXQ), UPD(MXPQX)
4497+ > / CtqPar2 / Nx, Nt, NfMx
4498+ > / XQrange / Qini, Qmax, Xmin
4499+ > / QCDtable / Alambda, Nfl, Iorder
4500+ > / Masstbl / Amass(6)
4501+
4502+ Read (Nu, '(A)') Line
4503+ Read (Nu, '(A)') Line
4504+ Read (Nu, *) Dr, Fl, Al, (Amass(I),I=1,6)
4505+ Iorder = Nint(Dr)
4506+ Nfl = Nint(Fl)
4507+ Alambda = Al
4508+
4509+ Read (Nu, '(A)') Line
4510+ Read (Nu, *) NX, NT, NfMx
4511+
4512+ Read (Nu, '(A)') Line
4513+ Read (Nu, *) QINI, QMAX, (TV(I), I =0, NT)
4514+
4515+ Read (Nu, '(A)') Line
4516+ Read (Nu, *) XMIN, (XV(I), I =0, NX)
4517+
4518+ Do 11 Iq = 0, NT
4519+ TV(Iq) = Log(Log (TV(Iq) /Al))
4520+ 11 Continue
4521+C
4522+C Since quark = anti-quark for nfl>2 at this stage,
4523+C we Read out only the non-redundent data points
4524+C No of flavors = NfMx (sea) + 1 (gluon) + 2 (valence)
4525+
4526+ Nblk = (NX+1) * (NT+1)
4527+ Npts = Nblk * (NfMx+3)
4528+ Read (Nu, '(A)') Line
4529+ Read (Nu, *, IOSTAT=IRET) (UPD(I), I=1,Npts)
4530+
4531+ Return
4532+C ****************************
4533+ End
4534+
4535+ Function NextUn6()
4536+C Returns an unallocated FORTRAN i/o unit.
4537+ Logical EX
4538+C
4539+ Do 10 N = 10, 300
4540+ INQUIRE (UNIT=N, OPENED=EX)
4541+ If (.NOT. EX) then
4542+ NextUn6 = N
4543+ Return
4544+ Endif
4545+ 10 Continue
4546+ Stop ' There is no available I/O unit. '
4547+C *************************
4548+ End
4549+C
4550+
4551+ SUBROUTINE POLINT6 (XA,YA,N,X,Y,DY)
4552+
4553+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
4554+C Adapted from "Numerical Recipes"
4555+ PARAMETER (NMAX=10)
4556+ DIMENSION XA(N),YA(N),C(NMAX),D(NMAX)
4557+ NS=1
4558+ DIF=ABS(X-XA(1))
4559+ DO 11 I=1,N
4560+ DIFT=ABS(X-XA(I))
4561+ IF (DIFT.LT.DIF) THEN
4562+ NS=I
4563+ DIF=DIFT
4564+ ENDIF
4565+ C(I)=YA(I)
4566+ D(I)=YA(I)
4567+11 CONTINUE
4568+ Y=YA(NS)
4569+ NS=NS-1
4570+ DO 13 M=1,N-1
4571+ DO 12 I=1,N-M
4572+ HO=XA(I)-X
4573+ HP=XA(I+M)-X
4574+ W=C(I+1)-D(I)
4575+ DEN=HO-HP
4576+ IF(DEN.EQ.0.) stop
4577+ DEN=W/DEN
4578+ D(I)=HP*DEN
4579+ C(I)=HO*DEN
4580+12 CONTINUE
4581+ IF (2*NS.LT.N-M)THEN
4582+ DY=C(NS+1)
4583+ ELSE
4584+ DY=D(NS)
4585+ NS=NS-1
4586+ ENDIF
4587+ Y=Y+DY
4588+13 CONTINUE
4589+ RETURN
4590+ END
4591+
4592+ Function PartonX6 (IPRTN, XX, QQ)
4593+
4594+c Given the parton distribution function in the array U in
4595+c COMMON / PEVLDT / , this routine interpolates to find
4596+c the parton distribution at an arbitray point in x and q.
4597+c
4598+ Implicit Double Precision (A-H,O-Z)
4599+
4600+ Parameter (MXX = 96, MXQ = 20, MXF = 5)
4601+ Parameter (MXQX= MXQ * MXX, MXPQX = MXQX * (MXF+3))
4602+
4603+ Common
4604+ > / CtqPar1 / Al, XV(0:MXX), TV(0:MXQ), UPD(MXPQX)
4605+ > / CtqPar2 / Nx, Nt, NfMx
4606+ > / XQrange / Qini, Qmax, Xmin
4607+
4608+ Dimension fvec(4), fij(4)
4609+ Dimension xvpow(0:mxx)
4610+ Data OneP / 1.00001 /
4611+ Data xpow / 0.3d0 / !**** choice of interpolation variable
4612+ Data nqvec / 4 /
4613+ Data ientry / 0 /
4614+ Save ientry,xvpow
4615+
4616+c store the powers used for interpolation on first call...
4617+ if(ientry .eq. 0) then
4618+ ientry = 1
4619+
4620+ xvpow(0) = 0D0
4621+ do i = 1, nx
4622+ xvpow(i) = xv(i)**xpow
4623+ enddo
4624+ endif
4625+
4626+ X = XX
4627+ Q = QQ
4628+ tt = log(log(Q/Al))
4629+
4630+c ------------- find lower end of interval containing x, i.e.,
4631+c get jx such that xv(jx) .le. x .le. xv(jx+1)...
4632+ JLx = -1
4633+ JU = Nx+1
4634+ 11 If (JU-JLx .GT. 1) Then
4635+ JM = (JU+JLx) / 2
4636+ If (X .Ge. XV(JM)) Then
4637+ JLx = JM
4638+ Else
4639+ JU = JM
4640+ Endif
4641+ Goto 11
4642+ Endif
4643+C Ix 0 1 2 Jx JLx Nx-2 Nx
4644+C |---|---|---|...|---|-x-|---|...|---|---|
4645+C x 0 Xmin x 1
4646+C
4647+ If (JLx .LE. -1) Then
4648+ Print '(A,1pE12.4)', 'Severe error: x <= 0 in PartonX6! x = ', x
4649+ Stop
4650+ ElseIf (JLx .Eq. 0) Then
4651+ Jx = 0
4652+ Elseif (JLx .LE. Nx-2) Then
4653+
4654+C For interrior points, keep x in the middle, as shown above
4655+ Jx = JLx - 1
4656+ Elseif (JLx.Eq.Nx-1 .or. x.LT.OneP) Then
4657+
4658+C We tolerate a slight over-shoot of one (OneP=1.00001),
4659+C perhaps due to roundoff or whatever, but not more than that.
4660+C Keep at least 4 points >= Jx
4661+ Jx = JLx - 2
4662+ Else
4663+ Print '(A,1pE12.4)', 'Severe error: x > 1 in PartonX6! x = ', x
4664+ Stop
4665+ Endif
4666+C ---------- Note: JLx uniquely identifies the x-bin; Jx does not.
4667+
4668+C This is the variable to be interpolated in
4669+ ss = x**xpow
4670+
4671+ If (JLx.Ge.2 .and. JLx.Le.Nx-2) Then
4672+
4673+c initiation work for "interior bins": store the lattice points in s...
4674+ svec1 = xvpow(jx)
4675+ svec2 = xvpow(jx+1)
4676+ svec3 = xvpow(jx+2)
4677+ svec4 = xvpow(jx+3)
4678+
4679+ s12 = svec1 - svec2
4680+ s13 = svec1 - svec3
4681+ s23 = svec2 - svec3
4682+ s24 = svec2 - svec4
4683+ s34 = svec3 - svec4
4684+
4685+ sy2 = ss - svec2
4686+ sy3 = ss - svec3
4687+
4688+c constants needed for interpolating in s at fixed t lattice points...
4689+ const1 = s13/s23
4690+ const2 = s12/s23
4691+ const3 = s34/s23
4692+ const4 = s24/s23
4693+ s1213 = s12 + s13
4694+ s2434 = s24 + s34
4695+ sdet = s12*s34 - s1213*s2434
4696+ tmp = sy2*sy3/sdet
4697+ const5 = (s34*sy2-s2434*sy3)*tmp/s12
4698+ const6 = (s1213*sy2-s12*sy3)*tmp/s34
4699+
4700+ EndIf
4701+
4702+c --------------Now find lower end of interval containing Q, i.e.,
4703+c get jq such that qv(jq) .le. q .le. qv(jq+1)...
4704+ JLq = -1
4705+ JU = NT+1
4706+ 12 If (JU-JLq .GT. 1) Then
4707+ JM = (JU+JLq) / 2
4708+ If (tt .GE. TV(JM)) Then
4709+ JLq = JM
4710+ Else
4711+ JU = JM
4712+ Endif
4713+ Goto 12
4714+ Endif
4715+
4716+ If (JLq .LE. 0) Then
4717+ Jq = 0
4718+ Elseif (JLq .LE. Nt-2) Then
4719+C keep q in the middle, as shown above
4720+ Jq = JLq - 1
4721+ Else
4722+C JLq .GE. Nt-1 case: Keep at least 4 points >= Jq.
4723+ Jq = Nt - 3
4724+
4725+ Endif
4726+C This is the interpolation variable in Q
4727+
4728+ If (JLq.GE.1 .and. JLq.LE.Nt-2) Then
4729+c store the lattice points in t...
4730+ tvec1 = Tv(jq)
4731+ tvec2 = Tv(jq+1)
4732+ tvec3 = Tv(jq+2)
4733+ tvec4 = Tv(jq+3)
4734+
4735+ t12 = tvec1 - tvec2
4736+ t13 = tvec1 - tvec3
4737+ t23 = tvec2 - tvec3
4738+ t24 = tvec2 - tvec4
4739+ t34 = tvec3 - tvec4
4740+
4741+ ty2 = tt - tvec2
4742+ ty3 = tt - tvec3
4743+
4744+ tmp1 = t12 + t13
4745+ tmp2 = t24 + t34
4746+
4747+ tdet = t12*t34 - tmp1*tmp2
4748+
4749+ EndIf
4750+
4751+
4752+c get the pdf function values at the lattice points...
4753+
4754+ If (Iprtn .GE. 3) Then
4755+ Ip = - Iprtn
4756+ Else
4757+ Ip = Iprtn
4758+ EndIf
4759+ jtmp = ((Ip + NfMx)*(NT+1)+(jq-1))*(NX+1)+jx+1
4760+
4761+ Do it = 1, nqvec
4762+
4763+ J1 = jtmp + it*(NX+1)
4764+
4765+ If (Jx .Eq. 0) Then
4766+C For the first 4 x points, interpolate x^2*f(x,Q)
4767+C This applies to the two lowest bins JLx = 0, 1
4768+C We can not put the JLx.eq.1 bin into the "interrior" section
4769+C (as we do for q), since Upd(J1) is undefined.
4770+ fij(1) = 0
4771+ fij(2) = Upd(J1+1) * XV(1)**2
4772+ fij(3) = Upd(J1+2) * XV(2)**2
4773+ fij(4) = Upd(J1+3) * XV(3)**2
4774+C
4775+C Use Polint6 which allows x to be anywhere w.r.t. the grid
4776+
4777+ Call Polint6 (XVpow(0), Fij(1), 4, ss, Fx, Dfx)
4778+
4779+ If (x .GT. 0D0) Fvec(it) = Fx / x**2
4780+C Pdf is undefined for x.eq.0
4781+ ElseIf (JLx .Eq. Nx-1) Then
4782+C This is the highest x bin:
4783+
4784+ Call Polint6 (XVpow(Nx-3), Upd(J1), 4, ss, Fx, Dfx)
4785+
4786+ Fvec(it) = Fx
4787+
4788+ Else
4789+C for all interior points, use Jon's in-line function
4790+C This applied to (JLx.Ge.2 .and. JLx.Le.Nx-2)
4791+ sf2 = Upd(J1+1)
4792+ sf3 = Upd(J1+2)
4793+
4794+ g1 = sf2*const1 - sf3*const2
4795+ g4 = -sf2*const3 + sf3*const4
4796+
4797+ Fvec(it) = (const5*(Upd(J1)-g1)
4798+ & + const6*(Upd(J1+3)-g4)
4799+ & + sf2*sy3 - sf3*sy2) / s23
4800+
4801+ Endif
4802+
4803+ enddo
4804+C We now have the four values Fvec(1:4)
4805+c interpolate in t...
4806+
4807+ If (JLq .LE. 0) Then
4808+C 1st Q-bin, as well as extrapolation to lower Q
4809+ Call Polint6 (TV(0), Fvec(1), 4, tt, ff, Dfq)
4810+
4811+ ElseIf (JLq .GE. Nt-1) Then
4812+C Last Q-bin, as well as extrapolation to higher Q
4813+ Call Polint6 (TV(Nt-3), Fvec(1), 4, tt, ff, Dfq)
4814+ Else
4815+C Interrior bins : (JLq.GE.1 .and. JLq.LE.Nt-2)
4816+C which include JLq.Eq.1 and JLq.Eq.Nt-2, since Upd is defined for
4817+C the full range QV(0:Nt) (in contrast to XV)
4818+ tf2 = fvec(2)
4819+ tf3 = fvec(3)
4820+
4821+ g1 = ( tf2*t13 - tf3*t12) / t23
4822+ g4 = (-tf2*t34 + tf3*t24) / t23
4823+
4824+ h00 = ((t34*ty2-tmp2*ty3)*(fvec(1)-g1)/t12
4825+ & + (tmp1*ty2-t12*ty3)*(fvec(4)-g4)/t34)
4826+
4827+ ff = (h00*ty2*ty3/tdet + tf2*ty3 - tf3*ty2) / t23
4828+ EndIf
4829+
4830+ PartonX6 = ff
4831+
4832+ Return
4833+C ********************
4834+ End
4835
4836=== added file 'Template/NLO/Source/PDF/Partonx5.f'
4837--- Template/NLO/Source/PDF/Partonx5.f 1970-01-01 00:00:00 +0000
4838+++ Template/NLO/Source/PDF/Partonx5.f 2012-09-28 12:29:27 +0000
4839@@ -0,0 +1,94 @@
4840+ FUNCTION PartonX (IPRTN, X, Q)
4841+C
4842+C Given the parton distribution function in the array Upd in
4843+C COMMON / CtqPar1 / , this routine fetches u(fl, x, q) at any value of
4844+C x and q using Mth-order polynomial interpolation for x and Ln(Q/Lambda).
4845+C
4846+ IMPLICIT DOUBLE PRECISION (A-H, O-Z)
4847+C
4848+ PARAMETER (MXX = 105, MXQ = 25, MXF = 6)
4849+ PARAMETER (MXPQX = (MXF *2 +2) * MXQ * MXX)
4850+ PARAMETER (M= 2, M1 = M + 1)
4851+C
4852+ Logical First
4853+ Common
4854+ > / CtqPar1 / Al, XV(0:MXX), QL(0:MXQ), UPD(MXPQX)
4855+ > / CtqPar2 / Nx, Nt, NfMx
4856+ > / XQrange / Qini, Qmax, Xmin
4857+C
4858+ Dimension Fq(M1), Df(M1)
4859+
4860+ Data First /.true./
4861+ save First
4862+C Work with Log (Q)
4863+ QG = LOG (Q/AL)
4864+
4865+C Find lower end of interval containing X
4866+ JL = -1
4867+ JU = Nx+1
4868+ 11 If (JU-JL .GT. 1) Then
4869+ JM = (JU+JL) / 2
4870+ If (X .GT. XV(JM)) Then
4871+ JL = JM
4872+ Else
4873+ JU = JM
4874+ Endif
4875+ Goto 11
4876+ Endif
4877+
4878+ Jx = JL - (M-1)/2
4879+ If (X .lt. Xmin .and. First ) Then
4880+ First = .false.
4881+ Print '(A, 2(1pE12.4))',
4882+ > ' WARNING: X < Xmin, extrapolation used; X, Xmin =', X, Xmin
4883+ If (Jx .LT. 0) Jx = 0
4884+ Elseif (Jx .GT. Nx-M) Then
4885+ Jx = Nx - M
4886+ Endif
4887+C Find the interval where Q lies
4888+ JL = -1
4889+ JU = NT+1
4890+ 12 If (JU-JL .GT. 1) Then
4891+ JM = (JU+JL) / 2
4892+ If (QG .GT. QL(JM)) Then
4893+ JL = JM
4894+ Else
4895+ JU = JM
4896+ Endif
4897+ Goto 12
4898+ Endif
4899+
4900+ Jq = JL - (M-1)/2
4901+ If (Jq .LT. 0) Then
4902+ Jq = 0
4903+ If (Q .lt. Qini) Print '(A, 2(1pE12.4))',
4904+ > ' WARNING: Q < Qini, extrapolation used; Q, Qini =', Q, Qini
4905+ Elseif (Jq .GT. Nt-M) Then
4906+ Jq = Nt - M
4907+ If (Q .gt. Qmax) Print '(A, 2(1pE12.4))',
4908+ > ' WARNING: Q > Qmax, extrapolation used; Q, Qmax =', Q, Qmax
4909+ Endif
4910+
4911+ If (Iprtn .GE. 3) Then
4912+ Ip = - Iprtn
4913+ Else
4914+ Ip = Iprtn
4915+ EndIf
4916+C Find the off-set in the linear array Upd
4917+ JFL = Ip + NfMx
4918+ J0 = (JFL * (NT+1) + Jq) * (NX+1) + Jx
4919+C
4920+C Now interpolate in x for M1 Q's
4921+ Do 21 Iq = 1, M1
4922+ J1 = J0 + (Nx+1)*(Iq-1) + 1
4923+ Call Polint (XV(Jx), Upd(J1), M1, X, Fq(Iq), Df(Iq))
4924+ 21 Continue
4925+C Finish off by interpolating in Q
4926+ Call Polint (QL(Jq), Fq(1), M1, QG, Ftmp, Ddf)
4927+
4928+ PartonX = Ftmp
4929+C
4930+ RETURN
4931+C ****************************
4932+ END
4933+
4934
4935=== added file 'Template/NLO/Source/PDF/PhotonFlux.f'
4936--- Template/NLO/Source/PDF/PhotonFlux.f 1970-01-01 00:00:00 +0000
4937+++ Template/NLO/Source/PDF/PhotonFlux.f 2012-09-28 12:29:27 +0000
4938@@ -0,0 +1,87 @@
4939+c/* ********************************************************* */
4940+c/* Equivalent photon approximation structure function. * */
4941+c/* Improved Weizsaecker-Williams formula * */
4942+c/* V.M.Budnev et al., Phys.Rep. 15C (1975) 181 * */
4943+c/* ********************************************************* */
4944+c provided by Tomasz Pierzchala - UCL
4945+
4946+ real*8 function epa_electron(x,q2max)
4947+ integer i
4948+ real*8 x,phi_f
4949+ real*8 xin
4950+ real*8 alpha
4951+ real*8 f, q2min,q2max
4952+ real*8 PI
4953+ data PI/3.14159265358979323846/
4954+
4955+ data xin/0.511d-3/ !electron mass in GeV
4956+
4957+ alpha = .0072992701
4958+
4959+C // x = omega/E = (E-E')/E
4960+ if (x.lt.1) then
4961+ q2min= xin*xin*x*x/(1-x)
4962+ if(q2min.lt.q2max) then
4963+ f = alpha/2d0/PI*
4964+ & (2d0*xin*xin*x*(-1/q2min+1/q2max)+
4965+ & (2-2d0*x+x*x)/x*dlog(q2max/q2min))
4966+
4967+ else
4968+ f = 0.
4969+ endif
4970+ else
4971+ f= 0.
4972+ endif
4973+c write (*,*) x,dsqrt(q2min),dsqrt(q2max),f
4974+ if (f .lt. 0) f = 0
4975+ epa_electron= f
4976+
4977+ end
4978+
4979+ real*8 function epa_proton(x,q2max)
4980+ integer i
4981+ real*8 x,phi_f
4982+ real*8 xin
4983+ real*8 alpha,qz
4984+ real*8 f, qmi,qma, q2max
4985+ real*8 PI
4986+ data PI/3.14159265358979323846/
4987+
4988+ data xin/0.938/ ! proton mass in GeV
4989+
4990+ alpha = .0072992701
4991+ qz = 0.71
4992+
4993+C // x = omega/E = (E-E')/E
4994+ if (x.lt.1) then
4995+ qmi= xin*xin*x*x/(1-x)
4996+ if(qmi.lt.q2max) then
4997+ f = alpha/PI*(phi_f(x,q2max/qz)-phi_f(x,qmi/qz))*(1-x)/x
4998+ else
4999+ f=0.
5000+ endif
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches