duello

Osmotic second virial coefficient (𝐡₂) and dissociation constant (𝐾𝑑) for two rigid macromolecules

https://github.com/mlund/duello

Science Score: 59.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • β—‹
    CITATION.cff file
  • βœ“
    codemeta.json file
    Found codemeta.json file
  • βœ“
    .zenodo.json file
    Found .zenodo.json file
  • βœ“
    DOI references
    Found 3 DOI reference(s) in README
  • βœ“
    Academic publication links
    Links to: zenodo.org
  • βœ“
    Committers with academic emails
    1 of 5 committers (20.0%) from academic institutions
  • β—‹
    Institutional organization owner
  • β—‹
    JOSS paper metadata
  • β—‹
    Scientific vocabulary similarity
    Low similarity (12.0%) to scientific vocabulary

Keywords

chemistry intermolecular-interactions protein-protein-interaction

Keywords from Contributors

mesh interpretability sequences projection interactive optim hacking network-simulation
Last synced: 6 months ago · JSON representation

Repository

Osmotic second virial coefficient (𝐡₂) and dissociation constant (𝐾𝑑) for two rigid macromolecules

Basic Info
  • Host: GitHub
  • Owner: mlund
  • License: apache-2.0
  • Language: Rust
  • Default Branch: main
  • Homepage:
  • Size: 1.55 MB
Statistics
  • Stars: 1
  • Watchers: 3
  • Forks: 1
  • Open Issues: 7
  • Releases: 1
Topics
chemistry intermolecular-interactions protein-protein-interaction
Created about 1 year ago · Last pushed 7 months ago
Metadata Files
Readme License Zenodo

README.md

crates.io

Zenodo Open In Colab


Duello
Virial Coefficient and Dissociation Constant Estimation for Rigid Macromolecules


Introduction

Duello is a tool to calculate the potential of mean force (PMF) between two rigid bodies, performing a statistical mechanical average over inter-molecular orientations using subdivided icosahedrons. For each mass center separation, R, the static contribution to the partition function, $\mathcal{Z}(R) = \sum{\mathbf{\Omega}} e^{-V(R,\mathbf{\Omega})/kBT}$, is explicitly evaluated to obtain the potential of mean force, $w(R) = -k_BT \ln \mathcal{Z}(R)$ and the thermally averaged energy,

$$ U(R) = \frac{\sum V(R,\mathbf{\Omega}) e^{-V(R,\mathbf{\Omega})/k_BT}} {\mathcal{Z}(R)} $$

where $V(R,\mathbf{\Omega})$ is the total inter-body interaction energy and $\mathbf{\Omega}$ represents a 5D angular space (e.g. two spherical coordinates for each body plus a dihedral angle around the connection line).

The osmotic second virial coefficient, which has dimensions of volume, reports on exactly two-body interactions:

$$ \begin{align} B2 & = -\frac{1}{16\pi^2} \int{\mathbf{\Omega}} \int0^{\infty} \left ( e^{-V(R,\mathbf{\Omega})/kBT} - 1 \right ) R^2 dR d\mathbf{\Omega}\ & = -2\pi \int0^{\infty} \left ( e^{-w(R)/kBT} -1 \right )R^2 dR \ & = B2^{hs} -2\pi \int{\sigma}^{\infty} \left ( e^{-w(R)/k_BT} -1 \right )R^2 dR\ \end{align} $$

where $B2^{hs} = 2\pi\sigma^3/3$ is the hard-sphere contribution and $\sigma$ is a distance of closest approach where $w(R\lt \sigma)=\infty$ is assumed. For systems with net attractive interactions, the dissociation constant, $Kd$, can be estimated by,

$$ Kd^{-1} = 2 NA\left (B2^{hs} - B2\right ) $$

crates.io

Installation

Binary packages are available for Linux and MacOS through PyPI.org:

console pip install duello

If you have a Rust toolchain installed, you may alternatively build and install directly from the source code:

sh cargo install --git https://github.com/mlund/duello

Usage

The command-line tool duello does the 6D scanning and calculates the angularly averaged potential of mean force, A(R) which is used to derive the 2nd virial coefficient and twobody dissociation constant, $Kd$. The two input structures should be in .xyz format and all particle names must be defined in the topology file under atoms. The topology also defines the particular pair-potential to use, see below. Note that currently, a coulomb potential is automatically added and should hence _not be specified in the topology. The program is written in Rust and attempts to use all available CPU cores.

sh duello scan \ --mol1 cppm-p18.xyz \ --mol2 cppm-p18.xyz \ --rmin 37 --rmax 50 --dr 0.5 \ --top topology.yaml \ --resolution 0.8 \ --cutoff 1000 \ --molarity 0.05 \ --temperature 298.15

Preparing PDB files

The following uses pdb2xyz to create a coarse grained XYZ file and Calvados topology for Duello:

sh pip install pdb2xyz pdb2xyz -i 4lzt.pdb -o 4lzt.xyz --pH 7.0 --sidechains duello scan \ -1 4lzt.xyz -2 4lzt.xyz \ --rmin 24 --rmax 80 --dr 0.5 \ --resolution 0.6 \ --top topology.yaml \ --molarity 0.05

If pdb2xyz give errors, you may be able to correct your PDB file with pdbfixer.

Examples

Ready run scripts examples are provided in the scripts/ directory:

Command | Description ---------------------- | ------------------------------------------------------------ scripts/cppm.sh | Spherical, multipolar particles using the CPPM model scripts/calvados3.sh | Two coarse grained lysozyme molecules w. Calvados3 interactions

Interaction models

Each macromolecule is represented by a rigid constellation of beads with properties defined under atoms in the topology file. The inter-molecular energy, $V(R,\Omega)$ is calculated by summing all pairwise interactions between beads using a customizable pair potential, $u_{ij}$. If needed, different pair-potentials can be explicitly defined for specific atom pairs.

The provided examples illustrate the following schemes:

  • Screened Coulomb + AshbaughHatch, for the Calvados model.
  • Screened Coulomb + WeeksChandlerAndersen for the CPPM model.

Many more pair-potentials are available through the interatomic library, e.g. LennardJones, HardSphere etc.

Warning: The electrostatic term, Coulomb is always automatically added and should therefore not be specified in the topology.

Development

This is for development purposes only and details how to create and publish a binary package on pipy.org.

Create pip package using Maturin via a Docker image:

sh docker run --rm -v $(pwd):/io ghcr.io/pyo3/maturin publish -u __token__ -p PYPI_TOKEN

For local Maturin installs, follow the steps below.

sh pip install ziglang pipx pipx install maturin # on ubuntu; then restart shell maturin publish -u __token__ -p PYPI_TOKEN --target=x86_64-unknown-linux-gnu --zig

MacOS targets can be generated without --zig using the targets x86_64-apple-darwin and aarch64-apple-darwin.

sh rustup target list rustup target add x86_64-apple-darwin

Owner

  • Name: Mikael Lund
  • Login: mlund
  • Kind: user
  • Location: Lund, Sweden
  • Company: Lund University

GitHub Events

Total
  • Create event: 4
  • Issues event: 1
  • Release event: 1
  • Watch event: 1
  • Delete event: 2
  • Issue comment event: 4
  • Push event: 10
  • Pull request event: 9
  • Fork event: 1
Last Year
  • Create event: 4
  • Issues event: 1
  • Release event: 1
  • Watch event: 1
  • Delete event: 2
  • Issue comment event: 4
  • Push event: 10
  • Pull request event: 9
  • Fork event: 1

Committers

Last synced: 7 months ago

All Time
  • Total Commits: 193
  • Total Committers: 5
  • Avg Commits per committer: 38.6
  • Development Distribution Score (DDS): 0.332
Past Year
  • Commits: 180
  • Committers: 4
  • Avg Commits per committer: 45.0
  • Development Distribution Score (DDS): 0.339
Top Committers
Name Email Commits
Mikael Lund M****d@m****m 129
mlund m****d@l****t 57
Ladislav Bartos l****b@g****m 3
dependabot[bot] 4****] 2
Harold Hatch h****h@n****v 2
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 1
  • Total pull requests: 8
  • Average time to close issues: N/A
  • Average time to close pull requests: 11 days
  • Total issue authors: 1
  • Total pull request authors: 2
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.25
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 7
Past Year
  • Issues: 1
  • Pull requests: 8
  • Average time to close issues: N/A
  • Average time to close pull requests: 11 days
  • Issue authors: 1
  • Pull request authors: 2
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.25
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 7
Top Authors
Issue Authors
  • mlund (1)
Pull Request Authors
  • dependabot[bot] (7)
  • HaroldHatchNIST (1)
Top Labels
Issue Labels
Pull Request Labels
dependencies (7) rust (7)

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 342 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 4
  • Total maintainers: 1
pypi.org: duello

Calculates the osmotic second virial coefficient (B2), and dissociation constant (Kd), for two rigid (macro)molecules, e.g. globular proteins. Done by explicit summation of the partition function in six dimensions (angular space and rigid-body separation). Calvados 3 parameters for use with coarsed grained amino acids are provided, but any pair-wise additivie potential can be used.

  • Versions: 4
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 342 Last month
Rankings
Dependent packages count: 9.8%
Average: 32.4%
Dependent repos count: 55.1%
Maintainers (1)
Last synced: 7 months ago

Dependencies

.github/workflows/rust.yml actions
  • actions/checkout v4 composite
Cargo.lock cargo
  • 258 dependencies
Cargo.toml cargo
  • lazy_static 1.5 development
  • anyhow 1.0
  • approx 0.5
  • average 0.16
  • clap 4
  • coulomb 0.2.1
  • flate2 1.0
  • get-size 0.1
  • glam 0.29.3
  • hexasphere 15.1
  • indicatif *
  • interatomic 0.3
  • iter_num_tools 0.7
  • itertools 0.14
  • itertools-num 0.1
  • log 0.4
  • nalgebra 0.33
  • nu-ansi-term 0.50
  • num-traits 0.2
  • physical_constants 0.5
  • pretty_env_logger 0.5
  • rand 0.8
  • rayon 1.10
  • rgb 0.8
  • semver 1.0
  • serde 1.0
  • serde_json 1.0.137
  • serde_yaml 0.9
  • textplots 0.8
  • xdrfile 0.3.0
pyproject.toml pypi
  • mdtraj >=1.9
  • pdb2xyz >=0.1.2