strong impulses when actuating joints

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Re: strong impulses when actuating joints

Postby blackbird_dream » Tue Oct 16, 2018 8:11 am

I observed it crashed when bodies fell asleep. I don't understand why but that's what I observed
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Tue Oct 16, 2018 10:09 am

yes and that is what explain that the null body caused the crash. is was a silly bug.
anyway it is fixed now, you can sync the newton SDK and build it.
see how that goes.
and back to the orginal problem.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Tue Oct 16, 2018 10:34 am

seems ok with the minimal case.
Still crashes with the FLT test. Let me build a new minimal case or find the reason.
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Tue Oct 16, 2018 1:42 pm

Maybe there is some other bug,
try getting this and fix the inertia thing then make another repro.
do not cheat by making an inertia some ridiculous small value like 1.0e-5 or something like that to pass the assert.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Tue Oct 16, 2018 1:46 pm

alright. No I won't cheat, I've no hard specs on these things, only physical data.
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Tue Oct 16, 2018 2:41 pm

Sweenie wrote:The plugin falls back to the NullCollision if no collision shape is added to the body.

Code: Select all
        else if (colliderList.Count == 0)
        {
            m_collidersArray = new ColliderShapePair[1];
            NewtonCollider collider = body.gameObject.AddComponent<NewtonNullCollider>();
            m_collidersArray[0].m_collider = collider;
            m_collidersArray[0].m_shape = collider.Create(body.m_world);
        }


I was wondering why a body can have a null shape so easy, but I see it now, is possible to make a body without a shape. can we make that the shape component is requirement of a rigid body.
this can prevent this thong from happening, because I think this is what people are report if you are allow to add body component then is easy to forget adding a collider component.

we do not change the code, so they still can be created out of order, but we know that when the final unity entity is ready, it will have a body with some collider unless the user want that collider to be a null shape.
not sure is that is possible.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Wed Oct 17, 2018 8:35 am

ok no more crash. This issue is solved in my opinion.
I came back to the jitter.
It's really better than before although it is not perfect as you can see here:
https://we.tl/t-e8KmmLOXdo
I was used to the perfection with v1.5.3 and to wean it off that will be very difficult.
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Wed Oct 17, 2018 1:58 pm

you say this demo still generate jitter.
It should be just as good or better than 1.53 was actually even better.
if you remember I have to tight some tolerance for you, this solver does no required that setting, but the difference is that not all configuration can be solve with this solve, so it use matrix partition.
in you case if entire system is not partition if I remember correctly.
so maybe some is not configured right. and some joint are in fact partition and do no converge to zero error.
I will try the last repro tonight and see what is wrong.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Wed Oct 17, 2018 2:56 pm

Do you want the testcase?
I remember well what you did but with the v1.5.3 there was no jitter. Only loose joints .
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Wed Oct 17, 2018 3:51 pm

yes that looseness is what masked the jitter. in 1.53 that was build into the solver now that has to be control but the application, you can set the stiffness for the joint to something less that 1.0 and that will make them more like 1.53, it will never be exact just like 1.53
because for 1.53 to converge it needed an implicit matrix regularizer which is basically a damper
the makes the diagonal bigger. now that controlled by the application per joint by setting the stiffness

try play with joint stiffness, set the to say 0.9 fo go from there.
can you make a video?
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Thu Oct 18, 2018 3:36 am

the tires are created procedurally with no collider as they don't need theoretically because they just calculate reaction torsors. It seems to work. Is it prohibited? It is created at runtime (nullcollider).
For me the behavior is acceptable as the testcase is very severe (the rear wheels are quite lifting off the ground due to the high mass on the fork with high lever arm. The load has big dimensions).
Last edited by blackbird_dream on Thu Oct 18, 2018 7:56 am, edited 1 time in total.
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Thu Oct 18, 2018 6:20 am

you can create null collided anytime,
my observation to swenie was that the plugin let people make unintended null shapes by simply making a body without collision. and I think that made be exposed by the optimization I made.
basically if half a scene when to sleep, the colliding pair iterate over the remaining active body, and there was possible to find a body with null shape because they do are not part of the broad phase.

it does not mean that null shape are to avoided.


on the other question, I am confused, are you saying the tire arena,t rigid bodies?
you calculate the forces and add them to the chassis?
that should work fine.
the question is about the jitter, if you make them just a bit more relax, the jitter may go away.
what is your simulation rate? 60 hertz.
you can also try 2 sub steps. the second is far cheaper.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Thu Oct 18, 2018 7:54 am

they are RB. I compute the torsor and apply it to the RB which is connected to the chassis by a Hinge or a Hinge actuator for the rear steering wheel. The axes are vertical.
y the rate is 60 Hz.
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

Re: strong impulses when actuating joints

Postby Julio Jerez » Thu Oct 18, 2018 8:34 am

blackbird_dream wrote:y the rate is 60 Hz.


in the world settings there should be an option to set the sub steps, try 2 substeps, or maybe more that has quadratic effect is accuracy, and is that expensive.
check that out it will probably resolve those thing for almost not effort.
Julio Jerez
Moderator
Moderator
 
Posts: 11040
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: strong impulses when actuating joints

Postby blackbird_dream » Thu Oct 18, 2018 8:38 am

I've tried. Increasing the substeps make the vibrations caused by the tire softness last longer as I set null damping. The damping is included in the reaction torsor.
In my opinion it's good as it is as this case is too severe.
According to Dave I tried 120fps et 2 substeps. It's more stable but slower.

https://youtu.be/XSJAUJUOHuc
User avatar
blackbird_dream
 
Posts: 279
Joined: Wed Jun 07, 2006 3:08 pm
Location: Italy

PreviousNext

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 6 guests

cron