All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Numbers
House Numbers on the Clock Street (Posted on 2023-11-10) Difficulty: 3 of 5
The house numbers on Clock Street are the same as the seconds on a digital clock, namely:

       00:00:00, 00:00:01, ..., 00:00:59, 00:01:00, ..., 00:59:59, 01:00:00, ..., 23:59:59

(A) The sum of the addresses up to and including Jack's house equals the sum of the addresses past Jack's house up to and including Jake's house. What are their addresses? (There are several solutions. Please give the largest.)

(B) The sum of the even addresses up to Jane's house equals the sum of the odd addresses past Jane's house up to and including June's house. What are their addresses? (There are several solutions. Please give the largest.)

Note: The addresses are added like one adds times. Like, 00:50+00:50=01:40

No Solution Yet Submitted by K Sengupta    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solution Comment 1 of 1
Writing the number of seconds into the day in clock format is isomorphic to writint them as ordinary arabic numbers:

00:01:40 is 100 seconds into the day
00:03:50 is 230 seconds into the day
--------    ---
    5:30    330 are both representations of 330 seconds into the day.
    
so it doesn't matter the form in which the addresses appear.

Let Jack's house be a and Jake's house be b.

a(a+1)       (b-a)(a+1+b)
------   =   ------------
   2              2

a(a+1)  =  (b-a)(a+1+b)

a^2 + a  =  b*a + b + b^2 - a^2 - a - a*b

2*a^2 + 2*a  = b^2 + b

for t2=86399:-1:10
  syms t
  % s=solve(@(t)2*t^2+2*t==t2^2+t2);
  s=roots([2 2 -t2^2-t2]);
  if abs(s(2)-round(s(2)))<.00001
    disp([s(2) t2])
    s1=seconds(s(2)); s2=seconds(t2);
    s1.Format='hh:mm:ss'; s2.Format='hh:mm:ss'; 
     s1, s2
    % break
  end
end

Starting with b=23*3600+59*60+59   = 86399, solving for a, and trying decreasing values from there, the first integer value of a we get to is the largest possible:

Jack at 16730 or 04:38:50        Jake at 23660 or 06:34:20

Verification:

>> sum(1:16730),sum(16731:23660)
ans =
   139954815
ans =
   139954815

Jane and June present a more difficult problem especially as the cases of Jane at an odd position and an even position differ. June is apparently already known to be at an odd house number.


clearvars
evensum=0; oddsum=1; june=1;
for jane=1:86400
   if mod(jane,2)==0
     evensum=evensum+jane-2;
   else
     oddsum=oddsum-jane;
   end
   while oddsum<evensum
     june=june+2;
     oddsum=oddsum+june;
   end
   if evensum==oddsum
     disp([jane june evensum])
   end
end

Showing on each line:

Jane's house, June's house, sum of eves prior to Jane
                            which equals sum of odds after Jand 
                              up to and including June's
>> houseNumbersOnClockStreet
     1     1     0
     2     1     0
     3     3     0
    33    45   240
    50    69   600
          91         127        1980
        1105        1561      304152
        1682        2377      706440
        3075        4347     2360832
       37521       53061   351918840
       57122       80781   815702160
>> sum(2:2:57120),sum(57123:2:80781)
ans =
   815702160
ans =
   815702160
>> 

The two sums at the bottom verify the sums obtained through addition and subtraction in the program.

The next step is to convert the house numbers to the time format, and also to limit the addresses to the 24-hour range:

clearvars
evensum=0; oddsum=1; june=1;
for jane=1:86400
   if oddsum>86400
     break
   end
   if mod(jane,2)==0
     evensum=evensum+jane-2;
   else
     oddsum=oddsum-jane;
   end
   while oddsum<evensum
     june=june+2;
     oddsum=oddsum+june;
   end
   if evensum==oddsum
     janes=seconds(jane);
     junes=seconds(june);
     evensums=seconds(evensum);
     janes.Format='hh:mm:ss';
     junes.Format='hh:mm:ss';
     evensums.Format='hh:mm:ss';
     disp([janes junes evensums])
   end
end

>> houseNumbersOnClockStreet
   00:00:01   00:00:01   00:00:00
   00:00:02   00:00:01   00:00:00
   00:00:03   00:00:03   00:00:00
   00:00:33   00:00:45   00:04:00
   00:00:50   00:01:09   00:10:00
   00:01:31   00:02:07   00:33:00
>> 

The largest case has Jane at 00:01:31, June at 00:02:07, and each of the two totals as  00:33:00, previously reported numerically as 91, 127, and 1980 respectively.

  Posted by Charlie on 2023-11-10 13:31:29
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (9)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information