[ODE] ODE Message 2: vector has zero size (part 2)

DjArcas djarcas at hotmail.com
Tue Jun 17 12:00:15 2003


This is a multi-part message in MIME format.

------=_NextPart_000_0069_01C3350B.412B6060
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Having a look at odemath.cpp, I notice these comments on dNormalize3

// this may be called for vectors `a' with extremely small magnitude, fo

// example the result of a cross product on two nearly perpendicular =
vectors

// we must be robust to these small vectors. to prevent numerical error

// first find the component a[i] with the largest magnitude and then =
scal

// all the components by 1/a[i]. then we can compute the length of `a' =
an

// scale the components by 1/l. this has been verified to work with =
vector

// containing the smallest representable numbers.



Which is followed by a hefty function. My problems are occuring in =
dNormalize4 - which doesn't appear to have any of these clever extra =
checks. Could that be part of the problem?



Adam

------=_NextPart_000_0069_01C3350B.412B6060
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1170" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Having a look at odemath.cpp, I notice =
these=20
comments on dNormalize3</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>
<P>// this may be called for vectors `a' with extremely small magnitude, =
fo</P>
<P>// example the result of a cross product on two nearly perpendicular=20
vectors</P>
<P>// we must be robust to these small vectors. to prevent numerical =
error</P>
<P>// first find the component a[i] with the largest magnitude and then =
scal</P>
<P>// all the components by 1/a[i]. then we can compute the length of =
`a' an</P>
<P>// scale the components by 1/l. this has been verified to work with=20
vector</P>
<P>// containing the smallest representable numbers.</P>
<P>&nbsp;</P>
<P><FONT face=3DArial size=3D2>Which is followed by a hefty function. My =
problems=20
are occuring in <FONT color=3D#808080>dNormalize4 - </FONT>which doesn't =
appear to=20
have any of these clever extra checks. Could that be part of the=20
problem?</FONT></P>
<P><FONT face=3DArial size=3D2></FONT>&nbsp;</P>
<P><FONT face=3DArial size=3D2>Adam</FONT></P></DIV></BODY></HTML>

------=_NextPart_000_0069_01C3350B.412B6060--