Today I Learned

  • Thread starter Greg Bernhardt
  • Start date
In summary: Today I learned that Lagrange was Italian and that he lamented the execution of Lavoisier in France during the French Revolution with the quote:"It took them only an instant to cut off this head and a hundred years might not suffice to reproduce it's...brains."
  • #491
For (10^10)! ? The Stirling formula, of course.
For 200! I guess they have the result stored somewhere.
 
Physics news on Phys.org
  • #492
Stephanus said:
Oh my God!. And in 1 second, too. What kind of method that they use??
If I run my method, it will take 1000 years! (or more?) And takes my entire RAM 4 x 10^9, but I think windows will switch to hard drive, but still 1000 years.
It's not clear what method you are using to calculate 200!, nor why this computation would swallow up 4GB of RAM. But that's the secret surprise in studying numerical analysis: you learn to do more with less.

Clearly, using floating-point arithmetic would be a non-starter. The result WA gives for 200! seems to be expressed in a reasonably finite number of decimal digits.

This article:
http://en.wikipedia.org/wiki/Arbitrary-precision_arithmetic

presents the code of an algorithm for doing arbitrary-precision integer arithmetic, specifically geared to calculating factorials.

I suspect that WA has a similar routine built into its programming somewhere. There are other examples of arbitrary-precision arithmetic on the web.
 
  • Like
Likes Stephanus
  • #493
Hi SteamKing, hi Mfb, hi everybody

SteamKing said:
It's not clear what method you are using to calculate 200!, nor why this computation would SWALLOW 4 GB
Hi SteamKing, glad to see you again after you answer my thread https://www.physicsforums.com/threads/neutron-star-temperature.814116/
My method? Actually it's a simple one.
The most significant and accurate floating point variable in Delphi (and I guess many programming languages) is 10 bytes real. Extended, in Delphi. long double in C.
So I have to make my own variable type: (I convert it to C, because many familiar in C more than Pascal)

Code:
[FONT=Courier New][SIZE=3]char[2000] Number;
/* for 2000 digits base ten number,
   should use BCD style, but more complex. You can guess for (10^10)!
   which takes billions of digits, the array should be bigger */

int Carry;   // to store for example x = 6 * 4, then Carry = 2
int Modulus; // to store x = 6 * 4, then Modulus = 4
int NumLen;  // for 100 NumLen = 2, for 1000 NumLen = 3, etc...

void MultiplyNumberByX(int ByX); // you can guess
                                 // the rest of the function.[/SIZE][/FONT]

mfb said:
For (10^10)! ? The Stirling formula, of course.

[PLAIN]http://mathworld.wolfram.com/images/equations/StirlingsApproximation/Inline11.gif[PLAIN]http://mathworld.wolfram.com/images/equations/StirlingsApproximation/Inline13.gif
Well, glancing for a while from http://mathworld.wolfram.com/StirlingsApproximation.html, using that integral sign (and of course approximation symbol),
no mystery here that wolfram is very quick. But it's still an impressive software.
And natural number is impressive, too.
ln n! = ln 1 + ln 2 + ln 3.
Like OmCheeto said, the number that's derived from a sequence of factorial, can be used to find factorial itself.

Talking about natural number, do anybody know what other constant like Pi, Ln(1) sorry, my poor latex, and Golden ratio?
I mean constants that are not bound by physical law.
Supposed other aliens using a length unit. They wouldn't measure in Earth metric, right. They don't have to divide their length unit from the circumference of their planet by 40,000 (and why should 40,000 at all).
All their constant would be different from us. Gravity, Planck (if they do have someone named Planck, there), Avogadro, etc...
I think an advanced civilization will eventually suspect about Golden Ratio.


So, do anybody know what other constants other than Pi, Ln(1), and Golden Ratio, that are not bound by physical law? Their Pi, Golden Ratio, would still match ours even if they use different base number.
Is Planck constant theoretical or not?

Thanks.

 
Last edited by a moderator:
  • #495
Back on topic here:

I made a list. The first column is just the uncalculated factorials from 1 to 69, which is the limit of my calculator. The second column is the corresponding number of digits for each factorial, and the third column is the difference between the number and the number of digits in its factorial. Like this:

12! (9) -3
13! (10) -3
14! (11) -3

The results were interesting and show the 22! 23! 24! triplet is inevitable. On the whole it looks like two different frequencies accelerating at different rates but which happen to "beat" right there. Generally it looks like the factorials of any two successive numbers will jump one order of magnitude from one to the next, but this is is increasingly interrupted by larger jumps in order of magnitude. The frequency of those jumps, and the amount of them, seemed to be accelerating in it's own right in a way that might be predictable, but my calculator started returning "error" results at 70!.
 
  • #496
Remember that 20!=20*19!, for example.
If you multiply 1... to 4... by 20=10*2 you get one digit more (factor 10) and the first digit increases to 2 to 9 (factor 2). If you multiply 5... to 9... by 20, you get two digits more and the first digit decreases to 1.

That way, factors of 11 to 99 are always adding one or two digits, with larger numbers adding two digits more frequently. 100 adds two digits, following factors add at least two digits (occasionally three), and so on.

Challenge: find the smallest base b such that there is no n! with n digits, or proof there is no such base. I would expect there to be some base, which means there is a smallest one.Today I learned that I don't want to live on exoplanet Kepler-10b. The weather forecast is horrible.
 
  • Like
Likes Stephanus
  • #497
mfb said:
Challenge: find the smallest base b such that there is no n! with n digits, or proof there is no such base. I would expect there to be some base, which means there is a smallest one.
I've found some
9, 13, 31.
But why?

The number of digits in an f! for n digits is
int(n Log f!)
So what we have to find is f = int(n log f!)
stuck here.
 
Last edited:
  • #498
mfb said:
Remember that 20!=20*19!, for example.
If you multiply 1... to 4... by 20=10*2 you get one digit more (factor 10) and the first digit increases to 2 to 9 (factor 2). If you multiply 5... to 9... by 20, you get two digits more and the first digit decreases to 1.

That way, factors of 11 to 99 are always adding one or two digits, with larger numbers adding two digits more frequently. 100 adds two digits, following factors add at least two digits (occasionally three), and so on.
This explains it! Thanks! It took me the longest time to fathom what you were saying, but I see now that, given any factorial, it's simple to predict how many digits will be in the next one; how many digits it will jump, and also explains why the breaks are more frequent as the factorials get higher. That's the "acceleration" I saw but couldn't explain.
 
  • #499
Today I learned that if I drop a warm can of diet coke on a ceramic tile floor the can instantly becomes a self opening container. This is not an absolute but I am not willing to drop enough cans to find out. Now back to factorials.
 
  • Like
Likes Stephanus
  • #500
Today I learned that if you shake a closed cup glass tupperware filled with hot water, it will pop (kinda explode) the top.
It's just that I didn't bring spoon to brew some coffee, so instead of stirred it with spoon, I shook it. The top tumbled, the coffe spilled. I brew some coffee again, now I USE SPOON!
 
  • Like
Likes edward
  • #501
Today I learned that studying abroad is a great way to learn new things, new culture, ideas, lifestyle as well as education system. We all know that we are living in a world with full of diverse people, and by studying abroad, we can try to experience dealing with those people and learn something from them that would help us be a better individuals and be prepared for next generation's global leaders.
 
  • #502
today I learned that if you learn socket programming in vb.net the world is your oyster :-p
 
  • #503
Today I learned why bees (and other insects) are all over our cherry laurel, even though it's much too early for flowers. It turns out that young leaves of that plant ooze a bit of nectar (from "extrafloral nectaries"). I cut it back a lot last year, so there are lots of new leaves coming out all over it.
 
  • Like
Likes Silicon Waffle, dlgoff, zoobyshoe and 1 other person
  • #504
And I learned that a worker bee is not necessarily a male bee but it also doesn't have a reproductive system. :nb) A real queen bee is well covered and over protected!
 
  • Like
Likes Stephanus
  • #505
Today I learned that PF looks way different from what I remember and I suddenly got a bunch of rewards just for showing up. Awesome.
 
  • Like
Likes dlgoff
  • #506
Today I learned how transistors work. [emoji4]
 
  • Like
Likes Silicon Waffle
  • #507
YILT I try so hard to look helpful and good! Maybe that's because I've made a bad image of myself in the past and now I'm trying to change it.:oldeyes:
 
  • Like
Likes Silicon Waffle and jim hardy
  • #508
Being kind makes us better. Where the conscious goes, the subconscious must follow.
 
  • Like
Likes CalcNerd and Silicon Waffle
  • #509
Today I learned that the speed of light is much faster than the speed of sound.
Is that why that someone looks bright until you hear him/her speaking?
 
  • Like
Likes phinds
  • #510
Origin-of-Life Story May Have Found Its Missing Link
http://news.yahoo.com/origin-life-story-may-found-missing-123319318.html

But exactly how that creature arose has long puzzled scientists. For instance, how did the chemistry of simple carbon-based molecules lead to the information storage of ribonucleic acid, or RNA? The RNA molecule must store information to code for proteins. (Proteins in biology do more than build muscle — they also regulate a host of processes in the body.)

The new research — which involves two studies, one led by Charles Carter and one led by Richard Wolfenden, both of the University of North Carolina — suggests a way for RNA to control the production of proteins by working with simple amino acids that does not require the more complex enzymes that exist today. [7 Theories on the Origin of Life on Earth]
 
  • Like
Likes mfb and Silicon Waffle
  • #511
Today I learned about glucosinolates in (white) vegetables that once their structures get "broken" they will produce isothiocyanates to cause or worsen people's goiters. :nb)
 
Last edited:
  • #512
Sir Bradley Wiggins has broken the iconic hour record by completing a distance of 54.526km (33.88 miles)
.http://www.bbc.com/sport/0/cycling/33041998

That's quite an achievement to sustain an average speed for one hour.
 
  • #514
Today I posted a tongue in cheek comment; "Sometimes, I get the feeling that NASA is stealing ideas from this thread..." in the "Ceres" thread.
It was the 4th or 5th time that NASA had published something the PF Dawn Nerd Party had previously published here.
After I pushed the submit button, I thought about that for a few seconds, and two quotes popped into my head:
"Great minds think alike"
and
"Imitation is the sincerest form of flattery".​

I googled the "flattery" quote, and found something funny:

Lacon, Or, Many Things in a Few Words: Addressed to Those who Think, Volume 1
By Charles Caleb Colton
[published "Toward the end of 1820...", per wiki]
...
CCXVII.
Imitation is the sincerest of flattery.
...

Now, it's quite well known that I'm fairly illiterate, so I'm not sure if that's ironic or not, that the quote wasn't imitated quite right.

skreeeeeech!

What's this?

Imitation is the sincerest form of flattery
...
Origin

This proverbial expression dates from the early 19th century, although versions of it that paraphrased the same thought existed well before then.

The first of these alternate versions is found in a biography of Marcus Aurelius by Jeremy Collier and André Dacier, titled Emperor Marcus Antoninus his conversation with himself, 1708:

You should consider that Imitation is the most acceptable part of Worship, and that the Gods had much rather Mankind should Resemble, than Flatter them.

A nearer stab at the current version comes in a piece by the English writer Eustace Budgell in the newspaper The Spectator No. 605, October 1714:

Imitation is a kind of artless Flattery.

Ha!
 
  • #515
TIL how to do some quick calculations in the terminal, as well as using ghostscript to extract relevant pages from a pdf.

Code:
echo "sqrt( 700234 )" | bc -l

The other one is too long, so I made an alias for the script.
Long live the command line
 
  • Like
Likes OmCheeto
  • #516
mfb said:
That sounds very interesting.
Would be a great topic for an insights article from @Ygggdrasil.

That's an interesting study (here's a link to the relevant publication http://www.ncbi.nlm.nih.gov/pubmed/26034281). Thanks for bringing the paper to my attention. I'll think about writing about it as it might go well with some other topics I'm considering. In the meantime, if you're interested in reading more about the topic, I'd suggest this review article: http://www.ncbi.nlm.nih.gov/pmc/articles/PMC3293468/
 
Last edited:
  • Like
Likes Enigman, mfb and Silicon Waffle
  • #517
chipmunks make cool pets.
 
  • #518
Today I learned that spiders ARE insects. I had always been taught that they are not, but Dave Barry explained it thusly:

"Insect" is from the Latin "in" meaning "a" and "sect" meaning "nasty little creature".

Thus spiders ARE insects, as are crabs, yippy little dogs, and Truman Capote.
 
  • Like
Likes OmCheeto
  • #520
Today I learned about the Assassin bug after seeing one for the first time ever yesterday crawling on my wife's car. It looked like the strangest spider that I had ever seen. :wideeyed:
 
  • #522
Today I realized the joys of staying quiet and not commenting on anything!:redface:
 
  • #524
Shyan said:
It seems he has a very emotional research group!
It must be the men. :wideeyed:
 
Back
Top