Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Confusion in [ dihedrals ] section in hybrid topology #38

Open
wagleswapnil opened this issue Oct 9, 2023 · 3 comments
Open

Confusion in [ dihedrals ] section in hybrid topology #38

wagleswapnil opened this issue Oct 9, 2023 · 3 comments

Comments

@wagleswapnil
Copy link

Hi, I generated a hybrid topology of two ligands, the [ dihedrals ] section of the hybrid topology looks like this:
[ dihedrals ]
; ai aj ak al funct c0 c1 c2 c3 c4 c5
1 10 9 3 1 180 15.3215155 2 180 0 2 ; C1x C10x C9x C3x (AAAA->DDDD)
1 10 9 3 1 180 0 2 180 15.3215155 2 ; C1x C10x C9x C3x (AAAA->DDDD)
1 10 9 8 1 180 15.3215155 2 180 0 2 ; C1x C10x C9x C8x (AAAA->DDDD)
1 10 9 8 1 180 0 2 180 15.3215155 2 ; C1x C10x C9x C8x (AAAA->DDDD)
1 11 2 3 1 180 24.7411728 2 180 0 2 ; C1x N1x C2x C3x (AAAA->DDDD)
1 11 2 3 1 180 0 2 180 24.7411728 2 ; C1x N1x C2x C3x (AAAA->DDDD)
1 11 2 23 1 180 15.6141438 2 180 0 2 ; C1x N1x C2x H2x (AAAA->DDDD)
1 11 2 23 1 180 0 2 180 15.6141438 2 ; C1x N1x C2x H2x (AAAA->DDDD)
2 3 4 12 1 180 4.8669776 2 180 0 2 ; C2x C3x C4x C11x (AAAA->DDAA)
2 3 4 12 1 180 0 2 180 0.48669776 2 ; C2x C3x C4x C11x (AAAA->DDAA)
....

The dihedrals for almost all the pairs are defined twice. So, I have 2 questions about this [ dihedrals ] output:

  1. I want to simulate just the end states A and B in equilibrium runs. Are all the force constants for dihedrals for state A turned to 0, as the latest entries for the dihedrals will be considered?
  2. If I want to write ifdef LIGAND_A and ifdef LIGAND_B sections for the dihedrals, which contain the dihedrals for ligand A and ligand B on both the left and right sides in the entries, respectively, should it look like this? :
    [ dihedrals ]
    #ifdef LIGAND_A
    1 10 9 3 1 180 15.3215155 2 180 15.3215155 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 3 1 180 0 2 180 0 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 8 1 180 15.3215155 2 180 15.3215155 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 10 9 8 1 180 0 2 180 0 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 11 2 3 1 180 24.7411728 2 180 24.7411728 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    1 11 2 3 1 180 0 2 180 0 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    ....
    #endif
    #ifdef LIGAND_B
    1 10 9 3 1 180 0 2 180 0 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 3 1 180 15.3215155 2 180 15.3215155 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 8 1 180 0 2 180 0 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 10 9 8 1 180 15.3215155 2 180 15.3215155 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 11 2 3 1 180 0 2 180 0 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    1 11 2 3 1 180 24.7411728 2 180 24.7411728 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    1 11 2 23 1 180 0 2 180 0 2 ; C1x N1x C2x H2x (AAAA->DDDD)
    1 11 2 23 1 180 15.6141438 2 180 15.6141438 2 ; C1x N1x C2x H2x (AAAA->DDDD)
    ....
    #endif
    #ifdef LIGAND_AB
    1 10 9 3 1 180 15.3215155 2 180 0 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 3 1 180 0 2 180 15.3215155 2 ; C1x C10x C9x C3x (AAAA->DDDD)
    1 10 9 8 1 180 15.3215155 2 180 0 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 10 9 8 1 180 0 2 180 15.3215155 2 ; C1x C10x C9x C8x (AAAA->DDDD)
    1 11 2 3 1 180 24.7411728 2 180 0 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    1 11 2 3 1 180 0 2 180 24.7411728 2 ; C1x N1x C2x C3x (AAAA->DDDD)
    1 11 2 23 1 180 15.6141438 2 180 0 2 ; C1x N1x C2x H2x (AAAA->DDDD)
    1 11 2 23 1 180 0 2 180 15.6141438 2 ; C1x N1x C2x H2x (AAAA->DDDD)
    2 3 4 12 1 180 4.8669776 2 180 0 2 ; C2x C3x C4x C11x (AAAA->DDAA)
    2 3 4 12 1 180 0 2 180 0.48669776 2 ; C2x C3x C4x C11x (AAAA->DDAA)
    2 3 4 18 1 180 4.8669776 2 180 0 2 ; C2x C3x C4x C14x (AAAA->DDAA)
    2 3 4 18 1 180 0 2 180 0.48669776 2 ; C2x C3x C4x C14x (AAAA->DDAA)
    ...
    #endif
@vgapsys
Copy link
Member

vgapsys commented Nov 29, 2023

  1. In a hybrid topology dihedral for ligand A is turned of, dihedral for ligand B is turned on. This topology can be used for equilibrium simulations in the states A and B, as well as for the transitions between the states
  2. The ifdef definitions are not required: you can simply use hybrid topology as created by pmx and control which state is activated via mdp parameters

@nonsensejoke
Copy link

I'm also struggling to understand this section about dihedral.

Is there some detailed manual related to this? Or could you please point me to certain block of pmx code?

Thanks a lot.

@vgapsys
Copy link
Member

vgapsys commented Aug 27, 2024

The dihedrals are constructed here:

def _make_dihedrals( self ):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants