This is not really a "Quickie".

The solution is a bit longer, but it's quite clever.

In base , the fraction and the fraction

In base , the fraction and the fraction

Find

Printable View

- Jan 19th 2007, 10:02 PMSorobanQuickie #14
This is not really a "Quickie".

The solution is a bit longer, but it's quite clever.

In base , the fraction and the fraction

In base , the fraction and the fraction

Find

- Jan 20th 2007, 12:16 AMCaptainBlack
- Jan 20th 2007, 06:33 AMearboth
Hello Soroban,

if you multiply a fraction in "decimal" notation by the base you move the "decimal" point one digit to the right. (It's a more general rule to the SHR-command in assembler).

If you multiply F_2 by A then the digits after the "decimal" point are the same as at F_1. If you subtract F_1 from A*F_2 then you get an integer. If you multiply F_1 by A then the digits after the "decimal" point are the same as at F_2. If you subtract F_2 from A*F_1 then you get an integer.

This method will give 4 linear equations:

I've got: A = 11, B= 8, F_1=1/3, F_3=2/3 (this time base 10)

EB

PS: As usual CaptainBlack is much faster than I:( - Jan 20th 2007, 08:00 AMSoroban
Hello, Captain Black and earboth!

I thought my book had a clever solution.

. . But yours are much shorter and more elegant.

I still want to show everyone the book's solution.

. . It has an interesting (unexpected) approach.

. . Hence: .**[1]**

Similarly: .**[2]**

Add**[1]**and**[2]**: .

. .

. .**[3]**

Subtract**[1]**from**[2]**: .

. .

. .**[4]**

**[3]**and**[4]**give us a system of equations: .

. . with solutions: .

Then: .

I agree . . . This solution is much longer.

But there are some interesting techniques involved

. . which I've added to my arsenal.