Naked Science Forum

Non Life Sciences => Physics, Astronomy & Cosmology => Topic started by: tommya300 on 14/07/2010 21:51:27

Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 14/07/2010 21:51:27
.
I will try to make this clear direct me if it is not.
In simple scientific solution, the equation contain individual numerical clusters separated by the math functions that will look like e.g. 1234.5 e^3 of defined digits that is 7 digits defining the value. Such as 1,234,500

If a particular constant value is introduced that has the fractional portion, which can extend infinitely longer then 7 digits; e.g. Pi or the square root of 2 or the reciprocal of the sin 45 deg
1.4142135623730950488016887242097

At which of these digits after the decimal point should the correct rounding out respectfully be 5th, 6th or 7th digit long?
 .

Title: What is the rule for rounding out numbers in an equation?
Post by: Pmb on 14/07/2010 22:56:15
I will try to make this clear direct me if it is not.
In simple scientific solution, the equation contain individual numerical clusters separated by the math functions that will look like e.g. 1234.5 e^3 of defined digits that is 7 digits defining the value. Such as 1,234,500

If a particular constant value is introduced that has the fractional portion, which can extend infinitely longer then 7 digits; e.g. Pi or the square root of 2 or the reciprocal of the sin 45 deg
1.4142135623730950488016887242097

At which of these digits after the decimal point should the correct rounding out respectfully be 5th, 6th or 7th digit long?
Your original expression has 5 significan figures so after you add that to, say, pi, then round that to 5 significan figures as well.
Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 14/07/2010 23:40:26
I will try to make this clear direct me if it is not.
In simple scientific solution, the equation contain individual numerical clusters separated by the math functions that will look like e.g. 1234.5 e^3 of defined digits that is 7 digits defining the value. Such as 1,234,500

If a particular constant value is introduced that has the fractional portion, which can extend infinitely longer then 7 digits; e.g. Pi or the square root of 2 or the reciprocal of the sin 45 deg
1.4142135623730950488016887242097

At which of these digits after the decimal point should the correct rounding out respectfully be 5th, 6th or 7th digit long?
Your original expression has 5 significan figures so after you add that to, say, pi, then round that to 5 significan figures as well.

Thanks for the reply Pmb!
Would I need to round out  Pi = 3.14159  before the math manipulation?
Input to a calculator pi button will give a long readout.
 Maintaining the rounding out each time through each step of the way??
Let's say I needed to document each step and reproducing the end results after.
.  
Title: What is the rule for rounding out numbers in an equation?
Post by: Pmb on 15/07/2010 01:11:57
Would I need to round out  Pi = 3.14159  before the math manipulation?
You're very welcome, and no. You don't need to round Pi

Rounding is only done at the end of a calculation, not for each step. But keep in mind this assumes that each term used is either exact or has more significan digits than the number input.

This topic is covered in text on numerical analysis. Usually in the first chapter. Would you like me to scan one in and post a link to it?
Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 15/07/2010 02:42:14
Would I need to round out  Pi = 3.14159  before the math manipulation?
You're very welcome, and no. You don't need to round Pi

Rounding is only done at the end of a calculation, not for each step. But keep in mind this assumes that each term used is either exact or has more significan digits than the number input.

This topic is covered in text on numerical analysis. Usually in the first chapter. Would you like me to scan one in and post a link to it?

Yes please! There may be other aspects that I may have no knowledge of to ask any questions.
Title: What is the rule for rounding out numbers in an equation?
Post by: Pmb on 15/07/2010 03:05:29
Yes please! There may be other aspects that I may have no knowledge of to ask any questions.
Okay. I'll do it tomorrow afternoon. Right now I'm off to bed and in the morning I have to go to the hospital. So tomorrow afternoon I'll be able to do that. See you tomorrow. :)

Please PM your e-mail address to me so I can e-mail the scans.

Title: What is the rule for rounding out numbers in an equation?
Post by: Bored chemist on 15/07/2010 06:55:06
Would I need to round out  Pi = 3.14159  before the math manipulation?
You're very welcome, and no. You don't need to round Pi



It's a matter of definition but, if you want to multiply all of pi by two it will take you an infinitely long time.
You round before, or during the calculation.
Title: What is the rule for rounding out numbers in an equation?
Post by: Pmb on 15/07/2010 08:12:16
Would I need to round out  Pi = 3.14159  before the math manipulation?
You're very welcome, and no. You don't need to round Pi

Rounding is only done at the end of a calculation, not for each step. But keep in mind this assumes that each term used is either exact or has more significan digits than the number input.

This topic is covered in text on numerical analysis. Usually in the first chapter. Would you like me to scan one in and post a link to it?

Yes please! There may be other aspects that I may have no knowledge of to ask any questions.
Sorry but I made a mistake above. Its not a text on numerical analysis that you want. I now recall where I first learned about the process of rounding. It was in a chemistry text. Since I have insomian :( I'm scanning this in now from the chemistry text I have in my bookcase. I'll see if I can post this on my website.
Title: What is the rule for rounding out numbers in an equation?
Post by: Pmb on 15/07/2010 08:43:46
Okay. I've scanned the text and have uploaded it to my website. See http://home.comcast.net/~peter.m.brown/rounding.pdf
Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 15/07/2010 12:18:59
.
OK thanks guys
Let's see if I understand.
Rounding out to the most significant digit depends on... e.g.
1.2345 + 3.14159 = 4.37609 is incorrectly rounded?
should this be rounded during the aritmetic process  1.2345 + 3.1416 =  4.3761
or
1.23 + 3.1416 = 4.3716  is incorrectly rounded?
1.23 + 3.14 = 4.37      correctly rounded?
or
(6.3781e6)(1/.7071067) + 6.3781e6 ...needs correction?
rewrite to
(6.3781e6)(1.4142136) + (6.3781e6)= ... is this incorrectly rounding?
(6.3781e6)(1.4142) + (6.3781e6)= ...  is this properly corrected rounding?

.
Title: What is the rule for rounding out numbers in an equation?
Post by: imatfaal on 15/07/2010 17:56:28
Tommy
If you break down your first sum it can demonstrate where problems might arise

1.2345 + 3.14159 = 4.37609       
      
But each of those numbers represents a range - as you have above mentioned
      
HI    1.234549    
LOW 1.234450    
            
hi   3.1415949    
low 3.1415850    

      
When you add the extremes of the range you find that the max potential error swamps the last digits you give      
    HIGH         LOW
hi   4.376144     4.376045
low 4.376134     4.376035

your range is approximately 4.376035-4.376144 (of course this itself has uncertainties/errors), you cannot be certain of anything past the 3rd decimal place. 

Personally, in all your examples I would try not to multiply out pi or root two (1.4142) until the very last moment in the hope that they will cancel or multiply out, and unless you need a plain number answer you can leave them in the actual answer.  Hope that helped a bit - I would also say that the pages Peter put up are very informative and easily digested. Matthew
Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 15/07/2010 19:14:05
Tommy
If you break down your first sum it can demonstrate where problems might arise

1.2345 + 3.14159 = 4.37609       
      
But each of those numbers represents a range - as you have above mentioned
      
HI    1.234549    
LOW 1.234450    
            
hi   3.1415949    
low 3.1415850    

      
When you add the extremes of the range you find that the max potential error swamps the last digits you give      
    HIGH         LOW
hi   4.376144     4.376045
low 4.376134     4.376035

your range is approximately 4.376035-4.376144 (of course this itself has uncertainties/errors), you cannot be certain of anything past the 3rd decimal place. 

Personally, in all your examples I would try not to multiply out pi or root two (1.4142) until the very last moment in the hope that they will cancel or multiply out, and unless you need a plain number answer you can leave them in the actual answer.  Hope that helped a bit - I would also say that the pages Peter put up are very informative and easily digested. Matthew

Helps a bit more Matthew.
Is that why tolerance values are highly observed?
Title: What is the rule for rounding out numbers in an equation?
Post by: Geezer on 15/07/2010 23:17:06

Is that why tolerance values are highly observed?


I don't think so. Manufacturing tolerances are more to do with cost than anything else.

Computational precision is more about knowing how precise your result needs to be. If you need an answer that's precise to 1% (one part in a hundred), the values that you use in your calculation should probably have a resolution of 0.1% (one part in a thousand).

So, it's really a question of knowing how much resolution (precision) you need in your result, and that very much depends on what you are going to do with the result.

A 1% error rate might not sound too bad, unless you are talking about midwives dropping babies on the floor when they are born.



Title: What is the rule for rounding out numbers in an equation?
Post by: tommya300 on 16/07/2010 02:42:27

Is that why tolerance values are highly observed?


I don't think so. Manufacturing tolerances are more to do with cost than anything else.

Computational precision is more about knowing how precise your result needs to be. If you need an answer that's precise to 1% (one part in a hundred), the values that you use in your calculation should probably have a resolution of 0.1% (one part in a thousand).

So, it's really a question of knowing how much resolution (precision) you need in your result, and that very much depends on what you are going to do with the result.

A 1% error rate might not sound too bad, unless you are talking about midwives dropping babies on the floor when they are born.


Thanks Geezer I think I understand. Is it that the difference in hitting a targets bullseye vs. a manufacturing slip fit?

Database Error

Please try again. If you come back to this error screen, report the error to an administrator.
Back