Re: [AMBER] Need help regarding calculation of Coordination number from RDF Profile

From: Daniel Roe <daniel.r.roe.gmail.com>
Date: Fri, 24 Aug 2018 13:02:34 -0400

Hi,

Maybe I missed something, but it seems like you're trying to treat the
RDF as two dimensional (r^2 dr) instead of 3D. Why is that?

Also, cpptraj includes options to print the integrated rdf (intrdf
<file>) and raw rdf (rawrdf <file>) that you may find useful.

-Dan

On Fri, Aug 24, 2018 at 6:19 AM Bharat Manna <bharatmanna.gmail.com> wrote:
>
> Dear All,
>
> Using cpptraj 'rdf' attribute I have got an RDF profile of solute-solvent
> interaction. Then I have used a simple python code to integrate the g(r) up
> to first minima with the formula:
>
> Integral = r^2 * g(r) * dr
> CN = 4 * pi * density * Integral
>
> However, I am getting too high coordination number as 149. Can anyone help
> me to troubleshoot the issue? I have provided the code and RDF data file
> below..
>
> #the python code
> import numpy as np
>
> rdf=[]
> r=[]
> #rdf and r are the two lists created from Column 2 and Column 1 data
> respectively.
> f = open('rdf_input.txt')
> lines = f.readlines()
> for each in lines:
> splitdata=each.split()
> rdf.append(float(splitdata[1]))
> r.append(float(splitdata[0]))
> dens=1.05
>
> imax = np.argmax(rdf)
> imin = imax + np.argmin(rdf[imax:])
> dr = r[1]-r[0]
>
> integral = 0.0
> for i in range(imin):
> integral += r[i] * r[i] * dr * rdf[i]
> CN = 4 * 3.14 * dens * integral
>
>
> Thanks,
> Bharat Manna
> PhD Scholar
> IIT Kharagpur
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber

_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Fri Aug 24 2018 - 10:30:02 PDT
Custom Search