www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - Berlin D Meetup Feb 2015

reply "Ben" <benpnz gmail.com> writes:
Hi All,

The next Berlin D Meetup will be happening on Friday the 20th of 
February at 19:30. The venue will be Berlin Co-Op 
(http://co-up.de/) on the 3rd floor who have the equipment for us 
to do presentations. Speaking of presentations, big thanks to 
Joseph Wakeling who will be doing a presentation on "Random 
number generation in Phobos and beyond". After the presentation 
we will have time for questions/discussions/drinks.

We also have a meetup page here: 
http://www.meetup.com/Berlin-D-Programmers/

Thanks,
Ben.
Feb 05 2015
parent reply "Joseph Rushton Wakeling" <joseph.wakeling webdrake.net> writes:
On Thursday, 5 February 2015 at 11:14:28 UTC, Ben wrote:
 The next Berlin D Meetup will be happening on Friday the 20th 
 of February at 19:30. The venue will be Berlin Co-Op 
 (http://co-up.de/) on the 3rd floor who have the equipment for 
 us to do presentations. Speaking of presentations, big thanks 
 to Joseph Wakeling who will be doing a presentation on "Random 
 number generation in Phobos and beyond". After the presentation 
 we will have time for questions/discussions/drinks.
Oh boy, what have I let myself in for :-)
Feb 07 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 2/7/2015 1:45 PM, Joseph Rushton Wakeling wrote:
 On Thursday, 5 February 2015 at 11:14:28 UTC, Ben wrote:
 The next Berlin D Meetup will be happening on Friday the 20th of February at
 19:30. The venue will be Berlin Co-Op (http://co-up.de/) on the 3rd floor who
 have the equipment for us to do presentations. Speaking of presentations, big
 thanks to Joseph Wakeling who will be doing a presentation on "Random number
 generation in Phobos and beyond". After the presentation we will have time for
 questions/discussions/drinks.
Oh boy, what have I let myself in for :-)
I see you're doing the presentation! I note that you haven't submitted a presentation proposal for Dconf 2015 yet. Please submit this one! Why not get the most mileage out of it?
Feb 11 2015
next sibling parent "Ben Palmer" <benpnz gmail.com> writes:
Just a reminder that this is happening tonight at 19:30. For 
those coming from further away the closest U-Bahn is Kottbusser 
Tor on the U1 and U8. The directions for getting to the room 
(from the http://co-up.de/ website) are:

Go through the big metal gate to the left of Adalbertstr. 7, 
straight to the far end of the courtyard, and in the first tunnel 
to your right. Ring the bell marked "co.up 3.OG" and come up to 
the 3rd floor.

If you are attending an evening/weekend meetup, you may find the 
big gate closed. In that case, go back in the direction of 
Kottbusser Tor to the small gate at Adalbertstr. 5-6. Reach 
through the bars to turn the handle and make your way straight 
through the tunnel, left through a second tunnel and then 
straight past the bike rack until you see the door of our 
building, across from the mailboxes.

Looking forward to seeing everyone and to Joseph's talk.
Feb 20 2015
prev sibling parent reply "Joseph Rushton Wakeling" <joseph.wakeling webdrake.net> writes:
On Thursday, 12 February 2015 at 01:58:04 UTC, Walter Bright 
wrote:
 I see you're doing the presentation!

 I note that you haven't submitted a presentation proposal for 
 Dconf 2015 yet. Please submit this one! Why not get the most 
 mileage out of it?
Submitted :-)
Feb 27 2015
parent reply "Ben Palmer" <benpnz gmail.com> writes:
I thought I would give a brief summary of the last meetup. Joseph 
Wakeling gave a presentation entitled “Random number generation 
in Phobos and beyond”. It was a great talk and we had some 
interesting discussions afterwards.

The talk began by mentioning some naive ways of generating random 
numbers and some of the negative consequences this can cause. 
Joseph then mentioned other methods of generating random numbers 
including big tables of random numbers, physical randomness, and 
deterministic methods (pseudo-random).

Pseudo-random number generators (RNGs) use a state variable and a 
transition function that maps from the current state to the next 
state and this sounds like a good match for a forward range. 
Currently in Phobos all RNGs are implemented as ForwardRange 
structs. Other ranges such as randomCover and randomSample wrap 
the Phobos RNGs.

Wrapping the RNGs can cause problems as structs are passed by 
value. This means that if the same RNG is used in subsequent 
calls to say randomCover then the same sequence of random numbers 
will be produced by each range.

A simple solution to this would be make random ranges classes. 
This can also cause problems but with memory management (we want 
to avoid lots of small alloc and free events). It also does not 
address problems with functions that make bad assumptions about 
their arguments.

If we can solve these problems then there are several different 
avenues to push forward with new RNG wrapper functionality. There 
are also other opportunities for looking at random number 
generation.

After the talk there was some discussion on a number of points 
including:

Testing RNGs. The unittests in std.random don't (and can't) 
provide tests of randomness. There are existing RNG tests in 
linux. It would be good to get a good randomness test suite in D.

Does the c++ standard library have the same problems? Possibly, 
there was some certainty that the boost documentation has some 
reference to the same problems.

Is this a general problem with forward ranges? Could there be 
something missing from the range interface or perhaps it would be 
better to have a distinct range type for random numbers.

There was then a discussion of the various types of hardware 
RNGs. Martin Novak mentioned “haveged” a C program that can 
generate large numbers of random numbers. It generates randomness 
based on variations in code execution time on a processor.

Thanks,
Ben.
Feb 27 2015
parent Martin Nowak <code+news.digitalmars dawg.eu> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 02/27/2015 03:04 PM, Ben Palmer wrote:
 Wrapping the RNGs can cause problems as structs are passed by
 value. This means that if the same RNG is used in subsequent calls
 to say randomCover then the same sequence of random numbers will be
 produced by each range.
 
 A simple solution to this would be make random ranges classes. This
 can also cause problems but with memory management (we want to
 avoid lots of small alloc and free events). It also does not
 address problems with functions that make bad assumptions about
 their arguments.
 
 If we can solve these problems then there are several different
 avenues to push forward with new RNG wrapper functionality. There
 are also other opportunities for looking at random number
 generation.
I actually had an idea how to solve this. https://issues.dlang.org/show_bug.cgi?id=7067#c19 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJU8i+vAAoJELJzgRYSuxk5u/8P/3znsvHfZ3+hiG4MfLUakBfA PASqYeesud4EBOYf7ztgYqCNziSZ5Zd4/fe9PyzgC1TMRzVfseckhpU9WNaVvtMd Ej5SnY6ylGma3lr9Bfl2EZWU6NgLvwgB/ZIYlJb6WjLyGaQy03niIcOlqEg4rHo/ vLr7qcCqBGGgUB3K+riQRP9ZDrub2JF5F2yad+fZB+bAObgqujENqLd+YiVNvW8p VeuDOacnb7S+tAakIUXOLJ8+peMEgtkhIKiRUjsXR7Q/QjwNLNMwBdTnrPKlyCNH Vt5f8vtzHRadFypHWvYvinNW4d2Eg62IZjYutzLia1AsHfrnCpt5l476gwaQnUa9 Zti22d0m8usKFR/MqUbhZ3c7xqBVcS9ib9JpnGVxnzWmI4zp7/PP8363IEZb84Yg U15vynIpIxMXsL2c8/qTGhL6wYSRX6+7sP+a+ZoBughAGAqSVmfbLhrAzJYg5SMq jEvB49jaWVS8VH/KS/OBHLedUoTad7BpFeMJk+GiGcd3vdhQJPsIv1ji7fCBQtBU 8hFjJsb/GYmihrfa8ds018DhmvV4OgOW1+a8xzYs3oKOQ5cq251U1oq+oh4lKoWO DMjUiPoa0zAMvrFRBirGs3tBO0361/et/hCwxLrKhhoR1mVTdm5kHEIv16SIjQiF W1meFORZw8QGBkvwz5Lm =OjGb -----END PGP SIGNATURE-----
Feb 28 2015