Print transformed Cartesian coordinates by default.

If you have a suggestion and a plan for implementing it, please file an issue on the Dalton or LSDalton GitLab. Otherwise, feel free to discuss it here first.
Post Reply
wildcat
Posts: 4
Joined: 07 Apr 2014, 10:28
First name(s): Anton
Last name(s): Simakov
Affiliation: CTCC, UiO
Country: Russian Federation

Print transformed Cartesian coordinates by default.

Post by wildcat » 23 Sep 2014, 15:51

At the very begging of execution Dalton centers an input molecule at center of mass and rotates it so principal axes of inertia are along coordinate axes. Obviously, these transformed coordinates are very important since all the calculations are then done in this transformed coordinate system. I'm trying visualize the molecule from the output and suddenly I found that transformed Cartesian coordinates are not always printed out.

As far as I can tell the condition for them to be printed is given in DALTON/abacus/herrdn.F file at lines 4591-4598

Code: Select all

      IPTEST = MIN(NUCDEP/13,2)
C     hjaaj: x,y,z normally only interesting for
C            small molecules, otherwise just a lot of lines.
      IF (QMMM .OR. PEQM) IPTEST = 0
      IF ( IPREAD .GT. IPTEST )  THEN
         CALL HEADER('Cartesian Coordinates (a.u.)',1)
         WRITE (LUPRI,'(A,I5)')'  Total number of coordinates:',NCOOR
      END IF
and in my opinion this behavior is quite strange for few reasons out of which the following two are most important
  • Consistency: the information to be printed should depend on print level only, there should be no difference due to the size of a molecule. Even the very artificiality of the condition in the code above involving some "magic numbers" proves this point.
  • Usefulness: these coordinates are very interesting and important if you want to visualize a molecule in the coordinate system in which calculations are actually done.
I understand that in principle I could recover these coordinates from Symmetry Independent Centres which are always printed in the output, but this would require some additional and non-trivial (at least for me) work. So, taking into account almost zero performance impact (printing even few thousands of lines should account for just a fraction of a microsecond) I would like Dalton to always print Cartesian coordinates of a molecule after it was centered and rotated.

And I understand that I could comment this IF conditional by myself to always print these Cartesian coordinates, but I would like it to be the default behaviour, because it makes writing visualization software much easier. Note that when I say by default here and in the title I mean already at the lowest possible print level.

kennethruud
Posts: 252
Joined: 27 Aug 2013, 16:42
First name(s): Kenneth
Last name(s): Ruud
Affiliation: UiT The Arctic University of Norway
Country: Norway

Re: Print transformed Cartesian coordinates by default.

Post by kennethruud » 23 Sep 2014, 18:15

Hi, and thanks for your input, the Dalton authors will consider this for future releases.

Let me perhaps note that the issue of why it is not always printed is not so much a matter of impact on the performance of the code as it is readability of the output (for humans) and thus avoiding duplication of information. This is particularly relevant when molecules become large and contain a large number of atoms. I should note that Dalton provides a few other files, see pages 36-38 in the panel. This are made for more automated processing and not meant to be directly used by users.


Best regards,

Kenneth

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests