# Tag Info

4

EDIT It seems to work now. The key is to use the TruncatedDistribution so $h \cot(x)$ is monotonic. transF=TransformedDistribution[h Cot[x], x\[Distributed]TruncatedDistribution[{0,π/2},NormalDistribution[μ,σ]], Assumptions->μ∈Reals&&σ>0&&h>0]; FullSimplify[PDF[transF,y],{y>0,h>0,μ∈Reals,σ>0}] gives (E^(-((μ + 2 ArcTan[(...

3

Amplifying on answer by @bRost03 distX = TruncatedDistribution[{0, Pi/2}, NormalDistribution[μ, σ]]; distY = TransformedDistribution[h/Tan[x], x \[Distributed] distX, Assumptions -> h > 0]; g = Assuming[{y > 0, h > 0, σ > 0, μ ∈ Reals}, PDF[distY, y] // FullSimplify] (* (E^(-((μ + 2 ArcTan[(y - Sqrt[h^2 + y^2])/h])^2/( 2 σ^2))) h ...

3

Couldn't you model this as a DiscreteMarkovProcess? (* states are start(1), stage1(2), stage2(3), stage3(4), missing(5) *) proc = DiscreteMarkovProcess[{1, 0, 0, 0, 0}, {{0, 0.253, 0, 0, 0.747}, {0, 0, 0.507, 0, 0.493}, {0, 0, 0, 0.705, 0.295}, {0, 0, 0, 1, 0}, {0, 0, 0, 0, 1} }]; Graph[proc] PDF[StationaryDistribution[proc], 4] (* 0....

2

It works if you boost the Working precision. h[x_] := (x*CDF[NormalDistribution[0, 1], x]* Log[CDF[NormalDistribution[0, 1], x]])/ PDF[NormalDistribution[0, 1], x]; Then Plot[h[x], {x, -5, 14}, WorkingPrecision -> 80] Note that for a WorkingPrecision -> 40 one gets a smooth output with a sharp discontinuity near 13.5 which is somewhat ...

2

This method generalises easily to larger sums: k = 2; vec = Array[x, k]; dist = EmpiricalDistribution[{2/9, 5/9, 2/9} -> {-1, 0, 1}]; pdf = PDF @ TransformedDistribution[ Total[vec], vec \[Distributed] ProductDistribution[ {dist, k} ] ] DiscretePlot[pdf[n], {n, -10, 10}, PlotRange -> All]

1

Two random variables, x and y, each with the same distribution: dist = EmpiricalDistribution[{2/9, 5/9, 2/9} -> {-1, 0, 1}]; ya[t_] := PDF[TransformedDistribution[x + y, {x \[Distributed] dist, y [Distributed] dist}], t]; ya /@ Range[-10, 10] (*Output:{0,0,0,0,0,0,0,0,4/81,20/81,11/27,20/81,4/81,0,0,0,0,0,0,0,0}*)

Only top voted, non community-wiki answers of a minimum length are eligible