The Numberphile Topic -- The Official Nerdy Math Topic! [OLD]

math
nobullying

#514

This reminded me of the 4 fours! I don’t know why but it did.
I also need to tell you that when you asked me if I had 113, I actually didn’t. I realized that it was 113 1/9.
I was pretty close

Yeah, (4^4) * 4/9 = 113.7777…
And 113.7777 - 2/3 = 113.11111…

Argh I was so close oh well
We need to wright some code that solves all of the combinations of 4 fours


#515

@BuildASnowman (or anyone else interested)

I created a Hopscotch project to calculate any Log N with any base b. The algorithm is my own creation, so it’s a naive solution but it appears to get the job done. (by naive I mean I just implemented what I consider to be a logical solution, as opposed to say a Taylor series with range reduction)

I’m curious on your thoughts of how this could be more elegant or efficient. Or if you notice any errors.

  • Essentially the algorithm iterates the answer until b^Answer = N
  • First the Answer is set to 1 or -1, and a variable ‘Reverse’ is also set to 1 or -1 to avoid extra conditionals in the subsequent recursions
  • Using resursion, Answer is doubled to the correct range of 2^n or -(2^n)
  • Answer is recursively refined using decreasing steps ('delta’s)
    .
Algorithm screenshots

  1. Check Once if b ^ (answer x Reverse) < N ^ Reverse

  1. Check if Else b ^ answer < N
  2. Check Once if Trunc (Answer) to 7 decimal places != Trunc (previous Answer) to 7 decimal places

.


#516

That is crazy epic!!! Should get featured

(There needs to be a #math filter or a Math project filter that works like feature, but for cool math projects)

A next idea should be Ln, e
(Or maybe even “i” woah!! That’s be a super cool project!!)


#517

Thanks

That project will do natural log as is… just enter e as the base.

Use 2.718281828459045 as that’s all the digits of e that a Hopscotch variable will hold. Though a project to calculate e should be relatively trivial since it’s just a simple summation of 1/n!. Using clones n! can be calculated in 1 or 2 frames, so the algorithm should run pretty quickly too

Note: While a variable will hold 2.718281828459045, when set to a text the text will only read 2.718282 as texts currently round numbers to 6 decimals of precision


#518

Ah, ok, that makes a lot of sense

I was thinking of maybe doing to Reimann Zeta functions since it’s a summation using factorials/Squares (can’t remember which)

I’ll find it on Wikipedia

Edit:
Yeah, it was squares


#519

I’m sorry I haven’t had a chance to look at this until now, school and mock trial have been hitting me hard!

I understand your algorithm and while it is very elegant and well-implemented, I’m convinced it can be tweaked for more efficiency. Although you do have the question of when it’s worth it to sacrifice simplicity for the sake of efficiency, and as you say, it’s better to have a logical solution than an efficient one.

Though, I wonder how well we could do with a simple Pade Approximation (read: better version of trunucated power series). For example, just a quick calculation with Mathematica gives:

ln (1+y)/(1-y) = 2y*(15 - 4y^2 )/(15 - 9y^2 )

With a maximum error of -0.000025.

I’ll have to take some time with my IPad tonight and see if I can optimize anything, though. Thank you for tagging me about this!

Slightly unrelated, but this reminds me of this bit-hacky way to calculate logarithms in O(log n) time that I absolutely love:
https://graphics.stanford.edu/~seander/bithacks.html#IntegerLog

It would be impossible to implement in Hopscotch though.


#520

Oddly, I came across that same bit twiddling hacks page a few days ago. I quickly discarded it for my Hopscotch log calculation purposes, but now I’m trying to go back and understand how it works…


Have you seen this Computing Logarithms Digit-by-Digit? Seemed interesting but I didn’t initially follow how it worked either, so I just stuck with the algorithm I developed.


#521

Bump! Interesting topic :blush:


#522

Do you say “Nine and five is thirteen” or “Nine and five are thirteen”?


#523

Oh my, this is English in Math! :anguished:
Whaaaa?..

I’m thinking it’s “are” since it’s plural, but they conjoint to make a singular number.. oh my


#524

Quote for a spoiler…

Neither. Nine and five are fourteen xD


#525

Hmm… I guess that makes sense? Not really… oh well, that’s what happens when English mixes with Math I guess (It does make some challenging logic problems though)


#526

Do you know anyone on Scratch? I’m awesomeplanet. https://scratch.mit.edu/users/awesomeplanet/ I need someone to alpha test my new work-in-progress project.


#527

Test Post


#529

okay this seems like a kewl topic but literally? my mth knowledge? w H oMph it dont exist

my entire brain is like brain subsitute tbh

i can’t believe it’s not brain!


#530

Yeah, literally dude. You like bullied me. Raise the hater counter to 6. Augggggghh!


#531

How about 60000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000?


#533

Chill, please.


#534

Why don’t you try being less of a jerk? You literally can’t be “less autistic.” Just because you don’t and will never understand how autism works, that doesn’t mean you have to bully every single autistic person you see! Get off the forum, if you can’t be nice!


#535

@Liza, we have an autism hating bully here. He’s called xse. Also known as ihaveexpectations. Please ban him.