[brahms-md] r62 committed - Fixed minor bug in lammps.c; some cosmetic updates.

2 views
Skip to first unread message

brah...@googlecode.com

unread,
Dec 21, 2011, 5:14:45 AM12/21/11
to brahms-d...@googlegroups.com
Revision: 62
Author: orsimario
Date: Wed Dec 21 02:14:05 2011
Log: Fixed minor bug in lammps.c; some cosmetic updates.
http://code.google.com/p/brahms-md/source/detail?r=62

Modified:
/trunk/src/diffusion.c
/trunk/src/forceNbdMain.c
/trunk/src/lammps.c
/trunk/src/main.c
/trunk/src/output.c
/trunk/src/stepInt.c

=======================================
--- /trunk/src/diffusion.c Thu Jan 6 06:46:39 2011
+++ /trunk/src/diffusion.c Wed Dec 21 02:14:05 2011
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Mario Orsi
+/* Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Mario Orsi
This file is part of Brahms.
Brahms is free software: you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or (at
your option) any later version.
@@ -51,8 +51,10 @@
fPtr = fopen( diffSnapFile, "w" );
for ( j = 0; j < nValDiffuse; j++ ) {
measurementTime = j * stepDiffuse * deltaT;
- fprintf( fPtr, "%17.4f", measurementTime ); /* [ps], Brahms's
fundamental unit of time (no need to convert) */
- fprintf( fPtr, "%12.5f", rrDiffuseAv[ j ] * Sqr( LENGTH_cm ) / TIME_s
* 1e5 ); // [10^(-5)cm^2/s]
+/* fprintf( fPtr, "%17.4f", measurementTime ); /\* [ps], Brahms's
fundamental unit of time (no need to convert) *\/ */
+/* fprintf( fPtr, "%12.5f", rrDiffuseAv[ j ] * Sqr( LENGTH_cm ) /
TIME_s * 1e5 ); // [10^(-5)cm^2/s] */
+ fprintf( fPtr, "%17.4f", measurementTime * TIME_ns ); /* [ns] */
+ fprintf( fPtr, "%18.15f", rrDiffuseAv[ j ] * Sqr( LENGTH_IN_m ) /
TIME_s ); // [ m^2 / s ]
fprintf( fPtr, "%12.5f", ddDiffuseAv[ j ] );
fprintf( fPtr, "\n" );
}
=======================================
--- /trunk/src/forceNbdMain.c Mon Oct 17 09:15:55 2011
+++ /trunk/src/forceNbdMain.c Wed Dec 21 02:14:05 2011
@@ -62,8 +62,8 @@
if ( interactionType[ n ] == WAT_WAT ) { /* water-water interaction
(special case) */
if ( rr < rrCutWatWat ) {
//
CalcDipDipInteraction(&ijPotEn,&ijForceTot,&ijTorqueTot,&jiTorqueTot,watDipoleSq,siteOrientVec[i],siteOrientVec[j],rij,rr);
- CalcDipDipInteraction_CS( &ijPotEn, &ijForceTot, &ijTorqueTot,
&jiTorqueTot, watDipoleSq, siteOrientVec[i], siteOrientVec[j], rCutWatWat,
rij, rr );
- // CalcDipDipInteraction_SF( &ijPotEn, &ijForceTot, &ijTorqueTot,
&jiTorqueTot, watDipoleSq, siteOrientVec[i], siteOrientVec[j], rCutWatWat,
rij, rr );
+ // CalcDipDipInteraction_CS( &ijPotEn, &ijForceTot, &ijTorqueTot,
&jiTorqueTot, watDipoleSq, siteOrientVec[i], siteOrientVec[j], rCutWatWat,
rij, rr );
+ CalcDipDipInteraction_SF( &ijPotEn, &ijForceTot, &ijTorqueTot,
&jiTorqueTot, watDipoleSq, siteOrientVec[i], siteOrientVec[j], rCutWatWat,
rij, rr );
potEnWatSum += ijPotEn;
// CalcLennJonesInteraction( &ijPotEn, &ijForce, sigWatSq, epsWat,
rr, rij );
CalcLennJonesInteraction_SF( &ijPotEn, &ijForce, sigWatSq, epsWat, rr,
rrCutWatWat, rij );
@@ -100,10 +100,10 @@
VVAdd( siteTorque[ i ], torque );
break;
case DIP_DIP: /* dipole-dipole */
- CalcDipDipInteraction_CS( &ijPotEn, &ijForce, &ijTorque, &jiTorque,
productElectroMoments[site[i].type][site[j].type],
- siteOrientVec[i], siteOrientVec[j], rCutLipLip, rij, rr );
-/* CalcDipDipInteraction_SF( &ijPotEn, &ijForce, &ijTorque,
&jiTorque, productElectroMoments[site[i].type][site[j].type], */
+/* CalcDipDipInteraction_CS( &ijPotEn, &ijForce, &ijTorque,
&jiTorque, productElectroMoments[site[i].type][site[j].type], */
/* siteOrientVec[i], siteOrientVec[j], rCutLipLip, rij, rr ); */
+ CalcDipDipInteraction_SF( &ijPotEn, &ijForce, &ijTorque, &jiTorque,
productElectroMoments[site[i].type][site[j].type],
+ siteOrientVec[i], siteOrientVec[j], rCutLipLip, rij, rr );
potEnDipSum += ijPotEn;
VVAdd( ijForceTot, ijForce );
VVAdd( siteTorque[ i ], ijTorque );
=======================================
--- /trunk/src/lammps.c Mon Oct 17 09:15:55 2011
+++ /trunk/src/lammps.c Wed Dec 21 02:14:05 2011
@@ -235,16 +235,18 @@
fn[ 0 ] = '\0';
strcat( fn, "data." );

+ if ( zReplicas==0 ) zReplicas = 1; // set zReplicas to default value in
case it wasn't set in 'brahms.md'
+
if (nLipids) {
// if (nDOPCsDSPCs) {
- sprintf( nString, "%d", nLipids );
+ sprintf( nString, "%d", nLipids*zReplicas );
strcat( fn, nString );
strcat( fn, "lip");
// }
}

if (nWaters) {
- sprintf( nString, "%d", nWaters );
+ sprintf( nString, "%d", nWaters*zReplicas );
strcat( fn, nString );
strcat( fn, "wat");
}
=======================================
--- /trunk/src/main.c Mon Oct 17 09:15:55 2011
+++ /trunk/src/main.c Wed Dec 21 02:14:05 2011
@@ -10,15 +10,14 @@
*
* BRAHMS - a Biomembrane Reduced-ApproacH Molecular Simulator
*
- * Brahms is a molecular dynamics program for the simulation of lipid
membranes and water.
+ * Brahms is a molecular dynamics program specifically designed for the
simulation of lipid and water systems modeled with the ELBA
+ * coarse-grain force field [Orsi & Essex, PLoS ONE, 6, e28637 (2011)].
*
- * Brahms is mainly based at the University of Southampton (Southampton,
UK). Funding has so far been received by:
- * - UK taxpayers, through government funding agencies: BBSRC, EPSRC;
- * - private companies: Johnson & Johnson, Unilever.
+ * The development of Brahms has been funded by:
+ * - UK taxpayers, through government funding agencies: BBSRC, EPSRC;
+ * - private companies: Johnson & Johnson, Unilever.
*
- * The main author of Brahms is Mario Orsi (www.personal.soton.ac.uk/orsi).
- *
- * The Brahms project was initiated and has been constantly guided and
supported by Prof. Jonathan W. Essex.
+ * The main author of Brahms is Mario Orsi (www.soton.ac.uk/~orsi).
*
* Many crucial components of Brahms, such as the main functions and data
structures, the cell-subdivision/neighbour-list algorithm,
* and several useful macro definitions, have been developed following the
excellent book 'The Art of Molecular Dynamics Simulation'
@@ -56,11 +55,12 @@
* Most of these rules are taken from Rapaport [pp.20-25], Oualline
[Practical C Programming, O'Reilly, 3rd edition, p.38] and the GNU
* coding standards (http://www.gnu.org/prep/standards).
*
- * Brahms manual, examples, and past and present code versions, can be
found online: www.personal.soton.ac.uk/orsi/brahms
+ * Brahms manual, examples, and past and present code versions, can be
found online: www.soton.ac.uk/~orsi/brahms
*
* Scientific papers based on Brahms simulations (please cite these papers
if you use or reference Brahms!):
+ * - Orsi, M. and J. W. Essex, The ELBA force field for coarse-grain
modeling of lipid membranes, PLoS ONE, 6, e28637 (2011).
* - Orsi, M., M. G. Noro and J. W. Essex. Dual-resolution molecular
dynamics simulation of antimicrobials in biomembranes,
- * Journal of the Royal Society Interface, in press (2011).
+ * Journal of the Royal Society Interface, 8, 826 (2011).
* - Orsi, M. and J. W. Essex. Permeability of drugs and hormones through
a lipid bilayer: insights from dual-resolution
* molecular dynamics, Soft Matter, 6, 3797 (2010).
* - Orsi, M., J. Michel and J. W. Essex. Coarse-grain modelling of DMPC
and DOPC lipid bilayers, Journal of Physics:
=======================================
--- /trunk/src/output.c Mon Oct 17 09:15:55 2011
+++ /trunk/src/output.c Wed Dec 21 02:14:05 2011
@@ -34,7 +34,8 @@
void PrintBrahmsVersion()
{
printf("\n**********************\n");
- printf( "* BRAHMS - 17Oct2011 *\n");
+ printf( "* BRAHMS - 21Dec2011 *\n");
+ printf( "* All shifted-force *\n");
printf( "**********************\n\n");
fflush(stdout);
}
=======================================
--- /trunk/src/stepInt.c Thu Jan 6 06:46:39 2011
+++ /trunk/src/stepInt.c Wed Dec 21 02:14:05 2011
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Mario Orsi
+/* Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Mario Orsi
This file is part of Brahms.
Brahms is free software: you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or (at
your option) any later version.

Reply all
Reply to author
Forward
0 new messages