Questions tagged [simulation]

A vast area which includes generating results from computer models.

Simulation is the imitation of the operation of a real-world process or system over time. The act of simulating something first requires that a model be developed; this model represents the key characteristics or behaviors/functions of the selected physical or abstract system or process. The model represents the system itself, whereas the simulation represents the operation of the system over time

(source: Wikipedia)

For understanding when to use simulation, refer to the following question:

When to use simulations?

706 questions
2
votes
1 answer

Lotka-Volterra: is stability analysis done on both equations separately or to their sum?

Lotka-Volterra: is stability analysis done on both equations separately or to their sum? So if the systems are e.g. notated as: $$u_t=u(v-1)$$ $$v_t=v(1-u)$$ then would one do stability analysis for $u_t$ and then for $v_t$ or would one consider…
mavavilj
  • 7,270
2
votes
1 answer

Simulate multivariate normal

I understand that by Cholesky Decomposition, multivariate normal distribution $X=[X_1, ..., X_n]$~$ N(0,\Sigma)$ can be simulated as $RZ$, where $Z=[Z_1, ..., Z_n]$~$N(0,I_{n\times n})$ and $R$ is a lower triangular matrix such that $RR^T=\Sigma$.…
dh7
  • 21
2
votes
0 answers

Continuous Variables generating from Simulation by Ross Sheldon.M

These questions are exercises from chapter Generating Continuous Variables. 14.Let $G$ be a distribution function with density $g$ and suppose, for constants $a < b$, we want to generate a random variable from the distribution function…
sss1031
  • 71
1
vote
1 answer

Mean Value Function and CDF of Nonhomogeneous Poisson

Consider a nonhomogeneous Poisson process on $[0, T]$ with mean value function $m(t)$ for $t \in [0, T]$. Let $X_1$ denote the time of the first arrival. Show that $(X_1\,|\,N(T) = 1)$ has the following cdf: $$F(x) = \frac{m(x)}{m(T)},\quad x \in…
1
vote
1 answer

Simulating a probability of $\frac1e$ given a fair coin

The problem asks to simulate a probability of $1/e$ given a fair coin, and asks the expected number of tosses for each simulation. It seems to do with CLT but I don't know how to link a normal $N(np,np(1-p))$ with parameter $n$ with this quantity…
WWSS
  • 119
1
vote
1 answer

Simulation Model

How do I find the Inter-arrival time when the Inter-arrival time is described on as exponentially distributed with mean of 12 minutes? This is a single server model with a generalized service time. I have the information for the service time and its…
MEC
  • 11
1
vote
1 answer

Simulating a divide area random variable

Suppose that we have a random variable with pdf like $f = \left\{ \begin{array}{ c l } x+1, x\in [-1,0] \\ -x+1, x\in (0,1] \end{array} \right.$ and we have to simulate it. It's pdf is $F(x) = \left\{ \begin{array}{ c l } x^2/2+x+0.5, x\in…
1
vote
0 answers

Simul8 two queues with one mandatory for part of population and optional for the remaining

In Simul8, anyone know how to set up a model that has two queues A and B. 20% of the entering population must use queue B and the remaining 80% can use the one with less queue. I currently have set it up forcing 20% to use A and 80% to use B, but…
1
vote
2 answers

generate 3 random variables uniformly that correspond to a hyper plane.

I am doing simulation that I want a point םמ a sphere to be picked at random. I used spherical coordinates, to uniformly generate $\theta$ ,$\phi$, but I found it that it does not really uniformly generates the values along x,y,z. x and y histogram…
0
votes
1 answer

simulation and algorithms

A variant method of squeezed rejection algorithm for the simulation of the exponential distribution $\exp(1)$ truncated to $(0,2)$ interval can be written as: (a) generate $Y \sim U(0,2)$ , $U\sim U(0,1)$ (b) if $U \le \mathrm{e}^{-a} \times…
0
votes
1 answer

Simulation from cdf

Give a method for simulating from $$F(x) =\left\{\matrix{ \frac{(1-e^{-2x}+2x)}{3},& 0 < x < 1\cr \frac{3-e^{-2x}}{3}, & 1 < x < ∞}\right.$$ (Work out the pdf, and try to write it as a mixture, with one of the components being an $Exp(λ)$ pdf…
0
votes
0 answers

Simulate sum of correlated and uncorrelated variables with uncertainty

This is surely a simple question for many. Suppose a sum S of linked variables must be simulated: x: independent variable sampled from empirical pdf. a = f1(x); f1 is a function with uncertainty bounds, and so, a is also sampled. b = f2(a); f2 is a…
0
votes
0 answers

How can I use the Metropolis Hastings Algorithm to sample from a posterior distribution

$$p(x) \propto \exp\left(-\frac{x_1^2}{10} - \frac{x_2^2}{10} - 2(x_2 - x_1^2)^2\right),\\ p(y|x) = \mathcal{N}(y; x_2, 0.1)$$ I want to sample from the posterior arising from this likelihood and prior distribution using both the random walk…
John Smith
  • 120
  • 7
0
votes
0 answers

Inverse Transform Sampling from Discrete Uniform Distribution

I understand that in simulation, inverse transform sampling means that I first generate a uniformly distributed value $u$ and then use $F^{-1}(u)$ to get a value according to the distribution $F$. If I need a sample size of 1000, then I repeat the…
Justin
  • 67
0
votes
1 answer

Finding solution for the intersection of a line and and arbitrary-order aspheric lens surface

I apologize for any formatting mistakes, first time here. I'm currently working on program in Java as a personal project that simulates and allows for the design of a lens system with surfaces generally defined using the equations covered here…
1
2