Quantum random floats in your applications
Re: Quantum random floats in your applications
Yeah I can see them. However I had to close and reopen Chrome, F5 was not enough.
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
Re: Quantum random floats in your applications
At the moment we just have one sequence - 16MBQNums.dat. We can create a different sequence by shuffling. There exists 16MB! ( ! = factorial ) different sequences. That is a huge number. If we shuffled using a generator with a period of 2^32 then we can only produce 2^32 different sequences. There are no restrictions if we use a cryptographic generator to do the shuffling.
The following code will take 16MBQNums.dat, shuffle it and save as 16MBQNums1.dat. We can repeat outputting to 16MBQNums2.dat and so on.
The new sequences will be different to 16MBQNums.dat.
Your code could choose from as many new sequences as you create.
The following code will take 16MBQNums.dat, shuffle it and save as 16MBQNums1.dat. We can repeat outputting to 16MBQNums2.dat and so on.
The new sequences will be different to 16MBQNums.dat.
Code: Select all
#define _16MB 16777216
#include "E:\FreeBASIC\CryptoRnd\CryptoRndII.bas" ' Whatever your path is.
Sub KnuthShuffle( a() As Double )
For i As Long = 1 To _16MB - 1
Swap a(i), a( CryptoR( i, _16MB ) )
Next
End Sub
Dim Shared _Rnd( 1 to _16MB ) As Double
Open "16MBQNums.dat" For Binary As #1
Get #1, , _Rnd()
Close #1
KnuthShuffle( _Rnd() )
Open "16MBQNums1.dat" For Binary As #1
Put #1, , _Rnd()
Close #1
Print "Done"
Sleep
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
Re: Quantum random floats in your applications
I have just dumped https - it is a nightmare.
I cannot get my FTP client, FileZilla, to open my website. I tried four different protocols and four different ports.
My web builder needs the configuration changing else I will not be able to edit my website.
Apologies to Google Chrome users, but your inconvenience is much less than mine. Whilst we are on the subject you do know that Chrome reports back to mother on nearly everything you do. A guy at PowerBASIC learnt the other day that Google not only scans his GMail but also his attachments. He is not a happy sausage! Me - I use Firefox and their VPN.
I cannot get my FTP client, FileZilla, to open my website. I tried four different protocols and four different ports.
My web builder needs the configuration changing else I will not be able to edit my website.
Apologies to Google Chrome users, but your inconvenience is much less than mine. Whilst we are on the subject you do know that Chrome reports back to mother on nearly everything you do. A guy at PowerBASIC learnt the other day that Google not only scans his GMail but also his attachments. He is not a happy sausage! Me - I use Firefox and their VPN.
Re: Quantum random floats in your applications
I used Chrome but somehow it would always get corrupted so I switched to FireFox, I am happy with it, one thing I like is the facility to backup/restore bookmarks, I stay away from syncing as you never know what you will end up with
BTW, I see your smileys just fine
BTW, I see your smileys just fine
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
Re: Quantum random floats in your applications
I am back on https again.
There are some guys at the PowerBASIC forum who are extremely Internet savvy. Three guys got involved and the issue was not with https or FileZilla but with Cloudfare applying a proxy. I was shown how to disable that the result being:
and FileZilla working as it has done for many years.
However, with the two images above I had to use 'http://' and that is in the Page Source so there may still be an issue with displaying in Google Chrome. If I use 'https://', then that is found in the Page Source, but we get 'image' as a placeholder and no emoji. So, the forum software forces 'http://' and Google Chrome will probably say "Oh, I am not having that".
I will have to stay with https since "https helps protect the download from being modified by a man-in-the-middle." said one of the guys at PowerBASIC. Since I am talking about my Encrypternet application that is the last thing that I want.
There are some guys at the PowerBASIC forum who are extremely Internet savvy. Three guys got involved and the issue was not with https or FileZilla but with Cloudfare applying a proxy. I was shown how to disable that the result being:
and FileZilla working as it has done for many years.
However, with the two images above I had to use 'http://' and that is in the Page Source so there may still be an issue with displaying in Google Chrome. If I use 'https://', then that is found in the Page Source, but we get 'image' as a placeholder and no emoji. So, the forum software forces 'http://' and Google Chrome will probably say "Oh, I am not having that".
I will have to stay with https since "https helps protect the download from being modified by a man-in-the-middle." said one of the guys at PowerBASIC. Since I am talking about my Encrypternet application that is the last thing that I want.
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
Re: Quantum random floats in your applications
Remember the Win98 days? Any issues were often solved by Restarting the system, so I did.
The forum software will now accept https.
So, what was the real problem? Closing something did the trick but what I have no idea.
Flaming heck.
@SARG
Can you see the images in my last two posts? The reason I ask is that all three have an image location using https but the first two use http in the Page Source and the last one uses https in the Page Source which tells me that the forum software is getting its knickers in a twist.
The forum software will now accept https.
So, what was the real problem? Closing something did the trick but what I have no idea.
Flaming heck.
@SARG
Can you see the images in my last two posts? The reason I ask is that all three have an image location using https but the first two use http in the Page Source and the last one uses https in the Page Source which tells me that the forum software is getting its knickers in a twist.
Re: Quantum random floats in your applications
I can see the 3 images (2 smileys and the 'deltarho.org..') without any problem on my PC and smartphone, both using Chrome.deltarho[1859] wrote:@SARG
Can you see the images in my last two posts? The reason I ask is that all three have an image location using https but the first two use http in the Page Source and the last one uses https in the Page Source which tells me that the forum software is getting its knickers in a twist.
-
- Posts: 4310
- Joined: Jan 02, 2017 0:34
- Location: UK
- Contact:
Re: Quantum random floats in your applications
That is great news. Thanks for letting me know, SARG.SARG wrote:I can see the 3 images (2 smileys and the 'deltarho.org..') without any problem on my PC and smartphone, both using Chrome.