espressomd-users
[Top][All Lists]
Advanced

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

Re: [ESPResSo-users] OIF, deviation in "origin"-command


From: Ivan Cimrak
Subject: Re: [ESPResSo-users] OIF, deviation in "origin"-command
Date: Thu, 27 Feb 2014 15:42:10 +0100
User-agent: Mozilla/5.0 (Windows NT 6.2; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

Hi Markus,

I set up a webpage with several meshes, see
http://cell-in-fluid.fri.uniza.sk/en/content/oif-espresso
You can download the zip files and use them.

The difference between the sphere and the ball is this one: sphere is a 2D surface triangulated with triangles and each edge is common with exactly two triangles. Ball is a 3D mesh with tetrahedra, so also the inside of the sphere is triangulated. However, in the files provided,  only two kinds of data is given:
1. the positions of the mesh points (points are on the surface of the sphere as well as inside of the sphere, almost uniformly distributed.)
2. the incidences of the triangles in the mesh.

Notice, that no information is given on which four triangles form a tetrahedron. We consider the mesh simply as a composition of points, triangles and edges. This results however in restricted use of elastic forces in the OIF framework. With these balls, you are NOT allowed to use the bending, because there are not exactly two triangles common for one edge. Also, you can NOT use the volume and the global surface preservation. So for this type of balls, you can use the stretching (it is defined for each edge) and local area conservation only, because this is defined for each triangle.

I hope the explanation is clear,

Ivan




Dňa 25.2.2014 17:16 Wink, Markus wrote / napísal(a):

Hi Ivan,

 

Anyway, what kind of meshes do you need? I could provide you with some spheres, balls or red-blood-cells

So far, I am interested in simple geometries like spheres. So it would be great, if you could provide me one of those. Anyway, what is the difference between balls and spheres? By “ball”, do you mean structures like a bucky ball?

 

Greetings Markus

 

 

Von: Ivan Cimrak [mailto:address@hidden]
Gesendet: Dienstag, 25. Februar 2014 15:32
An: Wink, Markus; address@hidden
Betreff: Re: AW: [ESPResSo-users] OIF, deviation in "origin"-command

 

Hi Markus,

We use gmsh (http://geuz.org/gmsh/) software for producing triangulations. There are however many others, commercial or non-commercial, just type "mesh generation tools" in your favorite search engine. Anyway, what kind of meshes do you need? I could provide you with some spheres, balls or red-blood-cells.

Ivan


Dňa 25.2.2014 15:25 Wink, Markus wrote / napísal(a):

Hi,

 

One more comment, your objects should be numbered consecutively, starting from 0

Thanks a lot for the command on the numbering. That’s a very good point!

 

When an OIF object deforms, the origin definitely does not need to coincide with the say center of the mass.

That is true, but so far no integration has be done, so no deformation should have taken place.

 

Simply, the triangulation mesh given in the $fileNodes file is not centered around the "expected" center of the sphere. Probably, the mesh generator did not produced balanced triangulation, which is in fact not a mistake.
That is what I thought. Anyway, I have never produced a triangulation on my own. Is there any recommendation of software/literature… you could give?

 

Greetings

 

Markus Wink

 

Von: address@hidden [mailto:address@hidden] Im Auftrag von Ivan Cimrak
Gesendet: Dienstag, 25. Februar 2014 15:14
An: address@hidden
Betreff: Re: [ESPResSo-users] OIF, deviation in "origin"-command

 

Dear Markus,

The switch "origin" in the oif_object_analyze command, computes the average of the coordinates of the current positions of the mesh points. When an OIF object deforms, the origin definitely does not need to coincide with the say center of the mass.

There is no wrong calculation in your script. Simply, the triangulation mesh given in the $fileNodes file is not centered around the "expected" center of the sphere. Probably, the mesh generator did not produced balanced triangulation, which is in fact not a mistake.

One more comment, your objects should be numbered consecutively, starting from 0. I strongly recommend to keep this in mind. Normaly, the software should complain when you do not do this, there will be a patch on this soon.

Ivan

Dňa 25.2.2014 15:02 Wink, Markus wrote / napísal(a):

Dear all,

 

I have noticed a quite strange behavior in the command “origin” for the OIF-implementation. Probably somebody can help me out with that. In my script, I have put a sphere in a channel at a specific position. Afterwards I wanted to check, which result the command “origin” gives. The interesting parts of my scripts are:

 

oif_create_template template-id 0 nodes-file $fileNodes triangles-file $fileTriangles ks 10 kb 10 kv 50

oif_add_object object-id 1 template-id 0 origin 15 15 15 rotate 0 0 0 part-type 1 mass 1

set x [oif_object_analyze object-id 0 origin]

puts $x

 

So I put the object with its origin @ 15 15 15; command “origin” prints out: 15.008655470737903 15.02980503816793 14.995383511450385

No integration of the system has be done so far.

 

I can think of two reasons for the deviation:

1)     The source code is correct and the deviation results because of rounding errors

2)     The template I have used (I used the sphere_nodes/triangles.dat found on git hub) is somehow not correct. Actually, I have noticed, that the points given do not exactly fulfill the relation for a sphere (x^2+y^2+z^2=r^2). So it could be that the deviation origins from that artefact.

3)     The calculations performed by the command “origin” has some error. Unfortunately, I could not locate, where the calculation is performed in the source code.

 

Does anyone have a clue?

 

Greetings

 

Markus Wink

 

 



reply via email to

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