# mathematical operations

Show 40 post(s) from this thread on one page
Page 1 of 3 123 Last
• Dec 21st 2009, 10:12 AM
hebby
mathematical operations
how it is possible to remove the last three-digit of a number N using two mathematical operations
• Dec 21st 2009, 10:28 AM
Plato
Quote:

Originally Posted by hebby
how it is possible to remove the last three-digit of a number N using two mathematical operations

$\left\lfloor {\frac{N}{{1000}}} \right\rfloor$???
• Dec 21st 2009, 10:34 AM
tonio
Quote:

Originally Posted by hebby
how it is possible to remove the last three-digit of a number N using two mathematical operations

What kind of number is N? What three "last digits": from the right or from the left? What do you mean by "removing digits"?? What mathematical operations are allowed: sum, multiplication, power, taking logarithms...??
Common, some definitions!

Tonio
• Dec 21st 2009, 10:59 AM
hebby
well that well only get u a decimal with all the digits still there
• Dec 21st 2009, 11:00 AM
hebby
ya basically from the right....ie the last 3 digits....the operations u mentioned are all valid.....but a general method...to remove the last 3 digits from any number N
• Dec 21st 2009, 11:01 AM
hebby
N= whole number...integer
• Dec 21st 2009, 11:02 AM
hebby
eg) 12345=N and u end up getting 12....but minus last 3 divide by 100 is not valid as this can be applied once we know the numbers....but we actually dont know the number N
• Dec 21st 2009, 02:47 PM
tonio
Quote:

Originally Posted by hebby
ya basically from the right....ie the last 3 digits....the operations u mentioned are all valid.....but a general method...to remove the last 3 digits from any number N

No operations needed: if the number is $N=a_1a_2\ldots a_n\,,\,\,a_i\in\{0,1,2,\ldots,9\}$ , then take $N'=a_1\ldots a_{n-3}$ (Giggle)

Or more seriously: take $\left[\frac{N}{1000}\right]$, as already proposed by Plato.

Tonio
• Dec 21st 2009, 02:52 PM
hebby
hey thanks, but how would the N divided by 1000 work? as you will end up with a number with decimals, how would you remove those?
• Dec 21st 2009, 03:01 PM
Plato
Quote:

Originally Posted by hebby
hey thanks, but how would the N divided by 1000 work? as you will end up with a number with decimals, how would you remove those?

Do you understand the floor function (greatest integer function)?
$\frac{{6346765}}{{1000}} = 6346.765\,\text{ so } \,\left\lfloor {\frac{{6346765}}{{1000}}} \right\rfloor = 6346$
• Dec 21st 2009, 03:03 PM
hebby
no i never saw that before, but i can see how that would work now
• Jan 5th 2010, 03:37 PM
hebby
Hi

I was think in the lines of

1) Multiply by 10^ -3

2) The we end up with a decimal, how can I remove the decimal from the integer?

Any ideas?
• Jan 5th 2010, 09:07 PM
Bingk
I was thinking ... would the floor function be considered as an operation? Just curious about that

Could you also try ( N - ( N (mod 1000) ) ) / 1000? Basically, N minus the remainder when you divide by 1000, then divide that by 1000 ....
• Jan 5th 2010, 09:10 PM
hebby
Could you show a numerical example on how that might work?
• Jan 5th 2010, 09:17 PM
Drexel28
Quote:

Originally Posted by Bingk
I was thinking ... would the floor function be considered as an operation? Just curious about that

Could you also try ( N - ( N (mod 1000) ) ) / 1000? Basically, N minus the remainder when you divide by 1000, then divide that by 1000 ....

$x-\{x\}=\lfloor x\rfloor$. But, $\frac{N}{1000}-N\text{ mod }1000=\frac{N}{1000}-\left\{\frac{N}{1000}\right\}=\left\lfloor \frac{N}{1000}\right\rfloor$. So, really all you've done is restate Plato's response.
Show 40 post(s) from this thread on one page
Page 1 of 3 123 Last