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

 Formula Formulation (Posted on 2014-03-03)
A function f(N) is defined as:
f(1)=sod(12), f(2) = sod(122)
f(3) = sod(1212), f(4) = sod(12122), .... and, so on

Derive the general formula for f(N) in terms of N.

*** sod(x) denotes the sum of the digits of base ten expansion of x.

 No Solution Yet Submitted by K Sengupta No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
 first few | Comment 3 of 4 |

5   S=""
10   for N=1 to 40
20      S=S+mid("21",N@2+1,1)
30      B=val(S)
40      P=B^2
50      Ps=cutspc(str(P))
60      T=0
70      for I=1 to len(Ps):T=T+val(mid(Ps,I,1)):next
80      print N,S,tab(48);T;sqrt(T)
90   next

finds

`n                                              f(n)    sqrt(f(n))  7      1212121                                  55  7.41619848709566294868      12121212                                 72  8.48528137423857029279      121212121                                79  8.8881944173155888510     1212121212                               90  9.486832980505137995911     12121212121                              94  9.69535971483265802812     121212121212                             108  10.392304845413263761113     1212121212121                            118  10.862780491200215723814     12121212121212                           126  11.224972160321824156715     121212121212121                          133  11.532562594670795889316     1212121212121212                         144  12.017     12121212121212121                        157  12.529964086141667788418     121212121212121212                       162  12.727922061357855439119     1212121212121212121                      163  12.767145334803704661620     12121212121212121212                     171  13.076696830622020656621     121212121212121212121                    178  13.341664064126333712422     1212121212121212121212                   198  14.071247279470288663623     12121212121212121212121                  193  13.892443989449804508324     121212121212121212121212                 207  14.387494569938158624725     1212121212121212121212121                208  14.422205101855957172426     12121212121212121212121212               234  15.2970585407783544927     121212121212121212121212121              232  15.231546211727816571228     1212121212121212121212121212             252  15.874507866387543542929     12121212121212121212121212121            247  15.716233645501710980230     121212121212121212121212121212           270  16.431676725154983403631     1212121212121212121212121212121          271  16.462077633154327947632     12121212121212121212121212121212         288  16.970562748477140585533     121212121212121212121212121212121        286  16.911534525287762898134     1212121212121212121212121212121212       306  17.492855684535901412535     12121212121212121212121212121212121      310  17.606816861659009145736     121212121212121212121212121212121212     324  18.037     1212121212121212121212121212121212121    325  18.027756377319946465538     12121212121212121212121212121212121212   342  18.493242008906929350739     121212121212121212121212121212121212121  349  18.681541692269404348440     1212121212121212121212121212121212121212 360  18.9736659610102759919`

 Posted by Charlie on 2014-03-03 17:22:45

 Search: Search body:
Forums (0)