Searching \ for 'Pseudo Random Number Generator (One Bit) Needed' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/method/math.htm?key=random
Search entire site for: 'Pseudo Random Number Generator (One Bit) Needed'.

Truncated match.
PICList Thread
'Pseudo Random Number Generator (One Bit) Needed'
1997\09\28@170707 by jdolson

picon face
Does anyone have an idea for a pseudo random number generator?  One
pseudo random bit is plenty.

Jim Dolson
spam_OUTjdolsonTakeThisOuTspamiserv.net

1997\09\28@181216 by Eric Smith

flavicon
face
Jim Dolson <.....jdolsonKILLspamspam@spam@ISERV.NET> wrote:
> One pseudo random bit is plenty.

Okay, I've pseudo-randomly picked '0'.

Sorry, couldn't resist.
Eric

1997\09\29@041002 by Andrew Warren

face
flavicon
face
Jim Dolson <jdolsonspamKILLspamiserv.net> wrote:

> Does anyone have an idea for a pseudo random number generator?  One
> pseudo random bit is plenty.

Jim:

See the answer to Question #75, in the "Microchip PIC" area of the
"Answers" section on my company's web page.

-Andy

=== Andrew Warren - .....fastfwdKILLspamspam.....ix.netcom.com
=== Fast Forward Engineering - Vista, California
=== http://www.geocities.com/SiliconValley/2499

1997\09\29@132043 by Eric van Es

flavicon
face
Eric Smith wrote:

> Jim Dolson <EraseMEjdolsonspam_OUTspamTakeThisOuTISERV.NET> wrote:
> > One pseudo random bit is plenty.
>
> Okay, I've pseudo-randomly picked '0'.
>
> Sorry, couldn't resist.
> Eric

Then I'll pick '1'.

I could not resist either <G>
Eric
--
Eric van Es               | Cape Town, South Africa
vanesspamspam_OUTilink.nis.za | http://www.nis.za/~vanes
LOOKING FOR TEMPORARY / HOLIDAY ACCOMODATION?
http://www.nis.za/~vanes/accom.htm

1997\09\30@002247 by Martin McCormick

flavicon
face
In message <@spam@342F697E.7D2F45DBKILLspamspamilink.nis.za>, Eric van Es writes:
>Eric Smith wrote:
>
>> Jim Dolson <KILLspamjdolsonKILLspamspamISERV.NET> wrote:
>> > One pseudo random bit is plenty.
>>
>> Okay, I've pseudo-randomly picked '0'.
>>
>> Sorry, couldn't resist.
>> Eric
>
>Then I'll pick '1'.
>
>I could not resist either <G>

       That's the trouble.  You need resistance and then things get really
random.  Actually, in all seriousness, there has been much discussion about
random number generators in the list and everything that anybody has said
about a 8-bit generator applies to a 1-bit one.  You can use a noise source
such as a Zenar diode and amplify the noise, if necessary so your one bit
flickers on and off with the noise.  If you have key strokes or some other
asynchronous events, you can and them with the clock and latch the results
each time to get a bit that is sometimes on and sometimes off.

       Some others suggested a shift register with feedback so you can
do just about anything that gives you a bit that isn't on all the time.

       A cold solder joint is a good low-frequency random number generator.
I hope there is one in the system that spams the PIC list from time to time.

Martin McCormick WB5AGZ  Stillwater, OK 36.7N97.4W
OSU Center for Computing and Information Services Data Communications Group


'Pseudo Random Number Generator (One Bit) Needed'
1997\10\01@150436 by Andrew G Williams
picon face
Martin McCormick wrote:

>Actually, in all seriousness, there has been much discussion about
>random number generators in the list and everything that anybody has said
>about a 8-bit generator applies to a 1-bit one.

Must be careful here though, as generators designed to produce >1 bit results
won't necessarily give good performance when only a single bit is used. As an
example, I wrote a 16-bit generator recommended by Texas Instruments for use
in their TMS320C5x DSPs, and tested the results (1 million samples) with the
Hotbits test program. Results were quite good on most tests, indicating an
effective random sequence.

I then produced another file of 1 million 16-bit values, each integer
produced by generating 16 random numbers and combining the bit 0 values
together. This gave a file consisting only of the first bit generated by the
algorithm. This file underwent the same tests, and results were hopeless. All
values were the same, due to bit 0 cycling through a repeating sequence.

The same was true of other bit positions, but with different sequences being
produced. An algorithm like this is fine for 16-bit numbers, but can't be
used for single bits. Having said that, I performed the same tests using the
random() function in Borland C++, and a bit 0 file gave good random results.
Still different from a test on the 'raw' data, though.

>You can use a noise source
>such as a Zenar diode and amplify the noise, if necessary so your one bit
>flickers on and off with the noise.

Yes, but he did specify a pseudo-random generator. Perhaps he needs to repeat
the sequence.

Andy.

1997\10\01@164923 by Roger Books

flavicon
face
> Martin McCormick wrote:
>
> >Actually, in all seriousness, there has been much discussion about
> >random number generators in the list and everything that anybody has said
> >about a 8-bit generator applies to a 1-bit one.
>
> Must be careful here though, as generators designed to produce >1 bit
> results won't necessarily give good performance when only a single bit is
> used. As an example, I wrote a 16-bit generator recommended by Texas
> Instruments for use in their TMS320C5x DSPs, and tested the results (1
> million samples) with the Hotbits test program. Results were quite good on
> most tests, indicating an effective random sequence.

Well, I'm a bit out of my area, but from reading sci.crypt if single bits
don't pass the tests for randomness than the PR generator is not really
acceptable for crypto work.  Of course you don't worry about perfection,
you worry about perfect enough for the task at hand.  If you need real
random number generators a PIC and a reverse biased diode are up to the
task, or so I have been told.  My electronics theory isn't up to the
level of random variations in leakage current.

Roger

1997\10\10@201559 by .EDU>

flavicon
face
> example, I wrote a 16-bit generator recommended by Texas Instruments for use
> in their TMS320C5x DSPs, and tested the results (1 million samples) with the
> Hotbits test program. Results were quite good on most tests, indicating an
> effective random sequence.

Andy -

What is the ``Hotbits'' test program?

--poko


Peter F. Klammer, Racom Systems Inc.                   RemoveMEPKlammerTakeThisOuTspamACM.Org
6080 Greenwood Plaza Boulevard                            (303)773-7411
Englewood, CO  80111                                  FAX:(303)771-4708

1997\10\12@072629 by Andrew G Williams

picon face
>Andy -
>
>What is the ``Hotbits'' test program?
>
>--poko


Hi poko. You'll find the Hotbits test program at:

http://www.fourmilab.ch/hotbits/.

It describes itself as "A Pseudorandom Number Sequence Test Program" which:
"applies  various tests to pseudorandom sequences of  bytes  stored  in
files  and  reports  the results  of  those  tests.  The program is useful
for those evaluating pseudorandom number generators for encryption and
statistical sampling applications, compression algorithms, and other
applications where the information density of a file is of interest."

The tests applied include chi square distribution, arithmetic mean, Monte
Carlo test, and others. It's useful for a quick test of a random
distribution, and can work on any file size.

A more sophisticated testing program is 'Diehard' available from:

http://stat.fsu.edu/pub/diehard/diehard.zip.

This gives far more detailed information from 15 tests, but takes longer to
generate and results can be difficult to analyse. Also, it expects a file
size of at least 10 megabytes. One neat feature is a large collection of
random number generators (including user-defined ones) which can create
suitable files for testing.

Andy.

More... (looser matching)
- Last day of these posts
- In 1997 , 1998 only
- Today
- New search...