Houdini precision

   5317   5   0
User Avatar
Member
131 posts
Joined: Oct. 2011
Offline
Hi,

I remember getting some results a while ago that I was planning on asking. Basically sometimes I was typing integers into numeric fields and was getting tiny fractions like .0000004 or something.

I don't remember the exact values, but is this common? I ask this because I am wondering if H12's moving everything to doubles will fix this issue?




Thanks all
User Avatar
Member
98 posts
Joined: Jan. 2008
Offline
same thing here. It really buged me at first.. but now i am somehow used to it.
User Avatar
Staff
181 posts
Joined: July 2005
Offline
On any float parameter, the new behaviour in H11 is to show full precision if it is in “expression” mode. Just left mouse click on the parameter name to get it back to “normal” mode.
User Avatar
Member
51 posts
Joined: Oct. 2006
Offline
Are you sure those numbers were integers?
This happens with floating-point values when the field is in “expression” mode (see the pic). (Edit: Sorry, didn't see this was already explained while I was typing my response.)

I don't think it has anything to do with internal precision though, some numbers are just not representable exactly in binary form, either floats or doubles.
For example, try the following in Python Shell (Python uses doubles):
print ‘%(#).17f’ % {“#”:1.0/10}
print ‘%(#).17f’ % {“#”:0.7}
Edited by - Dec. 5, 2011 14:56:29

Attachments:
too_many_digits.jpg (17.8 KB)

User Avatar
Member
1390 posts
Joined: July 2005
Offline
he, he, I had to explain this several times to new people (perhaps a hint for Help department?).

In other words, ironically, this is a over-precision, not lack of it
User Avatar
Member
131 posts
Joined: Oct. 2011
Offline
Thanks guys. That makes sense now.

@axebeak: I was talking about integers but worded it wrong. I meant when I was typing integers into float numeric fields which becomes floats anyway
  • Quick Links