[Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Václav Šmilauer
> Ok then I will update my law, I missed these introductions. Thanks! You are very welcome. I added those functions yesterday actually, when I added the homoDeform==1 (position update) and had tocheck what kind of homoDeform we had at multiple places (ScGeom, NewtonIntegrator etc). -- periodic b

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread chiara modenese
On 26 October 2010 20:29, Bruno Chareyre wrote: > > You are right, of couse. >>> But how can I get shift2 in my Law* engine? >>> >>> >> No need here. > > Why not? As I understand it, if in Sergei's law you want to use > getIncidentVelocity function because you need to compute damping, then you

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Chiara Modenese
2010/10/26 Václav Šmilauer > Moving the discussion back to the bug tracker... > > Chiara: misunderstanding, sorry, I meant that the prevous > Ig2_Facet_Sphere_ScGeom did not work for facets because the shift2 > parameter was disregarded. Otherwise it should work with facets just > fine, as well a

[Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Václav Šmilauer
Moving the discussion back to the bug tracker... Chiara: misunderstanding, sorry, I meant that the prevous Ig2_Facet_Sphere_ScGeom did not work for facets because the shift2 parameter was disregarded. Otherwise it should work with facets just fine, as well as any other shapes. For getting periodi

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Václav Šmilauer
My reply to mails in this thread is at https://bugs.launchpad.net/yade/+bug/666246/comments/7, please discuss things at the bugzilla so that comments related to the issue are kept in one single place. ___ Mailing list: https://launchpad.net/~yade-

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Bruno Chareyre
You are right, of couse. But how can I get shift2 in my Law* engine? No need here. Why not? As I understand it, if in Sergei's law you want to use getIncidentVelocity function because you need to compute damping, then you need to get shift2 first. I can't remember if

Re: [Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2516: 1. Disable debug messages from ScGeom in both debug and non-debug (!!) builds

2010-10-26 Thread Bruno Chareyre
Ooops, sorry to have this in last commit. B. 1. Disable debug messages from ScGeom in both debug and non-debug (!!) builds modified: pkg/dem/ScGeom.cpp ___ Mailing list: https://launchpad.net/~yade-dev Post to : yade-dev@lists.launc

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread chiara modenese
On 26 October 2010 19:01, Bruno Chareyre wrote: > > You are right, of couse. >> But how can I get shift2 in my Law* engine? >> >> > No need here. Why not? As I understand it, if in Sergei's law you want to use getIncidentVelocity function because you need to compute damping, then you need to ge

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Sergei D.
26.10.2010 21:54, chiara modenese: Btw, according to Vaclav, for Facet-Sphere interaction shift2 would not work properly. Only with ScGeom, I meant. Sorry, I don't understand this. shift2 is used to put both interacitons bodies to one periodic cell. So, why is it would not work prop

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Bruno Chareyre
You are right, of couse. But how can I get shift2 in my Law* engine? No need here. Or to use precomputed shearIncrement from ScGeom? yes. But I need incidentVelocity too, but in ScGeom it is not cashed... Indeed. Use increment/dt? bad), I recommend turning it false : Ig2_Fa

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread chiara modenese
Btw, according to Vaclav, for Facet-Sphere interaction shift2 would not work > properly. > Only with ScGeom, I meant. ___ Mailing list: https://launchpad.net/~yade-dev Post to : yade-dev@lists.launchpad.net Unsubscribe : https://launchpad.net/~yade-de

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread chiara modenese
You are right, of couse. > But how can I get shift2 in my Law* engine? > What is prefered path? > May be to use HertzMindlin.cpp:181 string: > > Vector3r shift2=scene->isPeriodic ? > Vector3r(scene->cell->Hsize*contact->cellDist.cast()) : > Vector3r::Zero(); > > Or to use precomputed shearIncrement

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Sergei Dorofeenko
Hi, Bruno. > > For the facet, couldn't it be something like : > > const Vector3r c2x = (geom.contactPoint - de2.pos + shift2) ? You are right, of couse. But how can I get shift2 in my Law* engine? What is prefered path? May be to use HertzMindlin.cpp:181 string: Vector3r shift2=scene->isPeriodic

[Yade-dev] [Bug 666876] Re: unregistered class when built at maverick

2010-10-26 Thread Václav Šmilauer
BTW on another machine (same maverick amd64, g++ build): GenericSpheresContact Dem3DofGeom FrictPhys GlIPhysFunctor PeriodicEngine GlIGeomFunctor BoundaryController BodyCallback KinemSimpleShearBox TriaxialStressController Recorder GlShapeFunctor -- unregistered class when built at maverick https

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Janek Kozicki
Václav Šmilauer said: (by the date of Tue, 26 Oct 2010 18:58:32 +0200) > > so, for example a function that calculates axis angle, could do a > > check if that argument to acos is higher that 1.0. And if yes - then > > perform a normalization, to bring back down that quaternion to an > > identi

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Václav Šmilauer
> so, for example a function that calculates axis angle, coule do a > check if that argument to acos is higher that 1.0. And if yes - then > perform a normalization, to bring back down that quaternion to an > identity quaternion. This method will prevent quaternions from growin > bigger than indent

[Yade-dev] [Bug 666876] Re: unregistered class when built at maverick

2010-10-26 Thread Václav Šmilauer
** Attachment added: "script testing io of all yade classes" https://bugs.launchpad.net/bugs/666876/+attachment/1712032/+files/save-class.py ** Changed in: yade Importance: Undecided => High ** Changed in: yade Status: New => Confirmed ** Changed in: yade Milestone: None => 0.

[Yade-dev] [Bug 666876] [NEW] unregistered class when built at maverick

2010-10-26 Thread Václav Šmilauer
Public bug reported: The problems with "unregistered class" seem to re-surface at maverick. The packaged version (bzr2460) runs the attached script just fine, but manually-compiled versions fail: This is what classes fail to save, a g++ build: ['FrictMat', 'PeriodicEngine', 'BodyCallback', 'GlIGe

Re: [Yade-dev] Dev on GPU

2010-10-26 Thread Václav Šmilauer
> 3SR lab plans to grow henriette, its cluster, and we try to evaluate the > needs of GPU computing solutions. Is there a plan for yade to use such > techno (CUDA, OpenCL) ? Not that I know of. I discussed it with some people recently, and it does not seem to be fit for yade as it currently is. We

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Janek Kozicki
Janek Kozicki said: (by the date of Tue, 26 Oct 2010 18:40:50 +0200) > Bruno Chareyre said: (by the date of Tue, 26 Oct 2010 17:09:12 +0200) > > > Below is an example (from revno 2514). If somebody see an obvious reason > > for getting a NaN, please let me know; if not, I'll send this to

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Janek Kozicki
Please go on. I am attaching a full example. The toAxisAngle routine implemented by hand is only to check the calculation results. It is not how it _should_ be implemented. In fact I didn't look at wm3 or at any other source code , I just looked at the quaternion formulas and coded them down. Th

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2516: 1. Disable debug messages from ScGeom in both debug and non-debug (!!) builds

2010-10-26 Thread noreply
revno: 2516 committer: Václav Šmilauer branch nick: trunk timestamp: Tue 2010-10-26 18:31:33 +0200 message: 1. Disable debug messages from ScGeom in both debug and non-debug (!!) builds modified: pkg/dem/ScGeom.cpp -- lp:yade https

Re: [Yade-dev] ScGeom6D crasher

2010-10-26 Thread chiara modenese
On 26 October 2010 16:40, Bruno Chareyre wrote: > Now the question is : why does it work?!! > Hi Bruno, the problem arose because I was including the moment law in Hertz-Mindlin but somehow I was getting segmentation fault and in debug mode I realized it was not creating an ScGeom instance rather

Re: [Yade-dev] ScGeom6D crasher

2010-10-26 Thread Bruno Chareyre
Now the question is : why does it work?!! Because I've been testing only with Ig2_ChainedCylinder_ChainedCylinder_ScGeom... B. ___ Mailing list: https://launchpad.net/~yade-dev Post to : yade-dev@lists.launchpad.net Unsubscribe : https://launc

Re: [Yade-dev] ScGeom6D crasher

2010-10-26 Thread Bruno Chareyre
Not sure it needs a 3rd common function actually. It should be enough to call new in ScGeom6D::go when needed, then apply ScGeom::go on the interaction, safely casting ScGeom6D to ScGeom3D . So new<> would never be called from inside the 3D version. Bad idea, the distance would be checked twi

Re: [Yade-dev] ScGeom6D crasher

2010-10-26 Thread Bruno Chareyre
Not sure it needs a 3rd common function actually. It should be enough to call new in ScGeom6D::go when needed, then apply ScGeom::go on the interaction, safely casting ScGeom6D to ScGeom3D . So new<> would never be called from inside the 3D version. I'll think about it. B. On 26/10/10 17:26,

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2515: 1. Fix laoding of unitialized LawTester

2010-10-26 Thread noreply
revno: 2515 committer: Václav Šmilauer branch nick: trunk timestamp: Tue 2010-10-26 17:39:49 +0200 message: 1. Fix laoding of unitialized LawTester modified: pkg/dem/DomainLimiter.cpp -- lp:yade https://code.launchpad.net/~yade-dev

Re: [Yade-dev] ScGeom6D crasher

2010-10-26 Thread Bruno Chareyre
Oh, yes, you are right. Initially, I put all code in a third function that was called from both go(), but it was more compact with the current style - and I didn't realize the obvious allocation problem. Feel free to fix that, if you don't I'll do it a.s.a.p (i.e. tomorrow maybe). Now the quest

[Yade-dev] ScGeom6D crasher

2010-10-26 Thread Chiara + Václav
Hi Bruno, we were just reading the ScGeom6D code and there a serious bug. Suppose a potential interaction of 2 spheres; Ig2_Sphere_Sphere_ScGeom6D::go calls Ig2_Sphere_Sphere_ScGeom::go, which, if it succeeds, creates a new ScGeom object and assigns it to I->geom. Then the execution goes back to I

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Bruno Chareyre
Below is an example (from revno 2514). If somebody see an obvious reason for getting a NaN, please let me know; if not, I'll send this to Eigen (the first line should be enough). Bruno NaN angle found in angleAxisr(q), for quaternion 1 -1.56132e-11 7.47311e-11 -1.7066e-10, after quaternion p

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2514: - more debug info for quaternions with nan angle.

2010-10-26 Thread noreply
revno: 2514 committer: bchareyre branch nick: yade timestamp: Tue 2010-10-26 16:59:45 +0200 message: - more debug info for quaternions with nan angle. modified: pkg/dem/ScGeom.cpp -- lp:yade https://code.launchpad.net/~yade-dev/yad

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2513: 1. Update the dispatch-torture script.

2010-10-26 Thread noreply
revno: 2513 committer: Václav Šmilauer branch nick: trunk timestamp: Tue 2010-10-26 16:29:01 +0200 message: 1. Update the dispatch-torture script. modified: scripts/test/dispatcher-torture.py -- lp:yade https://code.launchpad.net/~

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Bruno Chareyre
Luc, if you want to investigate nan's with quaternions, you can try rev2511 with #define Q_DEBUG. A good example to show the problem is scripts/test/chained-cylinder-spring.py B. ___ Mailing list: https://launchpad.net/~yade-dev Post to : yade-de

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2512: - Fix cylinder reg. test with respect to r2509(2510).

2010-10-26 Thread noreply
revno: 2512 committer: bchareyre branch nick: yade timestamp: Tue 2010-10-26 16:09:37 +0200 message: - Fix cylinder reg. test with respect to r2509(2510). - Add output for nan quaternion products #ifdef Q_DEBUG. - Document some fla

Re: [Yade-dev] ForceResetter in python

2010-10-26 Thread Jan Stránský
Hi Vaclav >I was thinking about this many times, and discussed it with Bruno and Chiara. >The reason to not do that is that we don't want to do things behind user's >back, since he/she is supposed to understand what is going on. (Currently, >Cell::integrateAndUpdate is called in such a hidden

Re: [Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2511: 1. Deprecate NewtonIntegrator::homotheticCellResize in favor of Cell::homoDeform (compatibility i...

2010-10-26 Thread Bruno Chareyre
BTW Bruno, can you run --test and fix chained cylinders attributes you changed? Done, sorry. I also included in the same commit tests in order to spot nan results of quaternion products, and send report to Eigen. If Q_DEBUG is defined and if you run --test, you'll see your screen ful

Re: [Yade-dev] [Bug 666246] Re: periodic boundary don't work with ViscEl classes

2010-10-26 Thread Chareyre
Hi Sergei, Are you sure these lines apply for facet-sphere? > + const Vector3r c1x = geom.radius1*geom.normal; > + const Vector3r c2x = -geom.radius2*geom.normal; > For the facet, couldn't it be something like : const Vector3r c2x = (geom.contactPoint - de2.pos + shift2) ? This is

Re: [Yade-dev] ForceResetter in python

2010-10-26 Thread Václav Šmilauer
Hi Jan, > just one (maybe very stupid, I don't know :-) suggestion. Does > ForceResetter() has any input parameters? and if not, is there any > possibility to move it out from the python scripting and perform it > automatically in the moving to the next time step? or oppositely, is > there any nec

Re: [Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2509: Fix bug666246. See https://bugs.launchpad.net/yade/+bug/666246

2010-10-26 Thread Bruno Chareyre
Hi Sergei, Are you sure these lines apply for facet-sphere? + const Vector3r c1x = geom.radius1*geom.normal; + const Vector3r c2x = -geom.radius2*geom.normal; For the facet, couldn't it be something like : const Vector3r c2x = (geom.contactPoint - de2.pos + shift2) ? This i

[Yade-dev] ForceResetter in python

2010-10-26 Thread Jan Stránský
Hello, just one (maybe very stupid, I don't know :-) suggestion. Does ForceResetter() has any input parameters? and if not, is there any possibility to move it out from the python scripting and perform it automatically in the moving to the next time step? or oppositely, is there any necessity

[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 2511: 1. Deprecate NewtonIntegrator::homotheticCellResize in favor of Cell::homoDeform (compatibility i...

2010-10-26 Thread noreply
revno: 2511 committer: Václav Šmilauer branch nick: trunk timestamp: Tue 2010-10-26 15:41:30 +0200 message: 1. Deprecate NewtonIntegrator::homotheticCellResize in favor of Cell::homoDeform (compatibility interface with warning) 2. A

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Václav Šmilauer
> If I'm the author of this comment in the sources (I am, probably), > "close to identity" means close to null rotation. In other words the > corresponding rotation matrix is very close to identity matrix. > So, let M be a rotation matrix defining a rotation of 10^-8 degrees. > Theoretically, M*

Re: [Yade-dev] computation of MomentBending

2010-10-26 Thread Bruno Chareyre
2/ Then I rediscovered that aa.angle() can return nan, as commented in source file, it happens when the quaternion is close to identity. Please apologise for my lack of culture, but what does represent physicaly a quaternion close to identity? hmm. All quaternions that we use are id