[Octopus-users] abnormality in the work of the parser
xavier at tddft.org
Wed Jul 2 13:48:14 WEST 2008
Thanks for your report, this is certainly a bug, I will have a look at it,
but probably the solution will be to forbid having a variable defined
On Sat, 28 Jun 2008, ??????? ?.?. wrote:
> Dear developers,
> There seem to exist an abnormality in the work of the parser (in Octopus 3.0.1).
> Namely, let the input file have the form
> Units = eV_Angstrom
> 'H' | 1.0 | spec_ps_psf | 1 | 1 | 1
> 'H' | -rHH/2 | 0.0 | 0.0 | no
> 'H' | rHH/2 | 0.0 | 0.0 | no
> BoxShape = cylinder
> Radius = r_H
> Xlength = rHH/2+r_H
> Spacing = 0.1
> CalculationMode = gs
> , and we run it as follows:
> export OCT_PARSE_ENV=1
> export OCT_rHH=1.6
> ../src/main/octopus 2>>gs.err 1|tee gs.lst
> ; then in exec/out.oct we obtain
> Opened block 'Coordinates'
> (0, 1) = -0.8
> (1, 1) = 0.8
> xlength = 4.35
> - xlength = 4.0+0.7/2 = 4.35 instead of 4.0+1.6/2 = 4.8;
> i.e., when calculating coordinates, it uses the exported value
> (as one could expect), but when calculating Xlength, it uses the old value
> (which is not what the user intented).
> If we comment out the assignment to rHH in the input file,
> or hold the original input file under different name and modify the input file
> in a cylcle over rHH, e.g.,
> cat h2.inp |sed 's_rHH=0.7_rHH='$rHH'_' >inp
> , we obtain the desirable values: coordinates - +-0.8, and xlength = 4.8 .
> With best regards Igor.
> Octopus-users mailing list
> Octopus-users at tddft.org
More information about the Octopus-users