|
| BF4 | |
|
| Facebook | |
|
|
|
|
by: Oðuz Ata - 15 Haziran 2014 Pazar 00:42:09
Russian peasant multiplication
In the Russian peasant method, the powers of two in the decomposition of the multiplicand are found by writing it on the left and progressively halving the left column, discarding any remainder, until the value is 1 (or -1, in which case the eventual sum is negated), while doubling the right column as before. Lines with even numbers on the left column are struck out, and the remaining numbers on the right are added together.[1]
For example, to multiply 238 by 13, the smaller of the numbers (to reduce the number of steps), 13, is written on the left and the larger on the right. The left number is progressively halved (discarding any remainder) and the right one doubled, until the left number is 1: |
|
13 |
|
238 |
|
|
6 |
(remainder discarded) |
476 |
|
|
3 |
|
952 |
|
|
1 |
(remainder discarded) |
1904 |
|
Lines with even numbers on the left column are struck out, and the remaining numbers on the right are added, giving the answer as 3094: |
|
13 |
|
238 |
|
6 |
|
476 |
|
3 |
|
952 |
|
1 |
|
+ 1904 |
|
|
|
|
|
|
|
3094 |
The algorithm can be illustrated with the binary representation of the numbers: |
1101 |
(13) |
11101110 |
(238) |
110 |
(6) |
111011100 |
(476) |
11 |
(3) |
1110111000 |
(952) |
1 |
(1) |
11101110000 |
(1904) |
|
|
|
|
|
1 |
1 |
1 |
0 |
1 |
1 |
1 |
0 |
(238) |
× |
|
1 |
1 |
0 |
1 |
(13) |
|
|
1 |
1 |
1 |
0 |
1 |
1 |
1 |
0 |
(238) |
|
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
(0) |
|
1 |
1 |
1 |
0 |
1 |
1 |
1 |
0 |
0 |
0 |
(952) |
+ |
|
1 |
1 |
1 |
0 |
1 |
1 |
1 |
0 |
0 |
0 |
0 |
(1904) |
|
|
1 |
1 |
0 |
0 |
0 |
0 |
0 |
1 |
0 |
1 |
1 |
0 |
(3094)
|
viewed 10373 times -
|
|
|
|
|
| Sınav Soruları | |
|
|
|