Re: AW: vmd-l: Occupancy maps

From: Axel Kohlmeyer (akohlmey_at_gmail.com)
Date: Mon Aug 12 2013 - 01:14:52 CDT

On Mon, Aug 12, 2013 at 7:14 AM, Norman Geist
<norman.geist_at_uni-greifswald.de> wrote:
> Hi Andrei,
>
> I'm was working with dx files just a week ago and so already know your
> questions. I was writing a script creating own dx files to visualize the
> temperature distribution through the simulation cell. You can just stay with
> the header like it is. Just put in your own origin(simply the minmax lower
> bounds) and delta values, aswell as a title for the data at the bottom of
> the file. The delta scaling factors usually just give the spacing between

the dx format as VMD reads it is described here:
http://www.ks.uiuc.edu/Research/vmd/plugins/molfile/dxplugin.html

> the grid points. As dx is a scalar format, you do not need to save the
> coordinates for each point in this way and so save a lot of disk space. To
> be able to translate the grid points to cartesian coordinates again, to
> visualize it, you need the scaling factors, which will also point to the
> right box size if multiplied by gridsize. The delta values are computed for
> each dimension from boxsize/gridsize. But, for some reason I didn't
> understand so far, VMD will compute the box size from delta*(gridsize-1).

i already explained that VMD expects a "general" and not a "periodic"
grid, i.e. the file is providing data for all corners of the described
voxels. that means for a single voxel, you need 8 (= 2x2x2) points,
for 8 (2x2x2) voxels correspondingly 27 (=3x3x3) grid points. for a
periodic data set, the values at the extremes are identical, for a
non-periodic data set, they are not.
is this so difficult to understand? where is the problem?

axel.

> Therefore if you create own dx file and want the "volslice" to correctly fit
> with the box bounds and the atoms, compute the delta from
> boxsize/(gridsize-1) aswell.
>
> Im not sure if you understood the data block correctly.
>
>> 0 0 0 -> x0 y0 z0
>> 0 0 0 -> x0 y0 z1
>
> I guess you meant:
>
>> 0 -> x0 y0 z0
>> 0 -> x0 y0 z1
>
> Or:
>
>> 0 0 -> (x0 y0 z0) (x0 y0 z1)
>
> The data values will just follow each other. Every number represents one
> gridpoint, there are no coordinates. I guess the maximum number of points
> per line was hardcoded in VMD to five. One value per line would also be
> possible and valid.The Z rows, as you pointed out raises 1st, then Y. This
> means for a 2x2x2 grid, the data section would look like:
>
> 1.2 3.2 5.09 7.32 9.52 -> (x0 y0 z0) (x0 y0 z1) (x0 y1 z0) (x0 y1
> z1) (x1 y0 z0)
> 4.8 7.2 8.4 -> (x1 y0 z1) (x1 y1 z0) (x1 y1 z1)
>
> Good luck
>
> Norman Geist.
>
>> -----Ursprüngliche Nachricht-----
>> Von: owner-vmd-l_at_ks.uiuc.edu [mailto:owner-vmd-l_at_ks.uiuc.edu] Im
>> Auftrag von Andrei Tudor
>> Gesendet: Freitag, 9. August 2013 18:27
>> An: vmd-l_at_ks.uiuc.edu
>> Betreff: vmd-l: Occupancy maps
>>
>> Hello,
>>
>> I am trying to understand the dx files that are made by volmap. This is
>> what I understand until now:
>>
>> [header]
>> header info like origin etc
>> [/header]
>>
>> [data]
>> 0 0 0 -> x0 y0 z0
>> 0 0 0 -> x0 y0 z1
>> 0 0 0 -> x0 y0 z2
>> 0.001294 0 0 -> x0 y0 z3
>>
>> (...)
>>
>> 0 0 0 -> x0 y1 z0
>> 0 0 0 -> x0 y1 z1
>>
>> (...)
>>
>> [/data]
>>
>> So each row of data represents a point on the grid and they are
>> described as I have shown here.
>> This is how I understood that dx works.
>> What I didn't understand is what is represented in each point as 0 0 0.
>> For example, on the row (0.001294 0 0) what does 0.001294 represent?
>>
>> Thank you,
>> Andrei
>
>

-- 
Dr. Axel Kohlmeyer  akohlmey_at_gmail.com  http://goo.gl/1wk0
International Centre for Theoretical Physics, Trieste. Italy.

This archive was generated by hypermail 2.1.6 : Tue Dec 31 2013 - 23:23:33 CST