Solution Builder

Create Solution Builder project

To begin, prepare either a completed PDB Reader project (step 5) or a completed Bioconjugate Modeler project (step 3). The Solution Builder uses the reference project’s force field automatically.

The following arguments are available for create_project():

  • title (str): Solution Builder project title.

  • ref_project_id (str): Completed PDB Reader or Bioconjugate Modeler project ID.

Example:

# alt: ref_project_id = pdbreader.projectId
# alt: ref_project_id = bioconjugate.projectId
ref_project_id = "your-reference-project-id"

sbuilder = molcube.create_solution_builder_project()
assert sbuilder.create_project(
   title="my_solution_project",
   ref_project_id=ref_project_id,
)

We will combine the individual components to build the system for molecular dynamics (MD) simulation. The following arguments are available for the method:

  • boxShape (str): System box shape (default: cubic)

  • margin (float): Box margin around the solute, dynamically applied based on solute size (default: 10.0).

  • boxSize (float, optional): Fixed box size in Å. When specified, overrides margin-based sizing (default: None).

  • ions (str): Type of ions to use (default: “kcl”).

  • ionConc (float): Ion concentration (default: 0.15).

  • neutralize (bool): Whether to neutralize the system (ion-related option) (default: False).

  • temperature (float): Temperature for the system in Kelvin (default: 310.0).

  • useHmr (bool): Whether to use hydrogen mass repartitioning (default: False).

  • mdEngines (list[str]): List of molecular dynamics engines to use (default: [‘openmm’]).

  • minimization (bool): Whether to perform energy minimization (default: False).

The available options for ions and mdengine are as follows:

  • boxShape: [‘cubic’, ‘truncated_octahedron’]

  • ions: [‘kcl’, ‘nacl’, ‘cacl2’]

  • mdEngines: [‘openmm’, ‘amber’, ‘gromacs’, ‘namd’, ‘genesis’, ‘desmond’]

Note: Both margin and boxSize are box sizing options, but only one will be applied:

  • margin: Creates a box that dynamically fits the solute with the specified margin around it

  • boxSize: Sets a fixed box size regardless of solute dimensions

  • If boxSize is provided, it takes precedence and margin is ignored

mdEngines = ['openmm', 'gromacs']
assert sbuilder.generate_system(mdEngines=mdEngines)

Download results

After the system is generated, the built system can be downloaded with download_project() and download_system():

  • download_project (filename: str): Full project archive (default: “solution.tar.gz”).

  • download_system (filename: str): Assembled system PDB file (default: “system.pdb”).

sbuilder.download_project("my-solution-project.tar.gz")
sbuilder.download_system("system.pdb")