Re: [Jmol-users] Polyhedra with 12 or 20 vertices

2007-06-13 Thread Dean Johnston
OK, I see that the POLYHEDRA command is really overkill for what I'm trying
to do.  I could essentially create my own polyhedral representations if the
DRAW command was extended to allow the drawing of planes with an arbitrary
number of vertices so that I could create triangles, pentagons, etc. as
needed.  Should I submit this as a feature request???

Dean


On 6/9/07 12:51 AM, Bob Hanson [EMAIL PROTECTED] wrote:

 Dean, sounds like you might appreciate:
 http://www.scienceu.com/geometry/facts/solids/coords/
 
 Well, ah, let's just say it doesn't work the way you probably think it
 does. The polyhedra code is a very complex algorithm that looks at
 possible faces (combinations of three atoms around a central atom) and
 determines which are faces and which are not. We have:
 
 #atoms comb of 3 at a time
 4 4!/(3!)(1!) = 4
 6 6!/3!3! = 20
 8 8!/3!5! = 56
 9 9!/3!6! = 84
 12 12!/3!9! = 220
 20 20!/3!17! = 1140
 ...
 n n(n-1)(n-2)/6
 
 so if you do nothing special, then you will possibly run into the
 problem with any number more than 9. HOWEVER, the algorithm has a
 parameter, distanceFactor, that is adjustable, and if you set it
 smaller, it will work. For example (That second line should not wrap), try:
 
 13
 #jmolscript: connect (*) (*) delete;connect (_Fe) (_C);select
 *;wireframe off;spacefill off;select (_Fe); polyhedra bonds
 distanceFactor 0.5
 Fe 0 0 0
 C -0.692 0.000 0.427
 C 0.000 0.427 -0.692
 C 0.000 0.427 0.692
 C 0.692 0.000 -0.427
 C -0.427 -0.692 0.000
 C -0.427 0.692 0.000
 C 0.000 -0.427 0.692
 C 0.427 0.692 0.000
 C 0.000 -0.427 -0.692
 C 0.692 0.000 0.427
 C 0.427 -0.692 0.000
 C -0.692 0.000 -0.427
 
 As for dodecahedra, that's just too large. I've upped the maximum number
 of faces to 147, and that takes care of it, but there are a few stray
 lines, since we are painting more triangles than actually needed. Just
 the way it goes, I guess
 
 
 
 Bob

 
 
 Dean Johnston wrote:
 
 Has anybody tried to create polyhedra with 12 or 20 vertices? The
 documentation seems to indicate that I should be able to go up to 20.
 
 I¹m creating representations of shapes (Platonic solids, actually ‹
 maybe Jmol isn¹t just for molecules anymore... :-). I would like to
 display an icosahedron and dodecahedron. I¹ve created structures with
 a central atom surrounded by 12 or 20 atoms, but when I try and create
 the polyhedron, I get the following error message:
 
 Polyhedron error: maximum face(87) -- reduce RADIUS
 
 I have a feeling it¹s creating more polyhedra faces than I want it to
 (I only want 20), but I¹m not entirely familiar with how it works.
 I¹ve gotten it to work just fine for tetrahedra and octahedra. Any
 insights, corrections, etc. are greatly appreciated.
 
 My testing page is at:
 http://www.otterbein.edu/home/fac/dnhjhns/jmoltest/poly.html
 
 Dean
 
 
 
 -




-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Polyhedra with 12 or 20 vertices

2007-06-13 Thread Bob Hanson
Dean Johnston wrote:

OK, I see that the POLYHEDRA command is really overkill for what I'm trying
to do.  I could essentially create my own polyhedral representations if the
DRAW command was extended to allow the drawing of planes with an arbitrary
number of vertices so that I could create triangles, pentagons, etc. as
needed.  Should I submit this as a feature request???

  

Yes, but don't hold your breath. It isn't core Jmol to be drawing random 
objects. If you really want to do it with Jmol, think about ways you can 
do it yourself with Jmol and triangles/quadrilaterals, and you will get 
there faster. You can load a file of coordinates and work with it to 
draw just about anything you want, provided the objects are triangles or 
quadrilaterals. Pmesh is another command that comes to mind.

Bob



Dean


On 6/9/07 12:51 AM, Bob Hanson [EMAIL PROTECTED] wrote:

  

Dean, sounds like you might appreciate:
http://www.scienceu.com/geometry/facts/solids/coords/

Well, ah, let's just say it doesn't work the way you probably think it
does. The polyhedra code is a very complex algorithm that looks at
possible faces (combinations of three atoms around a central atom) and
determines which are faces and which are not. We have:

#atoms comb of 3 at a time
4 4!/(3!)(1!) = 4
6 6!/3!3! = 20
8 8!/3!5! = 56
9 9!/3!6! = 84
12 12!/3!9! = 220
20 20!/3!17! = 1140
...
n n(n-1)(n-2)/6

so if you do nothing special, then you will possibly run into the
problem with any number more than 9. HOWEVER, the algorithm has a
parameter, distanceFactor, that is adjustable, and if you set it
smaller, it will work. For example (That second line should not wrap), try:

13
#jmolscript: connect (*) (*) delete;connect (_Fe) (_C);select
*;wireframe off;spacefill off;select (_Fe); polyhedra bonds
distanceFactor 0.5
Fe 0 0 0
C -0.692 0.000 0.427
C 0.000 0.427 -0.692
C 0.000 0.427 0.692
C 0.692 0.000 -0.427
C -0.427 -0.692 0.000
C -0.427 0.692 0.000
C 0.000 -0.427 0.692
C 0.427 0.692 0.000
C 0.000 -0.427 -0.692
C 0.692 0.000 0.427
C 0.427 -0.692 0.000
C -0.692 0.000 -0.427

As for dodecahedra, that's just too large. I've upped the maximum number
of faces to 147, and that takes care of it, but there are a few stray
lines, since we are painting more triangles than actually needed. Just
the way it goes, I guess



Bob



  

Dean Johnston wrote:



Has anybody tried to create polyhedra with 12 or 20 vertices? The
documentation seems to indicate that I should be able to go up to 20.

I¹m creating representations of shapes (Platonic solids, actually ‹
maybe Jmol isn¹t just for molecules anymore... :-). I would like to
display an icosahedron and dodecahedron. I¹ve created structures with
a central atom surrounded by 12 or 20 atoms, but when I try and create
the polyhedron, I get the following error message:

Polyhedron error: maximum face(87) -- reduce RADIUS

I have a feeling it¹s creating more polyhedra faces than I want it to
(I only want 20), but I¹m not entirely familiar with how it works.
I¹ve gotten it to work just fine for tetrahedra and octahedra. Any
insights, corrections, etc. are greatly appreciated.

My testing page is at:
http://www.otterbein.edu/home/fac/dnhjhns/jmoltest/poly.html

Dean



-
  





-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users
  



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Polyhedra with 12 or 20 vertices

2007-06-13 Thread Dean Johnston
On 6/13/07 12:38 PM, Bob Hanson [EMAIL PROTECTED] wrote:

 Yes, but don't hold your breath. It isn't core Jmol to be drawing random
 objects. If you really want to do it with Jmol, think about ways you can
 do it yourself with Jmol and triangles/quadrilaterals, and you will get
 there faster. You can load a file of coordinates and work with it to
 draw just about anything you want, provided the objects are triangles or
 quadrilaterals. Pmesh is another command that comes to mind.
 
 Bob
  Triangles and quadrilaterals will do just fine - for some reason I had the
PLANE keyword in my DRAW commands, so I forgot that triangles were that
easy.  Thanks!

Dean



 Dean Johnston wrote:
 
 OK, I see that the POLYHEDRA command is really overkill for what I'm trying
 to do.  I could essentially create my own polyhedral representations if the
 DRAW command was extended to allow the drawing of planes with an arbitrary
 number of vertices so that I could create triangles, pentagons, etc. as
 needed.  Should I submit this as a feature request???



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


[Jmol-users] Polyhedra with 12 or 20 vertices

2007-06-08 Thread Dean Johnston
Has anybody tried to create polyhedra with 12 or 20 vertices?  The
documentation seems to indicate that I should be able to go up to 20.

I¹m creating representations of shapes (Platonic solids, actually ‹ maybe
Jmol isn¹t just for molecules anymore...  :-). I would like to display an
icosahedron and dodecahedron.  I¹ve created structures with a central atom
surrounded by 12 or 20 atoms, but when I try and create the polyhedron, I
get the following error message:

  Polyhedron error: maximum face(87) -- reduce RADIUS

I have a feeling it¹s creating more polyhedra faces than I want it to (I
only want 20), but I¹m not entirely familiar with how it works.  I¹ve gotten
it to work just fine for tetrahedra and octahedra.  Any insights,
corrections, etc. are greatly appreciated.

My testing page is at:
http://www.otterbein.edu/home/fac/dnhjhns/jmoltest/poly.html

Dean
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Polyhedra with 12 or 20 vertices

2007-06-08 Thread Bob Hanson
Dean, sounds like you might appreciate: 
http://www.scienceu.com/geometry/facts/solids/coords/

Well, ah, let's just say it doesn't work the way you probably think it 
does. The polyhedra code is a very complex algorithm that looks at 
possible faces (combinations of three atoms around a central atom) and 
determines which are faces and which are not. We have:

#atoms comb of 3 at a time
4 4!/(3!)(1!) = 4
6 6!/3!3! = 20
8 8!/3!5! = 56
9 9!/3!6! = 84
12 12!/3!9! = 220
20 20!/3!17! = 1140
...
n n(n-1)(n-2)/6

so if you do nothing special, then you will possibly run into the 
problem with any number more than 9. HOWEVER, the algorithm has a 
parameter, distanceFactor, that is adjustable, and if you set it 
smaller, it will work. For example (That second line should not wrap), try:

13
#jmolscript: connect (*) (*) delete;connect (_Fe) (_C);select 
*;wireframe off;spacefill off;select (_Fe); polyhedra bonds 
distanceFactor 0.5
Fe 0 0 0
C -0.692 0.000 0.427
C 0.000 0.427 -0.692
C 0.000 0.427 0.692
C 0.692 0.000 -0.427
C -0.427 -0.692 0.000
C -0.427 0.692 0.000
C 0.000 -0.427 0.692
C 0.427 0.692 0.000
C 0.000 -0.427 -0.692
C 0.692 0.000 0.427
C 0.427 -0.692 0.000
C -0.692 0.000 -0.427

As for dodecahedra, that's just too large. I've upped the maximum number 
of faces to 147, and that takes care of it, but there are a few stray 
lines, since we are painting more triangles than actually needed. Just 
the way it goes, I guess



Bob








Dean Johnston wrote:

 Has anybody tried to create polyhedra with 12 or 20 vertices? The 
 documentation seems to indicate that I should be able to go up to 20.

 I’m creating representations of shapes (Platonic solids, actually — 
 maybe Jmol isn’t just for molecules anymore... :-). I would like to 
 display an icosahedron and dodecahedron. I’ve created structures with 
 a central atom surrounded by 12 or 20 atoms, but when I try and create 
 the polyhedron, I get the following error message:

 Polyhedron error: maximum face(87) -- reduce RADIUS

 I have a feeling it’s creating more polyhedra faces than I want it to 
 (I only want 20), but I’m not entirely familiar with how it works. 
 I’ve gotten it to work just fine for tetrahedra and octahedra. Any 
 insights, corrections, etc. are greatly appreciated.

 My testing page is at: 
 http://www.otterbein.edu/home/fac/dnhjhns/jmoltest/poly.html

 Dean



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/



___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users
  



-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr


If nature does not answer first what we want,
it is better to take what answer we get. 

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users