search for: d_1d_2i

Displaying 2 results from an estimated 2 matches for "d_1d_2i".

2006 Sep 01
1
integration problem with gamma function
...; (* p_svbar *) UiA = Ni (Dsi - 2Di A + A^2)/2; UiiA = Nii (Dsii - 2Dii A + A^2)/2; psvbar = NIntegrate[1/(UiA^(Ni/2)) 1/(UiiA^(Nii/2)) Gamma[Ni/2,UiA/(sH^2),UiA/(sL^2)] Gamma[Nii/2,UiiA/(sH^2),UiiA/(sL^2)],{A,L,H}, MinRecursion->3]; PSVbar = psvbar/(4 Log[sH/sL]); Print["p(s?v|D_1D_2I) = const. ",N[PSVbar,6]]; </---> <--- translation to R ---> integpsvbar <- function(A) { # Mathematica: gamma[a,z0,z1] = gamma[a,z1] - gamma[a,z0] UiA <- Ni*(Dsi-2*Di*A+A^2)/2 UiiA <- Nii*(Dsii-2*Dii*A+A^2)/2 1/UiA^(Ni/2) * 1/UiiA^(Nii/2) * ( pgamma(UiA/(sL^2), Ni/2...
2006 Aug 07
1
mathematica -> r (gamma function + integration)
...low = lownum/(2s^2); up = upnum/(2s^2); psv = NIntegrate[1/(s^NN) Exp[-dd/(2s^2)] (Gamma[1/2,0,up] + Gamma[1/2,0,low]),{s,sL,sH}, MinRecursion->3]; PSV = psv/Sqrt[2NN]; Print["------------- Results ------------------------------------"]; Print[" "]; Print["p(sv|D_1D_2I) = const. ",N[PSV,6]]; ######## # R part library(fOptions) ###raw values for reproduction NN <- 58 dd <- 0.411769 lownum <- 20.81512 upnum <- 6.741643 sL <- 0.029 sH <- 0.092 ### integpsv <- function(s) { 1 / (s^NN) * exp(-dd / (2 * s^2)) * ( (igamma((upnum/(2*s^2))...