Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re^11: Randomly biased, random numbers.

by educated_foo (Vicar)
on Dec 08, 2013 at 01:24 UTC ( #1066169=note: print w/ replies, xml ) Need Help??

in reply to Re^10: Randomly biased, random numbers.
in thread Randomly biased, random numbers.

Your translation looks correct, so I'm a bit surprised by the result. I only tested it in 1-D, but the histogram looked plenty spiky. You could make it spikier by raising the random numbers used to generate @fx to some power, but it sounds like you found another solution.

Comment on Re^11: Randomly biased, random numbers.
Replies are listed 'Best First'.
Re^12: Randomly biased, random numbers.
by BrowserUk (Pope) on Dec 08, 2013 at 07:36 UTC
    You could make it spikier by raising the random numbers used to generate @fx to some power

    Indeed, adding a power component causes much more clumpiness, and making the power component variable:

    my @fx = @{ reduce( sub{ push @$a, $a->[-1]+$b; $a }, [ 0 ], map{ rand()**rand +(3) } 1..10 ) };

    gives a nice variability.

    But yes, I am currently much enamoured of my weight-map solution. Some of the grey-scale images it produces are just downright beautiful :)

    But thankyou for your input. The vectorising of the 3D weight-map to 1D weight-stick my solution uses. came directly from your example, and I understand a little more about matlab/octave now :)

    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1066169]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (4)
As of 2015-11-25 23:58 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (693 votes), past polls