Getting old

For other topics related to the FreeBASIC project or its community.
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 02, 2020 21:47

@marcov

I have seen that list and others as well. Like most people I have had my 'ups and downs' and during my downs resorted to writing quips. I knocked out quite a few over the years and eventually put them altogether on my Atari computer in the eighties and added to the list as time went on. I made a hard copy once but it got lost on a house move.

A lot of them were quite disgraceful and do not reflect my attitude to life in my dotage. One such was: "The scriptures are incorrect. God created woman first but got it right on the second try." I would, of course, get strung up for saying that today.

Some were what I called 'double quips' were a second quip reversed the first quip and also made sense. For example:

"If you take yourself seriously then you may find that no one else does."
"If you do not take yourself seriously then you may find that every one else does."

Although intended as 'tongue in cheek' remarks I have come across examples where both were true.

I tried to model the quips on Wilde because I found his quips suited my sense of humour.

"If you cannot improve on mediocrity then do it with style."

There are many successful people, such as on television, who have style but when we remove the style we often find mediocrity.

Anyway, I won't ramble on - this thread is about 'Getting old'.

Except to mention Bernard Shaw who is another favourite of mine. On his deathbed he remarked: "I knew if I lived long enough something like this would happen."
Provoni
Posts: 391
Joined: Jan 05, 2014 12:33
Location: Belgium

Re: Getting old

Postby Provoni » Jul 03, 2020 14:28

deltarho[1859] wrote:I am going to leave my body to medical science but I can imagine a conversation like: "His brain is in good shape but as for the rest of him I think the furnace beckons, don't you?". His colleague may remark: "I am inclined to agree - let's have his brain out".

Perhaps it is better to leave this world with a failing body than with a failing mind. That said, I hope that you may engage in a active and healthy lifestyle. Your passion with random number generators is astounding! And it is certainly a topic that also interests me.

fxm wrote:I am 69 years old and I do not feel at all old. It is true that I am lucky to be in good health and good physical condition.

Happy to hear!
grindstone
Posts: 755
Joined: May 05, 2015 5:35
Location: Germany

Re: Getting old

Postby grindstone » Jul 03, 2020 19:50

Thank you, guys. You make me feel young again (2^6-2^2) ;-)

Just for curiosity: Does anybody know what programming language(s) today's coding - juniors use? Do they code at all? Or do they content theirselfes with slandering at the social media?
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 03, 2020 21:02

Provoni wrote:Your passion with random number generators

It is not a passion with random number generators, per se, but a passion with random numbers. What interests me with generators is how authors go about minimizing the correlation between the latest number generated and its predecessor. With Sebastion Vigna's generators not enough work is done, and they fail PractRand at 64GB. It is a question of balance - more work will gets us past 64GB but that will slow down the generator's throughput. 32GB or less will not see PractRand complain and 32GB will give us 8 Gigs of floats - and that is many floats. It seems to me that once we get past a certain speed applications do not benefit from a faster speed. Highlighting speed as a selling point is more to do with a public relations exercise, in my opinion. Vigna's generators go straight into bit shifting. Melissa O'Neill's PCG32 uses Donald Knuth's 64-bit LCG, which is very fast, as a starting point to get us into a 'neighbourhood' of a random number. Bit shifting is then employed; but not that much. The result is a fast generator and a PractRand success to 16TB. We could speed up PCG32 with less bit shifting but at the expense of randomness and as intimated above the holy grail should be randomness and not speed. Bernard Widynski's is an interesting generator. It is non-linear so should be slower but it employs very little bit shifting resulting in a fast generator which also gets to 16TB with PractRand.

PractRand is good at spotting generators which do not pass muster from a randomness point of view but tells us that O'Neill's PCG32 and Widynski's MsWs are equally good. Perhaps they are but is it that we have reached the limitation of PractRand?

I am now looking at warming up generators. Vigna has done some work on this and found that some generators need a longer warm up period than others. A warm up may be needed, by discarding the early numbers generated, to eliminate any unusual bias in the '0'/'1' distribution. PractRand, unless told otherwise, examines 512KB, 1MB, 2MB and so on. Any bias in the very early stages will get overlooked. PCG32 passes PractRand to 16TB but what is it like in the early stages? We can force PractRand to start at 1KB, 2KB, 4KB and so on. To my horror PCG32 had unusual anomalies at 1KB, 2KB and 8KB; thereafter we would see very few to 16TB. Vigna talks about warming up in the hundreds. Perhaps we should be talking about thousands. 8KB of PCG32 will only cost, on my machine, about 11 microseconds. At the moment I am discarding 200 as a warm up.

Mersenne Twister(MT) fails PractRand at 256GB. 128GB will give 32 Gigs of floats. So, nobody should get the sack for using MT for, say, a few million floats unless MT is not fast enough; it isn't that fast. However, what are the early numbers like? I don't know. Forum members tend to use MT for a few hundred numbers but do not warm up MT. From what I have read MT needs a very long warm up period before it settles down. It could be that the early numbers of MT are very poor; perhaps into the high thousands. I'll do some work on this and may start a thread on 'warming up' generators.
Provoni
Posts: 391
Joined: Jan 05, 2014 12:33
Location: Belgium

Re: Getting old

Postby Provoni » Jul 04, 2020 6:15

I am trying to think about what random numbers are. What is the opposite of random numbers? I would like to say sequential numbers but not sure. "1234567..." And how is randomness measured? It seems so simple to measure sequential numbers (+1) but up to infinitively hard to measure random numbers?

I feel that there is a intrinsic complexity to random numbers. If that is true then perhaps random numbers are never really random? Because there is always some underlying generator, at the very least, the possible deterministic physics of our universe.

A funny thing with opposites is that they often have common properties, for example, both a sequential number generator and a good random number generator will be able to generate every number between 1 and a googol.

I feel that random numbers are in a way deeply connected to our universe and beings.
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 04, 2020 10:13

Provoni wrote:What is the opposite of random numbers?

Chaos theory. Randomness is deterministic. Take RND for example. If we calculate the average it will tend to 0.5 as we increase the number of samples. Well, not quite 0.5 as RND is within [0,1). It doesn't matter what the starting position is, the seed, we still tend to 0.5. Chaos is not deterministic. A slight perturbation in the starting position will see a very different pattern emerge. Weather systems are chaotic. However, a chaotic system is predictable for a short while. Predicting the weather in a few a days time can be fairly accurate but looking a month ahead would be impossible even for a super computer. With random numbers we have the opposite. With a true random number it is anyone's guess what the next random number will be.
And how is randomness measured?

We examine the sequence to see if the present value could have been predicted from past values. Serial correlation is one method. George Marsaglia's Die Hard used quite a few methods but PractRand uses many more.
perhaps random numbers are never really random?

Theoretically PRNGs cannot be since they are mechanistic. PractRand cannot prove randomness. PractRand assumes the null hypothesis that the numbers given it are random and then tries to find a contradiction. A successful PractRand to 16TB is not telling us the data is random - it is telling us that it cannot find any evidence that it isn't. CPRNGs are not mechanistic so it should not be possible, in theory, for a present value to have been predicted from past values. However, CPRNGs do not generate true random numbers. Microsoft's CPRNG uses an entropy pool which gets flushed regularly but the entropy pool, whilst being large, is not infinite. CPRNGs tend to be much slower than PRNGs and why I developed CryptoRndII using buffers and defaults to using BCryptGenRandom. The next step up is something like Intel's RdRand which examines thermal noise and then subjects it to conditioning via cryptographic functions. We can force CryptoRndII to use RdRand rather than BCryptGenRandom.

It is worth remembering that with long sequences of random numbers there will be sub-sequences of poor randomness. If this was not possible then we would not be looking at random numbers. We do get the occasional anomaly, all be they small, with quantum random numbers. An analogy would be to find ourselves in the tails of a normal distribution, but we shouldn't find ourselves there that often and when we are we shouldn't be there that long. Of course, being random we cannot tell, a priori, when we happen to be in a sub-sequence of poor randomness. With scientific use of random numbers we wouldn't restrict ourselves to just 'one run' no more than with timing code where we would examine several 'runs'.
badidea
Posts: 2152
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Getting old

Postby badidea » Jul 04, 2020 11:37

Provoni wrote:I feel that there is a intrinsic complexity to random numbers. If that is true then perhaps random numbers are never really random? Because there is always some underlying generator, at the very least, the possible deterministic physics of our universe.

If you know the full state of the universe, location and speed of every existing particle, then there are probably no random numbers. The digital nature of computers makes it impossible for them to come up with a random number. They can generate sequences the seem random and use the outside world via sound input, mouse input, the internet to improve the randomness. Also interesting, how good are people at generating random numbers?

edit: typo
Last edited by badidea on Jul 04, 2020 17:25, edited 1 time in total.
dodicat
Posts: 6726
Joined: Jan 10, 2006 20:30
Location: Scotland

Re: Getting old

Postby dodicat » Jul 04, 2020 12:57

Numbers and random numbers are an invention of the human brain alone.
We use numbers so we can live comfortable and organised lives.
No other species, as far as we know, need a number system.
The universe is a complete mystery to us.
We explore it only by actually going to places in it (The moon so far), and for that we also need numbers.
But there are so many lies told about these places, that any individual human being taken at any instance will, in this modern age, have no more clue about these places than 500 years ago people.
Anyway contemplating the universe is now not important for humanity, we need to repair the damage we have done to Earth in these last few decades.
Maybe only an older person can understand the extent of the damage, also, most of it was done in their lifetime.
IMHO

So actually fxm, what we thought was a gruelling workout in the mountains is actually, when stretched out over six weeks, a gentle afternoon stroll each day.
Never mind, I hope you enjoy your time out of the city.
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 04, 2020 14:33

badidea wrote:It you know the full state of the universe, location and speed of every existing particle, then there are probably no random numbers.

I think that may be true of the relativistic universe but not of the quantum universe.
dodicat wrote:Maybe only an older person can understand the extent of the damage, also, most of it was done in their lifetime.

"Ignorantia juris non excusat", latin for "ignorance of the law excuses not". That also goes for the natural law. The damage to the earth was done out of ignorance, we know better now but it is no excuse, and we must pay the penalty. We can reduce the penalty with good behaviour. Getting people to stop behaving badly is proving difficult. I supposed that most people would know that dropping litter is bad. This last few weekends in the UK, in the parks and at the beaches, with lockdown easing makes me question that supposition. Of course, the supposition may be correct in which case we have people not caring. If that is true then we are doomed and banging on about climate change will simply go in one ear and out of the other. On balance, I think that we are probably doomed. Image

On reflection 'getting old' may not be a bad thing - when we start to sink into the quick sand I may be well out of it and will miss the end of the film.
badidea
Posts: 2152
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Getting old

Postby badidea » Jul 04, 2020 17:52

deltarho[1859] wrote:...The damage to the earth was done out of ignorance, we know better now but it is no excuse, and we must pay the penalty. We can reduce the penalty with good behaviour. Getting people to stop behaving badly is proving difficult. I supposed that most people would know that dropping litter is bad...

It is again a 'numbers' problem, and I don't see how we (humans) are going to solve it. Look at the numbers of primates (including us). Or the number of even-toed ungulates; the wild ones versus the domesticated ones. Same for the number of carnivorans and somewhat less the number of odd-toed ungulates. Our best hope is that some deity or alien race will apply some correction. This virus is not going to make a big difference.
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 04, 2020 18:13

badidea wrote:Our best hope is that some deity or alien race will apply some correction.

What are you on and where can I get some?

On second thoughts .....
badidea
Posts: 2152
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Getting old

Postby badidea » Jul 04, 2020 18:36

deltarho[1859] wrote:What are you on and where can I get some?

Thanos with Infinity Gems? From the movies I understood that those gems are hard to find.

Else, with the current numbers, we need to make some very big changes. Kill the system which requires us to consume more every year. E.g. start producing and buying clothes the lasts 10 years instead of 10 weeks. Stop flying around the globe for no good reason. Stop driving cars to get to work (move to work to the persons). Remove 90% of roads and fences. Stop eating animals (maybe with the exception on domestic cats and dogs). Etc.
jj2007
Posts: 1726
Joined: Oct 23, 2016 15:28
Location: Roma, Italia
Contact:

Re: Getting old

Postby jj2007 » Jul 04, 2020 19:14

badidea wrote:Stop eating animals (maybe with the exception on domestic cats and dogs). Etc.
So you will continue to eat dogs and cats?
deltarho[1859]
Posts: 2698
Joined: Jan 02, 2017 0:34
Location: UK

Re: Getting old

Postby deltarho[1859] » Jul 04, 2020 19:43

jj2007 wrote:So you will continue to eat dogs and cats?

He probably will if he still has some Infinity Gems left. He will run out which will be a blessing for cats and dogs and the rest of us I shouldn't wonder. I have no objection to an alien race correcting us but the thought of some deity getting involved made me shudder. Image
badidea
Posts: 2152
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Getting old

Postby badidea » Jul 04, 2020 21:02

deltarho[1859] wrote:I have no objection to an alien race correcting us but the thought of some deity getting involved made me shudder.

How would we know the the difference?

jj2007 wrote:
badidea wrote:Stop eating animals (maybe with the exception on domestic cats and dogs). Etc.
So you will continue to eat dogs and cats?

For a while, to reduce the amount. Just cleaned my charcoal barbecue.

Return to “Community Discussion”

Who is online

Users browsing this forum: No registered users and 11 guests