Re: [Yade-dev] : Add damping coefficient to material

2012-01-23 Thread Chiara
On 23/01/12 00:12, Klaus Thoeni wrote: Hi Bruno, hi Anton, I think density scaling is not what I am looking for since I am interested in real dynamic simulations. I need different damping parameters in NewtonIntegrator for the block and the mesh. I have to consider free flight under gravity so

Re: [Yade-dev] : Add damping coefficient to material

2012-01-23 Thread Klaus Thoeni
Hi Chiara, thanks for your comment. I am not after viscous damping either. But I think the current implementation does exactly what I want, it's the same as the PFC option b_damp(). So I can deactivate the damping coefficient for individual bodies. I can commit the code if anyone is

Re: [Yade-dev] : Add damping coefficient to material

2012-01-23 Thread Bruno Chareyre
Ok, I understand. I like your diff more than the previous one. :) Still one suggestion: this additional parameter in the damping functions is useless: + cundallDamp2nd(dt,m,state-angVel,angAccel,dampcoeff); In your code, dampCoeff will be either

Re: [Yade-dev] : Add damping coefficient to material

2012-01-23 Thread Anton Gladky
On Mon, Jan 23, 2012 at 10:44 AM, Chiara c.moden...@gmail.com wrote: ... If you are not after any density scaling, why damping in NewtonIntegrator should be acceptable in a realistic dynamic situation? Would not be easier/more meaningful for you to implement damping inside your contact model?

Re: [Yade-dev] : Add damping coefficient to material

2012-01-23 Thread Klaus Thoeni
Hi guys, thanks a lot for your suggestions. I just committed the code and I think it looks very good now. Klaus On Mon, 23 Jan 2012 11:08:59 PM Bruno Chareyre wrote: Ok, I understand. I like your diff more than the previous one. :) Still one suggestion: this additional parameter in the

Re: [Yade-dev] : Add damping coefficient to material

2012-01-22 Thread Klaus Thoeni
Hi Bruno, hi Anton, I think density scaling is not what I am looking for since I am interested in real dynamic simulations. I need different damping parameters in NewtonIntegrator for the block and the mesh. I have to consider free flight under gravity so damping=0 (and I am interested in the

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Klaus Thoeni
Hi Anton, I just had a look at py/tests/clump.py, that's the test which fails. I added this after line 60 (before NewtonIntegrator is called): for b in O.bodies: print b.material and that's what I get: FrictMat instance at 0x1014c10 None So the second body has no material. I think it's more

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Klaus Thoeni
Hi Anton, actually it is the third body and it's a clump (isClump=True). Clumps should have a material too, shouldn't they? Klaus On Thu, 19 Jan 2012 06:31:09 PM Anton Gladky wrote: Real getDampCoeff() { return material-damping; }; Can you check here a material existence? Anton On

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Anton Gladky
Hmm, good question. Maybe not. They consist of real spheres and those spheres should have a material, I think. Anton On Thu, Jan 19, 2012 at 11:35 AM, Klaus Thoeni klaus.tho...@gmail.com wrote: Hi Anton, actually it is the third body and it's a clump (isClump=True). Clumps should have a

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Klaus Thoeni
I just creeated a clump in a real simulation , and indeed, material gives 'None'. So clumps have no material. Anyone knows why? Makes no sense to me. Klaus On Thu, 19 Jan 2012 09:51:38 PM Anton Gladky wrote: Hmm, good question. Maybe not. They consist of real spheres and those spheres should

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Klaus Thoeni
Solved the problem by checking if it is a clump: Real getDampCoeff() { return (!Body::isClump) ? material-damping : NaN; }; However, I think we still have to sort out why clumps don't have a material! I will commit the code, it might be useful to have different non-viscous damping

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Anton Gladky
Could you, please, attach a diff first? Thanks Anton On Thu, Jan 19, 2012 at 1:03 PM, Klaus Thoeni klaus.tho...@gmail.com wrote: Solved the problem by checking if it is a clump: Real getDampCoeff() { return (!Body::isClump) ? material-damping : NaN; }; However, I think we still have to

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Klaus Thoeni
Here is the diff, effected classes Body, Material, NewtonIntegrator. Let me know if you are happy! === modified file core/Body.hpp --- core/Body.hpp 2010-12-22 10:55:23 + +++ core/Body.hpp 2012-01-19 11:40:50 + @@ -68,6 +68,8 @@ int getGroupMask() {return

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Bruno Chareyre
Hi Klaus, 1/ I don't really understand what you did and what the problem is. I know what density scaling is (what we discussed in Barcelona iirc), but it is not a form of damping and doesn't need anything new in materials. Instead, it uses the per-body timestep. 2/ In order to be sure where the

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Bruno Chareyre
(sorry for previous message, I didnt see the full discussion) As Anton says, a clump is a collection of bodies (not only spheres), and each of them have a material. At the clump's scale, material properties would be useless. Bruno On 19/01/12 11:56, Klaus Thoeni wrote: I just creeated a clump

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Bruno Chareyre
Still not good Klaus sorry. Bodies without material are allowed. Your change should not crash yade in that case. Solved the problem by checking if it is a clump: ___ Mailing list: https://launchpad.net/~yade-dev Post to :

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Anton Gladky
One note: if(!isnan(b-getDampCoeff())) dampcoeff=b-getDampCoeff(); I think it is not optimal to check (if(!isnan(b-getDampCoeff( on _every_ interaction on _each_ step (performance!!!). As I understand, you do not use damping-variable of Newtonintegrator at all, so just set it to -1 and use

Re: [Yade-dev] : Add damping coefficient to material

2012-01-19 Thread Bruno Chareyre
Klaus, If what you want is to increase the timestep (because your steel-net induces very small dt, right?), this change will not work. You need to modify density in the good place in Newton, not damping. It can be done by adding dscale parameter in the material class (hence no need to check if it

Re: [Yade-dev] : Add damping coefficient to material

2012-01-18 Thread Klaus Thoeni
Hi guys, can anyone help me on this? Klaus On Thu, 12 Jan 2012 06:03:16 PM Klaus Thoeni wrote: Hi guys, as discussed with Bruno in Barcelona I need different non-viscous damping coefficients for different materials. I introduced this capability by adding a variable damping to the base

Re: [Yade-dev] : Add damping coefficient to material

2012-01-18 Thread Anton Gladky
Real getDampCoeff() { return material-damping; }; Can you check here a material existence? Anton On Thu, Jan 19, 2012 at 8:14 AM, Klaus Thoeni klaus.tho...@gmail.com wrote: Hi guys, can anyone help me on this? Klaus On Thu, 12 Jan 2012 06:03:16 PM Klaus Thoeni wrote: Hi guys, as

[Yade-dev] : Add damping coefficient to material

2012-01-11 Thread Klaus Thoeni
Hi guys, as discussed with Bruno in Barcelona I need different non-viscous damping coefficients for different materials. I introduced this capability by adding a variable damping to the base class material which is initialised with NaN. The body class has a function getDampCoeff() and in