Outputting cell information and fractional coordinates

Matthias Krack matthia... at psi.ch
Thu Jan 30 09:07:34 UTC 2014

Hi FX,

you are right, the information about the alignment of the cell with respect 
to the Cartesian axes is lost. Thus it is currently not possible to 
retrieve the scaled coordinates for an atomic configuration in an unique 
manner from the dcd file information involving non-orthorhombic cells. This 
is however something which could be fixed. CP2K adopts a common convention 
for the cell alignment when an explicit cell vector definition is not 
available, namely, the cell vector *a* is aligned with the x axis and the 
cell vectors *a* and *b* lie in the xy plane. I think this convention could 
also be applied in this case and the Cartesian coordinates could be dumped 
only after the cell has been mapped to this representation using scaled 


On Wednesday, January 29, 2014 10:51:04 PM UTC+1, fxc... at gmail.com wrote:
> Hi all,
> I'm going back to this issue of outputting cell information.
> I could provide a dumpdcd code for CP2K output files in DCD format. Atomic 
>> labels are added if a prototype XYZ file is provided. It has also some 
>> additional features like frame selection (first/last dumped frame, stride), 
>> an optional application of PBC boundary conditions and a dump of all 
>> out-of-box atoms. I use often the DCD format, because it allows the 
>> consideration of the cell information e.g. VMD. I would put the code into 
>> the cp2k/tools folder in case you are interested.
> Yes, I know how to use DCD format, but I'm not so sure it contains all the 
> information from the simulation. Only the (a,b,c,alpha,beta,gamma) 
> information is written out, but not the actual unit cell matrix (h). Which 
> means, unless a alignment is chosen and coordinates are rotated before 
> being written to the DCD file (and from reading the source in 
> particle_types.F, it doesn't look the case), some information is lost and 
> there is no way to obtain fractional coordinates from the existing output 
> format.
> Or am I missing something?
> FX
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cp2k.org/archives/cp2k-user/attachments/20140130/88978652/attachment.htm>

More information about the CP2K-user mailing list