[CPMD-list] constraints

Phineus Markwick markwick at NMR.EMBL-Heidelberg.DE
Fri Nov 1 18:59:42 CET 2002


Hallo cpmd-list,

I am trying to program a new type of constraint in cpmd. As it is a 
quasi-distance constraint (based on several multiple distances), I have 
followed in principle the distance constraint program that already exists.

I introduce the new constraint in CONINP.F, defining the name of the new 
constraint and the atomic numbers that occur in the input line, the 
constraint "distance" and the LSHOVE value.

In CNSTFC.F, I call the program FILLC(...) to read in the appropriate 
atomic coordinates, and then call the two constraint subroutines that 
are in CONSTR.F (funcconstraint.F and diffconstraint.F).

In CONSTR.F I have already introduced the two new subroutines 
funcconstraint and diffconstraint.

When I run cpmd with the new constraint, the program happliy runs 
through CONINP.F, CNSTFC.F and CONSTR.F. The program reads in all the 
atomic coordinates and runs through the two subroutines funccontraint 
and diffconstraint.

Using the same terminology as in the existing constraint subroutines 
funcd and diffd, my new constraint subroutines generate both fd (fd 
=d-RO, the difference between the actual distance and the constraint 
distance) and the vector dR.
At this point the program immediately stops with the error output:


forrtl: error (75): floating point exception
    0: __FINI_00_remove_gp_range [0x3ff81a6de38]
    1: __FINI_00_remove_gp_range [0x3ff81a76e60]
    2: __FINI_00_remove_gp_range [0x3ff800d5120]
    3: cnstfc_ [./cnstfc.f: 118, 0x1201cb028]
    4: detdof_ [./detdof.f: 191, 0x1201c9b10]
    5: mdmain_ [./mdmain.f: 119, 0x1201daa00]
    6: mdpt_ [./mdpt.f: 124, 0x1201d9ff0]
    7: cpmd_ [./cpmd.f: 120, 0x12003dac4]
    8: cpmd_stuttgart_ [./cpmd.f: 3, 0x12003d590]
    9: main [for_main.c: 203, 0x1203fc66c]
   10: __start [0x12003d3b8]
time: command terminated abnormally.

real   15.8
user   3.0
sys    2.6

The last line in the output file is the number of degrees of 
freedom.(which is correct).

This error message suggests to me that at some point the program is 
being asked to do something stupid like divide some number by zero.
This is not occuring in the two subroutines funcconstraint and 
diffconstraint, but at some later point in the program. The only two new 
variables generated by these two programs are fd and the vector dR, and 
these seem to be O.K.

So, are there any other programs that I need to edit or introduce?

In particular, I am concerned by the fact that for this new constraint, 
I have at no point defined either fd or dR other than to state that they 
exist as variables in the programs funcconstraint and diffconstraint.

I would appreciate any help or comments,
best regards,
Phineus Markwick.




More information about the CPMD-list mailing list