top of page

Karagol-Ramachandran Plots: Extending Conformational Analysis Beyond the Carbon World

  • Writer: Alper KARAGÖL
    Alper KARAGÖL
  • Mar 11
  • 3 min read

When carbon gives way to silicon, the classic conformational analysis tools fall silent. Here is how we adapted one of structural biology's most iconic plots for a new class of polymers — and packaged it for anyone to use.


The Ramachandran plot has guided structural biology for over sixty years. By mapping the two backbone dihedral angles φ and ψ for every residue in a protein, it reveals at a glance whether a structure is sterically plausible, which secondary structures are present, and where unusual conformations lurk.


But the tool is built entirely around protein chemistry. The GROMACS command gmx rama works by searching for atoms named N, CA, and C — the nitrogen, alpha-carbon, and carbonyl carbon of the peptide backbone. In a silicon-backbone polymer, none of those atoms exist. Running gmx rama on such a system either crashes or returns empty output.


Strip away the chemistry and the Ramachandran plot is really just a two-dimensional histogram of consecutive dihedral angles along a backbone chain. In a protein, the heterogeneous backbone (N–Cα–C repeating unit) means two distinct dihedrals naturally arise per residue. In a homogeneous silicon chain, every backbone atom is the same element, so there is no natural "residue boundary" to anchor the window.


Our solution: sliding windows of four consecutive Si atoms.



The package is freely available and can be downloaded in one line:
pip install karagol-rama

ANGLE

PROTEIN DEFINITION

SILICON EQUIVALENT

φ (phi)

C(i−1) – N – Cα – C

Si[i] – Si[i+1] – Si[i+2] – Si[i+3]

ψ (psi)

N – Cα – C – N(i+1)

Si[i+1] – Si[i+2] – Si[i+3] – Si[i+4]

For a chain of N silicon atoms, this gives N − 3 φ angles and N − 4 ψ angles, yielding N − 4 complete φ/ψ pairs per trajectory frame. The geometry is computed using the standard IUPAC arctan2 convention, so the output values are directly comparable to GROMACS protein output.


Architecture


The package is split into two files with a clean separation of concerns. core.py contains only pure computation — no I/O, no argument parsing, no side effects. cli.py is a thin wrapper that reads command-line arguments and delegates everything to core. This makes the library trivially importable in notebooks and pipelines.


The Dihedral Calculation


Each dihedral is computed using the cross-product method, which is numerically stable and sign-correct over the full (−180°, +180°] range:


PYTHONdef calc_dihedral(p1, p2, p3, p4):

b1 = p2 - p1; b2 = p3 - p2; b3 = p4 - p3


n1 = np.cross(b1, b2) # normal to plane 1-2-3

n2 = np.cross(b2, b3) # normal to plane 2-3-4


n1 /= np.linalg.norm(n1)

n2 /= np.linalg.norm(n2)

m1 = np.cross(n1, b2 / np.linalg.norm(b2))


return np.degrees(np.arctan2(

np.dot(m1, n2), # sine component

np.dot(n1, n2) # cosine component

))

The arctan2 call is the key: unlike arccos, it preserves the sign of the dihedral, giving the full −180° to +180° range that makes the Ramachandran plot interpretable.


Output


The script writes a GROMACS-compatible .xvg file — the same format produced by gmx rama. Every downstream tool that accepts protein Ramachandran output will accept this file without modification.




The current implementation assumes a linear, unbranched silicon chain. Branched or cyclic topologies require custom windowing logic that accounts for the branching point. Pull requests are welcome.


More fundamentally, unlike the protein Ramachandran plot, there are no pre-defined "favoured" or "disallowed" regions for silicon backbones. Those boundaries need to be established empirically for each polymer class — through quantum mechanical energy maps, large-scale MD sampling, or both. Establishing such a reference database is a natural next step.


The Ramachandran plot became powerful not just because it visualised two angles, but because decades of protein structures gave those angles meaning. Silicon backbone polymers are at the very beginning of that journey

Comments


Confused? Go to my twin's website >> www.tanerkaragol.com

The views and opinions expressed on this website are solely my own and do not reflect the views, policies, or positions of any institution, organization, or entity with which I am or have been affiliated.

Nothing on this website should be construed as professional, legal, or official advice. 

bottom of page