espressomd-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ESPResSo-users] track a particle in each time step


From: Stefan Kesselheim
Subject: Re: [ESPResSo-users] track a particle in each time step
Date: Wed, 19 Mar 2014 11:24:57 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

Dear Narges,
what you would like to do is currently not possible with the observables. In principle the challenge for your system lies in evaluating a certain observable in every step and do some postprocessing. By using lots of "integrate 1"s the code becomes slow.

The idea of "observables" is to have something generic mechanism to calculate averages, variances, correlations, MSDs and so on, where the analysis is done on the fly. Observables are in principle just n-dimensional vectors, which can be used for postprocessing. Currently this is mostly used in conjuction with "correlations", i.e. quantities that depend on the state of the system for two different times. This includes MSDs. Check the Espresso 3.1 paper for details.

My question again is: What exactly are you interested in? The probability to find a monomer inside a certain subvolume? Then you can construct a new observable "is_in_subvolume" which is 1 if the monomer is in, and which is 0 if it is not. Then you can calculate the average of this observable, to obtain the probability.
To get a good estimate of this quantity it is however not necessary to sample every time step. The ballistic time scale 1/gamma is an the highest sampling rate you will need.

If you are interested in first passage times, it becomes more difficult. Then you need something like and "event recorder" which is currently not implemented.

How much slower does the "integrate 1" make your code?

I hope that helps.

Stefan


On 03/19/2014 11:06 AM, Narges Nikoofard wrote:
Dear Axel and Stefan,

Many thanks for the answers.

In more details, in my problem, a single polymer is confined eg. inside a sphere. I let the polymer to fluctuate in the sphere for a long time. A small volume is assumed inside this confining sphere. I need the simulation time, when one end of the polymer enters this volume.

So, I need to have the positions of the two end monomers at all timesteps. I read section 9.1 of the userguide. The observable "particle_positions" is defined. I also can specify "id"s of the two end monomers (that their position is required), as it seems. But I don't how to write these in the code. How can I have two output files that contain positions of each of the end monomers?

Besides, is there any example on using the command "observable"?

Many thanks again,
Narges Nikoofard




On Tue, Mar 18, 2014 at 2:21 AM, Stefan Kesselheim <address@hidden> wrote:
Hi Narges,
as Axel pointed out, the observable concept might solve your problem. It however depends on what exactly you want to do with the information if certain monomers are in certain places. You of course need to do the postprocessing on the c-level. If you tell me more details, I might be able to suggest a solution.
Cheers
Stefan

On Mar 16, 2014, at 9:59 AM, Narges Nikoofard <address@hidden> wrote:

> Dear Espresso users,
>
> I am simulating a confined polymer. I should count the number of times the end monomers enter a pre-defined region in the space. So, I need to track the end monomers' position. I need to know the end monomers' position in each time step of the simulation.
>
> As a result, I have used "integrate 1" in my code. So, I can get the monomers position in each time step and check if they are in the specified region. This makes the code very slow. Is there any way to solve this problem?
>
> Many thanks in advance,
> Narges
>
>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]