Bugs item #1598349, was opened at 2006-11-17 13:22
Message generated for change (Comment added) made by baoilleach
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=379133&aid=1598349&group_id=23629

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: File Input/Output
Group: v10.9
Status: Closed
Resolution: Invalid
Priority: 5
Private: No
Submitted By: Noel O\'Boyle (baoilleach)
Assigned to: Bob Hanson (hansonr)
Summary: Gaussian Cube File incorrect units

Initial Comment:
Hello Miguel, Bob,

I am trying to visualise isosurfaces of cube files which I have generated 
myself.

Jmol's cube file reader assumes that the cube file units are in Bohrs. However, 
this is only true if the 'number of points' is a negative value. Otherwise, the 
units are Angstroms (this applies to the units of the origin, as well as the 
units of the spacing).

This is described briefly at 
http://local.wasp.uwa.edu.au/~pbourke/dataformats/cube/:
"""
If the sign of the number of voxels in a dimension is positive then the units 
are Angstroms, if negative then Bohr.
"""

I think the behavior is undefined if some of the signs of the 'number of 
voxels' are positive and some are negative (i.e. what units should be used for 
the origin in that case?).

I would very much appreciate if you could fix this.

Regards,
    Noel


----------------------------------------------------------------------

>Comment By: Noel O\'Boyle (baoilleach)
Date: 2006-12-06 09:03

Message:
Logged In: YES 
user_id=850620
Originator: YES

You're absolutely right - apologies for the inconvenience. It was this
input system that I used in the past, and I got mixed up due to reading
different web pages.

Noel

----------------------------------------------------------------------

Comment By: Bob Hanson (hansonr)
Date: 2006-12-05 17:33

Message:
Logged In: YES 
user_id=1082841
Originator: NO

Noel, I know what the problem is. There seems to be confusion (generally)
between "Gaussian Input" and "Gaussian Output" files. Rene Canters just
sent me this link, which I recommend:

http://www.nersc.gov/nusers/resources/software/apps/chemistry/gaussian/g98/00000430.htm

Careful reading indicates that the N<0 business for Bohr/Angstroms is for
the input cards. Later on it says:

Output File Formats

.... All values in the cube file are in atomic units, regardless of the
input units. 

That's the key -- all units in a cube OUTPUT file are atomic units --
Bohr.

A lot of people have been confused by this.

Bob



----------------------------------------------------------------------

Comment By: Noel O\'Boyle (baoilleach)
Date: 2006-12-05 10:29

Message:
Logged In: YES 
user_id=850620
Originator: YES

I cannot say I'm 100% convinced. The problem of course is that Gaussian
haven't published a specification for cube files themselves. I think I
figured out the format (some years ago) by looking at the contents of a
cube file, rather than looking at web pages. I cannot remember however,
whether I was able to make an Angstrom-type cube file using Gaussian's
cubegen itself. In short, if I get my hands on cubegen and am able to
generate an Angstrom-type cube file, I will report back to this bug. In
the meanwhile, since it's only the surface I'm interested in, I will use
the "angstroms" option, or generate my data in bohr, as you suggest.

The code you reference behaves as you describe. However, if you look at
the comments at the start of the code, it describes the specification as I
have described it. :-)
"""
If N1<O the input cube coordinates are assumed 
to be in Bohr, otherwise, they are interpreted as Angstroms (|N1| is used
as 
the number of X-direction points in any case)
"""

Thanks,
   Noel

----------------------------------------------------------------------

Comment By: Bob Hanson (hansonr)
Date: 2006-11-30 20:37

Message:
Logged In: YES 
user_id=1082841
Originator: NO

Noel, 

Ah, yes. Quite a long history this issue has. I'm sorry, but that page you
reference has an error. Somehow, somewhere along the way this specification
was changed, and Gaussian Cube files -- despite the clear indication that
only a negative count should indicate Bohr -- are all in Bohr, even with
the count positive.

Evidence of this is given in the code at
http://ftp.ccl.net/cca/software/SOURCES/C/scarecrow/gcube2plt.c
which reads the files as Bohr even with N > 0. 

I understand your pain. If you are trying to read the file just for its
atom coordinates, you are out of luck; if you are reading the file
specifically for its surface and you can get the coordinates from another
file, try the "angstroms" isosurface option.

Bob Hanson

Bob



----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=379133&aid=1598349&group_id=23629

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Jmol-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-developers

Reply via email to