Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

my question is pretty much the same as the one asked here: Notation for sampling random variate (I did not find a satisfying answer there...):

I have a random variable $X \sim U(1, 10)$. I want to define a function $f : [n] \mapsto \mathbb{R}$ (or an $n$-dimensional vector if you prefer) which is supposed to evaluate for each $i \in [n]$ to one value sampled from $X$.

I am describing how I generate data for a problem, internally I am using the C++11 random generator described here: http://en.cppreference.com/w/cpp/numeric/random

I am unsure how to write this as a formula, especially if I use some more complex way of computing the function, for example flipping a coin to decide whether I choose the value for one $i$ from one distribution or another.

share|improve this question
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.