Hexagony, 161161 122 bytes
?{10''d0=.{&1=10''2\}{{<{1&{=*{=&/........}u44.\4476'*0&}=..:1&'$/:!@...>105_03""-~+{&<..)"<>-":\$....=&={{/.00000|"=}{{&={*={&1d000000}24=<....|...\{=&={.+..>""'....(<>........}240504"-~{&137{:_1&':!@..~<>"._3724476'*0){.>}{}11744..=}&={=$/_"'\>{={<>(<\&1=/
? . { 1 0 ' ' d 0
= { & 12 =\ } { {} <
u 4 4
{ 1. &\ {4 =4 *7 {6 =' &* /0
. .& .} .= . . .$ ./ .: ." .-
+ :{ 1= & ' : != @{ .{ ./ . >| 1"
= 0} 5{ _{ 0& 3= "{ -* ~= { & < . .1
) " < > - " : \ $ . . . .d .
0 0 0 0 0 0 } { { } 2 4 = < . .
.0 .5 |0 .4 ." .- \~ { = & = {1 .3 +7
.{ .: >_ "1 "& ' .: .! .@ . ( < >.
. . .~ .< .> ." . .) .{ .{ .{ _=
3 7 2 4$ 4/ 7_ 6" ' * 0 {
.\ > } { } 1 1 7 4 4=
. .{ =< }> &( =< {\ {& {1
. .= ./ . . . . .
My first go at a Hexagony program. I will return to this later to hopefully golf it down considerably. The precision is overkill and the layout is very lazy, so there shouldCould probably still be lots of bytes to save. For nowgolfed some, but I'm just quite happy thatto have gotten it worksto side length 7.
We take the input and keep a running count of how many digits long we think it is. We enter a loop. For each iteration, we square the input and double this running count (since squaring roughly doubles length). We then truncate the input to the first 7 digits, and add the number of digits we took off to our running count. Iterating 24 times gives us more than enough precision. We then take our predicted length, add a constant, multiply by a constant and print it out.
The agony
So how is this implemented exactly? I'll refer to the memory graph as it is labeled below. as well as the colored paths.
Note that I only use one instruction pointer for this program, which is probably not optimal. We begin on the blue path. This initializes some variables, putting the input in A, 10
in H, 100000000
in I, and 24
on L leaving the memory pointer in L. Then on to the main loop in green. The main loop first uses G and F to square A, then similarly uses E and K to double D. Moving the memory pointer to B, we then use the yellow path to redirect into a sub loop on the orange tiles. This sub loop uses B an C to divide A by 10, compare against I and increment D. Once the input is less than I, We use the red path to traverse back to the main loop, putting the memory pointer back on L and decrementing. L serves as the main loop counter. Once L is 0, we break out of the main loop and on to the purple track. The purple track uses C and J to do the final subtraction and multiplication on the output in D. The final output ends up in J
Visualizations done with hexagony.net.