[chimera-dev] Icosahedral lattice on a sphere
Wei Zhang
zhangwei at umn.edu
Thu Dec 10 13:05:48 PST 2020
Thanks so much Tom for the insights.
I only partially follow the 4th paragraph. I think you mean to map a half
asymmetric unit of a planer icosahedral to an inscribed sphere (if using
the draping analogy). I will be very interested to see what the result
looks like. It sounds like it will take some coding effort.
Thank you!
Wei
On Thu, Dec 10, 2020 at 1:22 AM Tom Goddard <goddard at sonic.net> wrote:
> Hi Wei,
>
> It occurs to me your question about how to make the hkcage hexagons more
> uniform in size when projected to a sphere is closely related to a
> simulation of unstretchable cloth that I tried last week. I've attached a
> picture where I draped a cloth made up of a uniform hexagonal mesh of
> triangles over a sphere (a 100 x 100 grid of triangles). All the
> equilateral triangles of the cloth surface keep exactly their same size.
> Of course the cloth billows and ripples to cover the sphere. This is just
> another way of seeing that the hkcage hexagons that are exactly of uniform
> size on the icosahedral surface with its 20 flat triangular faces cannot be
> mapped onto a sphere while keeping all the hexagons the same size, since
> the sphere has curvature and the triangle faces of the icosahedron are flat.
>
> But this also suggests a way to get a more uniform size of the hkcage
> hexagons on a sphere. The cloth doesn't conform to the sphere because the
> circle of radius r from the center of the flat cloth has too large a
> circumference to hug the sphere tightly, it has to ripple. So how about I
> just uniformly shrink the circle of radius r in the cloth so it matches the
> circumference of the sphere? My cloth triangles won't be equilateral
> anymore but will be as close as I can get.
>
> We could do the same thing with the flat mesh made by hkcage on an
> icosahedron, about each 5-fold vertex. At a 5-fold vertex there are 5
> equilateral triangles of an icosahedron, each with 60 degree angles, so 300
> degrees along the cone surface about the 5-fold axis. Flattened on the
> sphere that needs to become 360 degrees. The idea is to map polar
> coordinates on the flat icosahedron centered on the 5-fold vertex to polar
> coordinates on the sphere. The 300 degree angle will be expanded uniformly
> to 360 degrees. But unlike the draping cloth we also need to map the
> radius from the icosahedral 5-face cone to the sphere in a special way that
> depends on the angle if we want the sphere mesh to have exact icosahedral
> symmetry. The radius mapping along a ray towards the 3-fold axes and the
> 2-fold axes nearest the 5-fold will be different. One idea is to take the
> flat triangle formed by neighbor 5-fold, 2-fold and 3-fold axes (there are
> 120 such triangles) and map it to the spherical triangle where those 3 axes
> intersect the sphere. I already described how to map the polar angle (30
> degrees -> 36 degrees), and for the radius we could map the line segment
> from 5-fold triangle vertex to a point in the triangle edge between 2-fold
> and 3-fold vertices so it is uniformly stretched to the longer arc on the
> spherical triangle, ie the arc where the sphere intersects the plane
> through the sphere radius, 5-fold vertex, and point on the 2-fold to 3-fold
> triangle edge.
>
> That description was probably a bit hard to follow, but basically it
> maps the flat icosahedron triangle bounded by 5-fold, 2-fold and 3-fold
> vertices to an equivalent spherical triangle trying to preserve uniformity
> of angles about the 5-fold axis, and also uniform stretch along rays. The
> math to do that mapping is probably a page or two of Python code. It would
> be interesting to see what the result would look like. I would expect the
> hkcage hexagons would have more uniform overall size but they will be
> skewed somewhat.
>
> Tom
>
>
>
> On Dec 9, 2020, at 8:28 PM, Wei Zhang <zhangwei at umn.edu> wrote:
>
> Hi Tom,
>
> Thanks so much. I have found the Python file of Chimera on linux. I
> currently do not have ChimeraX yet.
> I think if one version can be worked out, it is not too hard to make the
> other version working.
> I do not know Python. I would need to ask my collaborator to look into
> the code.
>
> I am thinking for the cases k=0, or h=k, It is not too hard to implement a
> spherical icosahedral cage.
> This is the diagram for a planner icosahedron definition:
> <Screen Shot 2020-12-09 at 9.02.59 PM.png>
> We just need to think the H axis is an arc between two neighboring 5 fold
> vertices, and K is another arc connecting the origin and the other nearby 5
> fold vertice. So the positions of 1, 2, 3, 4 ... would be defined by angles
> or length on the arc, rather than the length on the line connecting the two
> 5-fold points.
>
> A quick test can be made by modifying the code of this routine (Linux
> Chimera): Tools => Higher-order Structure => Icosahedron Surfaces. When the
> sphere factor = 1. The subdivision can be considered to be a subdivision of
> the arc that connects two 5 folds. I am not sure what is the best method to
> draw the lattice lines when the sphere factor is >0 and less than 1, some
> kind of interpolation function has to be developed.
>
> I do not know how to handle the cases of skewed icosahedron either, ie. h
> and k are different. It seems very difficult to define the references
> points and determine how to draw those parallel lines on the spherical
> surface. I am thinking we have to start with a big spherical triangle.
> <Screen Shot 2020-12-09 at 9.56.03 PM.png>
> For example, if we want to define h=3, k=2 lattice (red triangle), we need
> to draw arcs on a sphere according to the purple triangle. The question is
> if we think the red triangle is the outline of a spherical triangle of
> three 5-fold vertices, where the vertices of the purple triangle are. The
> current version of Chimera can draw any icosahedral lattice beautifully. I
> think this must have been worked out for the planner cases. The python code
> must have some clues. I have to think about it more.
>
> Best regards,
>
> Wei
>
>
>
>
>
>
>
> On Wed, Dec 9, 2020 at 5:48 PM Tom Goddard <goddard at sonic.net> wrote:
>
>> Hi Wei,
>>
>> You are right the Chimera and ChimeraX hkcage command "sphere" option
>> simply moves the cage vertices outward to lie on a sphere. The sphere
>> passes through the 12 vertices of a plain icosahedron so those 12 vertices
>> don't get moved. But the midpoint of one of the triangular faces of the
>> icosahedron is at radius 0.79 (= sqrt( (1+2/sqrt(5))/3 )) if the vertices
>> are at radius 1 (ie the ratio of inner icosahedron radius to outer radius
>> is 0.79) so projecting a shape near the middle of a triangular icosahedron
>> face will expand its size by 21% relative to if it is near an icosahedron
>> vertex.
>>
>> It is an interesting problem to try to reduce that distortion. It
>> looks impossible to remove it. For that you would need an isometric map
>> from an icosahedron triangle to a spherical triangle, but no such isometry
>> exists since the triangle is flat and the sphere has curvature 1/R. Let me
>> know what you figure out.
>>
>> The code for computing the cages in Chimera is all Python and is in
>> your Chimera distribution, on Linux it is here
>>
>> chimera/share/IcosahedralCage/cages.py
>>
>> You would be better off working on the successor of Chimera, called
>> ChimeraX. If you improve hkcage we won't update Chimera as we no longer
>> add new features to it since all development is on ChimeraX. The ChimeraX
>> hkcage command is in the ChimeraX distribution, on Linux it is here
>>
>> chimerax/lib/python3.8/site-packages/chimerax/hkcage/cage.py
>>
>> Tom
>>
>>
>>
>>
>> On Dec 8, 2020, at 6:58 PM, Wei Zhang <zhangwei at umn.edu> wrote:
>>
>> Hello,
>>
>> I use the command hkcage to generate an icosahedral lattice on a sphere:
>>
>> hkcage 5 7 sphere 1
>>
>> However, this only expands the strict icosahedral lattice (ie when using
>> sphere=0) radially to match a spherical surface. As a result, the sizes of
>> the hexagons and pentagons are not the same. The effect would be very
>> dramatic if the parameter sphere is larger than 1.
>>
>> I am wondering if the code can be modified to generate a truly
>> icosahedral lattice on a spherical surface, or if that piece of code is
>> open to access?
>>
>> Thank you and best regards,
>>
>> Wei
>>
>> _______________________________________________
>> Chimera-dev mailing list
>> Chimera-dev at cgl.ucsf.edu
>> https://www.rbvi.ucsf.edu/mailman/listinfo/chimera-dev
>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-dev/attachments/20201210/20a0bd93/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: helmet.png
Type: image/png
Size: 411700 bytes
Desc: not available
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-dev/attachments/20201210/20a0bd93/attachment-0001.png>
More information about the Chimera-dev
mailing list