[gmx-users] Genbox - Removal of Unwanted Waters
Hello all, How do you remove unwanted waters (or how do you prevent genbox from placing unwanted waters) after you solvate by genbox? This problem was posted once before, http://www.gromacs.org/pipermail/gmx-users/2005-December/018997.html but it doesn't seem like it was resolved. Is there an easy way to do this (aside from going into the .gro file and manually deleting the unwanted waters!) Thanks, Arneh ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php
Re: [gmx-users] Genbox - Removal of Unwanted Waters
Arneh Babakhani wrote: Hello all, How do you remove unwanted waters (or how do you prevent genbox from placing unwanted waters) after you solvate by genbox? This problem was posted once before, http://www.gromacs.org/pipermail/gmx-users/2005-December/018997.html but it doesn't seem like it was resolved. Is there an easy way to do this (aside from going into the .gro file and manually deleting the unwanted waters!) genbox 3.3.1 has an option to set the maximum number of waters. Thanks, Arneh ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php -- David. David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group, Dept. of Cell and Molecular Biology, Uppsala University. Husargatan 3, Box 596, 75124 Uppsala, Sweden phone: 46 18 471 4205 fax: 46 18 511 755 [EMAIL PROTECTED] [EMAIL PROTECTED] http://folding.bmc.uu.se ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php
Re: [gmx-users] Genbox - Removal of Unwanted Waters
Thanks for the input. Is there a way to restrict the water from a certain space (in other words, to confine it a certain location)? Thanks, Arneh David van der Spoel wrote: Arneh Babakhani wrote: Hello all, How do you remove unwanted waters (or how do you prevent genbox from placing unwanted waters) after you solvate by genbox? This problem was posted once before, http://www.gromacs.org/pipermail/gmx-users/2005-December/018997.html but it doesn't seem like it was resolved. Is there an easy way to do this (aside from going into the .gro file and manually deleting the unwanted waters!) genbox 3.3.1 has an option to set the maximum number of waters. Thanks, Arneh ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php
Re: [gmx-users] Genbox - Removal of Unwanted Waters
Arneh Babakhani wrote: Thanks for the input. Is there a way to restrict the water from a certain space (in other words, to confine it a certain location)? just the shell option, otherwise no. genbox -h Thanks, Arneh David van der Spoel wrote: Arneh Babakhani wrote: Hello all, How do you remove unwanted waters (or how do you prevent genbox from placing unwanted waters) after you solvate by genbox? This problem was posted once before, http://www.gromacs.org/pipermail/gmx-users/2005-December/018997.html but it doesn't seem like it was resolved. Is there an easy way to do this (aside from going into the .gro file and manually deleting the unwanted waters!) genbox 3.3.1 has an option to set the maximum number of waters. Thanks, Arneh ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php -- David. David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group, Dept. of Cell and Molecular Biology, Uppsala University. Husargatan 3, Box 596, 75124 Uppsala, Sweden phone: 46 18 471 4205 fax: 46 18 511 755 [EMAIL PROTECTED] [EMAIL PROTECTED] http://folding.bmc.uu.se ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php
[gmx-users] Genbox - Removal of Unwanted Waters
If I have a solvated membrane and I want to extend the z dimension and add new waters there, this is what I do. The script could be modified to get rid of new waters in any x/y/z dimensions (around line 41 of the script). 1. run genbox on initial.gro to create solvated.gro 2. cp solvated.gro new_waters.gro 3. use vi to remove everything in new_waters.gro except the new waters (make sure you remove waters that were in initial.gro) 4. use vi to edit keepbyz.pl - upperz and lowerz variables as you please - sol to the name of your solvent molecule 5. run keepbyz.pl on new_waters.gro ./keepbyz new_waters.gro keep_these_waters.gro 6. tail -1 initial.gro last_line.gro 7. head -$(expr $(cat initial.gro | wc -l | awk '{print $1}') - 1 ) initial.gro not_last_line.gro 8. cat not_last_line.gro new_waters.gro last_line.gro new_system.gro 9. editconf -f new_system.gro -o new_system_sequential_numbers.gro Here is the script (make sure you chmod +x keepbyz.pl): #!/bin/bash # give x.gro as first command line arguement upperz=6.417 lowerz=0.820 sol=SOL count=0 cat $1 | grep $sol | while read line; do for first in $line; do break done if [ $count = 3 ]; then count=0 fi count=$(expr $count + 1) if [ $count != 1 ]; then continue fi l=${#line} m=$(expr $l - 24) i=1 for word in ${line:$m}; do if [ $i = 1 ]; then popex=$word else if [ $i = 2 ]; then popey=$word else if [ $i = 3 ]; then popez=$word break fi fi fi i=$(expr $i + 1) done nolx=`echo $popez $upperz | bc` nohx=`echo $popez $lowerz | bc` myno=$(expr $nolx + $nohx) if [ $myno != 0 ]; then z=${#first} if [ $z != 8 ]; then sfirst=[[:space:]]$first else sfirst=$first fi `echo grep $sfirst $1` fi done ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php
Re: [gmx-users] Genbox - Removal of Unwanted Waters
Great, thank you very much, will try it out, [EMAIL PROTECTED] wrote: If I have a solvated membrane and I want to extend the z dimension and add new waters there, this is what I do. The script could be modified to get rid of new waters in any x/y/z dimensions (around line 41 of the script). 1. run genbox on initial.gro to create solvated.gro 2. cp solvated.gro new_waters.gro 3. use vi to remove everything in new_waters.gro except the new waters (make sure you remove waters that were in initial.gro) 4. use vi to edit keepbyz.pl - upperz and lowerz variables as you please - sol to the name of your solvent molecule 5. run keepbyz.pl on new_waters.gro ./keepbyz new_waters.gro keep_these_waters.gro 6. tail -1 initial.gro last_line.gro 7. head -$(expr $(cat initial.gro | wc -l | awk '{print $1}') - 1 ) initial.gro not_last_line.gro 8. cat not_last_line.gro new_waters.gro last_line.gro new_system.gro 9. editconf -f new_system.gro -o new_system_sequential_numbers.gro Here is the script (make sure you chmod +x keepbyz.pl): #!/bin/bash # give x.gro as first command line arguement upperz=6.417 lowerz=0.820 sol=SOL count=0 cat $1 | grep $sol | while read line; do for first in $line; do break done if [ $count = 3 ]; then count=0 fi count=$(expr $count + 1) if [ $count != 1 ]; then continue fi l=${#line} m=$(expr $l - 24) i=1 for word in ${line:$m}; do if [ $i = 1 ]; then popex=$word else if [ $i = 2 ]; then popey=$word else if [ $i = 3 ]; then popez=$word break fi fi fi i=$(expr $i + 1) done nolx=`echo $popez $upperz | bc` nohx=`echo $popez $lowerz | bc` myno=$(expr $nolx + $nohx) if [ $myno != 0 ]; then z=${#first} if [ $z != 8 ]; then sfirst=[[:space:]]$first else sfirst=$first fi `echo grep $sfirst $1` fi done ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php ___ gmx-users mailing listgmx-users@gromacs.org http://www.gromacs.org/mailman/listinfo/gmx-users Please don't post (un)subscribe requests to the list. Use the www interface or send it to [EMAIL PROTECTED] Can't post? Read http://www.gromacs.org/mailing_lists/users.php