<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://pybullet.org/Bullet/phpBB3/app.php/feed/topic/4350" />

	<title>Real-Time Physics Simulation Forum</title>
	
	<link href="https://pybullet.org/Bullet/phpBB3/index.php" />
	<updated>2020-09-17T02:22:21+00:00</updated>

	<author><name><![CDATA[Real-Time Physics Simulation Forum]]></name></author>
	<id>https://pybullet.org/Bullet/phpBB3/app.php/feed/topic/4350</id>

		<entry>
		<author><name><![CDATA[Erwin Coumans]]></name></author>
		<updated>2020-09-17T02:22:21+00:00</updated>

		<published>2020-09-17T02:22:21+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=43101#p43101</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=43101#p43101"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=43101#p43101"><![CDATA[
Finally, it took 11 years but it was worth waiting: a new paper by Theodore Kim addresses the problem, and one of the references points to this forum thread. See <a href="http://www.tkim.graphics/FEMBW" class="postlink">http://www.tkim.graphics/FEMBW</a> or <a href="https://twitter.com/_TheodoreKim/status/1300774070997393409" class="postlink">https://twitter.com/_TheodoreKim/status ... 0997393409</a><p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=2">Erwin Coumans</a> — Thu Sep 17, 2020 2:22 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[mathis]]></name></author>
		<updated>2009-12-04T16:22:10+00:00</updated>

		<published>2009-12-04T16:22:10+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16366#p16366</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16366#p16366"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16366#p16366"><![CDATA[
Well, it is not PD only for large time steps and large stiffness/damping constants, but as their paper is entitled "large steps in cloth simulation", they should have realized this <img class="smilies" src="https://pybullet.org/Bullet/phpBB3/images/smilies/icon_wink.gif" width="15" height="15" alt=":wink:" title="Wink"> <br><br>I realized it already with my second test of my implementation where the simulation just exploded. After some hours of further testing, I discovered the non-PD-ness of the matrix.<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5568">mathis</a> — Fri Dec 04, 2009 4:22 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[fishboy82]]></name></author>
		<updated>2009-12-01T06:44:08+00:00</updated>

		<published>2009-12-01T06:44:08+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16318#p16318</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16318#p16318"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16318#p16318"><![CDATA[
Oh, I now realize they are the same, so this mean the matrix in baraff 's original paper of stretch enegy is not a PD matrix ..strange<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5261">fishboy82</a> — Tue Dec 01, 2009 6:44 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[mathis]]></name></author>
		<updated>2009-11-30T09:19:25+00:00</updated>

		<published>2009-11-30T09:19:25+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16310#p16310</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16310#p16310"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16310#p16310"><![CDATA[
The formulas are the same for a uv-aligned triangle. Let (x0, x1, x2) be such a triangle with the uv-coordinates (0, 0), (L1, 0), (0, L2). L1 and L2 are the rest lengths of the edges x0-x1 and x0-x2, respectively. This fulfills the requirement of the paper that |dw/du| = |dw/dv| = 1 if w is the rest state w(u,v) = (u,v,0), where w in general maps (u,v) into the current 3d vertex position.<br><br>Now for the current state w, the paper approximates<br><br>(dw/du, dw/dv) = (x1-x0, x2-x0) * ((u1-u0, u2-u0), (v1-v0, v2-v0))^-1<br><br>In our case, the matrix ((u1-u0, u2-u0), (v1-v0, v2-v0)) is a diagonal with the entries L1, L2, so the formula simplifies to<br><br>dw/du = (x1 - x0) / L1<br>dw/dv = (x2 - x0) / L2<br><br>Now the paper uses C(x0,x1,x2) = a * (|dw/du| - bu, |dw/dv| - bv) as constraint and k/2 C^T C as energy. This leads to the energy<br><br>E = a^2 k / 2 * ( ((x1 - x0)/L1 - bu)^2 + ((x2 - x0)/L2 - bv)^2 )<br><br>which is the sum of the energy of two springs with rest lengths bu*L1, bv*L2 and spring constants a^2 k / L1^2, a^2 k / L2^2. And this energy leads to a non-PD system matrix for large time steps and extensions less than the rest lengths.<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5568">mathis</a> — Mon Nov 30, 2009 9:19 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[fishboy82]]></name></author>
		<updated>2009-11-30T08:46:20+00:00</updated>

		<published>2009-11-30T08:46:20+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16309#p16309</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16309#p16309"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16309#p16309"><![CDATA[
Hi mathis :<br>  Have you ever tested to derive the derivation from Baraff's stretch enegry directly but not use your spring form? Because I think there is still a little difference beacasue baraff use the particle's position as varaible rather than the extension of the spring , could this induce the K matrix to be different of  yours,just my guess .<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5261">fishboy82</a> — Mon Nov 30, 2009 8:46 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[mathis]]></name></author>
		<updated>2009-11-30T08:20:16+00:00</updated>

		<published>2009-11-30T08:20:16+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16308#p16308</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16308#p16308"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16308#p16308"><![CDATA[
Yes, they only use stretch/bend/shear-terms, but the stretch-term is a spring. They have a more general setting with triangles and uv-coordinates so that the behaviour is not so dependent on the tesselation, but for a triangle with one u- and one v-parallel edge, the formula for the stretch-term is exactly that of a spring (or actually two springs, one for the u-edge and one for the v-edge, but that doesn't matter).<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5568">mathis</a> — Mon Nov 30, 2009 8:20 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[fishboy82]]></name></author>
		<updated>2009-11-28T16:28:44+00:00</updated>

		<published>2009-11-28T16:28:44+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16291#p16291</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16291#p16291"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16291#p16291"><![CDATA[
Is it possible that they don't use the spring-like energy . I remeber they only use stretch ,bend and shear energy. May be these energy will cause a PD matrix but not all energy you derive will be a PD matrix?<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5261">fishboy82</a> — Sat Nov 28, 2009 4:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[mathis]]></name></author>
		<updated>2009-11-28T16:20:23+00:00</updated>

		<published>2009-11-28T16:20:23+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16290#p16290</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16290#p16290"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16290#p16290"><![CDATA[
They state: "The matrices we ultimately hand to our CG method are positive definite." and "Let us define the symmetric positive definite matrix A by A = M - h df/dv - h^2 df/dx."<br><br>If you read mathematical papers on the CG method, there is the requirement of positivity. Maybe that you are lucky and CG converges also for some special situations with indefinite matrices, but that's not guaranteed. Theoretically, if A is indefinite for large h, you can also find a h where A is not invertible (the h where A switches from positive definite to indefinite). But with CG we want to solve Ax=b, so we need an invertible A.<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5568">mathis</a> — Sat Nov 28, 2009 4:20 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[fishboy82]]></name></author>
		<updated>2009-11-28T08:52:20+00:00</updated>

		<published>2009-11-28T08:52:20+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16288#p16288</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16288#p16288"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16288#p16288"><![CDATA[
Hi:<br>   I roughly read the paper, but it seems baraff only mentioned that the K matrix(d2E/dx2 )<br>is a symmetric Matrix not a PD matrix (cha 4.1).<br>and in 6.1 he mentioned that CG methods, however, require symmetric matrices and there is also a label "In fact, they work best on positive definite symmetric matrices", I don't knwon CG Method  so I suppose that CG should work not only with a PD matrix but symmetric is enough?<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5261">fishboy82</a> — Sat Nov 28, 2009 8:52 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[mathis]]></name></author>
		<updated>2009-11-26T10:14:13+00:00</updated>

		<published>2009-11-26T10:14:13+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16272#p16272</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16272#p16272"/>
		<title type="html"><![CDATA[Re: Baraff/Witkin's integration matrix not positive: what to do?]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=16272#p16272"><![CDATA[
<blockquote class="uncited"><div>if you read the cloth papers people always state that the matrix is PD. </div></blockquote>Yes, this is also my impression. These papers seem to be a bit optimistic.<br><br>The case of non-PD is not academic, it occurs already for typical time steps together with stiff cloth. For positive definiteness, you get the condition m + h^2 k (1 - L/|x|) &gt; 0, so for |x| &lt; L:<br><br>h^2 &lt; m / (k * (L/|x| - 1))<br><br>This is the typical relationship between stiffness and time step which is already known from explicit euler integration, but with an additional division by (L/|x| - 1). Now one could argue that for stiff springs, |x| is always close to L, so the division is by a small number and large time steps are possible. But in a test with damped stiff structural and bending springs (bending springs being based on angles), I had to use time steps of about 1/1000 second.<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=5568">mathis</a> — Thu Nov 26, 2009 10:14 am</p><hr />
]]></content>
	</entry>
	</feed>
