<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi Wei,<div class=""><br class=""></div><div class=""> 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.</div><div class=""><br class=""></div><div class=""> 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.</div><div class=""><br class=""></div><div class=""> The code for computing the cages in Chimera is all Python and is in your Chimera distribution, on Linux it is here</div><div class=""><br class=""></div><div class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>chimera/share/IcosahedralCage/cages.py</span></div></div><div class=""><br class=""></div><div class="">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</div><div class=""><br class=""></div><div class=""><span class="Apple-tab-span" style="white-space:pre"> </span><span style="font-family: Menlo; font-size: 11px;" class="">chimerax/lib/python3.8/site-packages/chimerax/hkcage/cage.py</span></div><div class=""><br class=""></div><div class=""> Tom</div><div class=""><br class=""><div class=""><br class=""></div><div class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 8, 2020, at 6:58 PM, Wei Zhang <<a href="mailto:zhangwei@umn.edu" class="">zhangwei@umn.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Hello,<div class=""><br class=""></div><div class="">I use the command <font color="#0000ff" class="">hkcage</font> to generate an icosahedral lattice on a sphere:</div><div class=""><br class=""></div><div class=""><font color="#0000ff" class="">hkcage 5 7 sphere 1</font></div><div class=""><br class=""></div><div class="">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. </div><div class=""><br class=""></div><div class="">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?</div><div class=""><br class=""></div><div class="">Thank you and best regards,</div><div class=""><br class=""></div><div class="">Wei</div><div class=""><br class=""></div></div>
_______________________________________________<br class="">Chimera-dev mailing list<br class=""><a href="mailto:Chimera-dev@cgl.ucsf.edu" class="">Chimera-dev@cgl.ucsf.edu</a><br class="">https://plato.cgl.ucsf.edu/mailman/listinfo/chimera-dev<br class=""></div></blockquote></div><br class=""></div></div></body></html>