diff --git a/mcstas-comps/contrib/MCViNE_Broadened_E_Q.comp b/mcstas-comps/contrib/MCViNE_Broadened_E_Q.comp new file mode 100644 index 0000000000..f6007576b8 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Broadened_E_Q.comp @@ -0,0 +1,149 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Broadened_E_Q +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE Broadened_E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/Broadened_E_Q_Kernel.icc) +* +* Isotropic dispersion E(Q) broadened by a Gaussian of Q-dependent width. +* +* %D +* S(Q,E) = S(Q) G(E - E(Q); sigma(Q)) with G a normalised Gaussian of standard +* deviation sigma(Q). +* Q is sampled uniformly in [Qmin,Qmax]; the energy offset is sampled from the +* line shape (up to 100 attempts). Neutrons with Ei below min(E(Q)-3w(Q)) do not +* scatter. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_Broadened_E_Q(E_Q="20*sin(Q*1.5)^2", S_Q="1", sigma_Q="0.5", Qmin=0, Qmax=10, scattering_coefficient=10, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression [meV], variable Q [AA^-1] +* S_Q: [str] S(Q) expression +* sigma_Q: [str] Gaussian sigma(Q) [meV] +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (retries without acceptance correction: over-weights when part of the Q range is forbidden). 1: single attempt, unbiased +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Broadened_E_Q + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", string sigma_Q="1", Qmin=0, Qmax=10, int unbiased=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Broadened_E_Q kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_W_Q, sigma_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_lorentzian = 0; + kernel.m_unbiased = unbiased; + mcvine_Broadened_E_Q_init (&kernel); + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Broadened_E_Q, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Broadened_E_Q_process.comp b/mcstas-comps/contrib/MCViNE_Broadened_E_Q_process.comp new file mode 100644 index 0000000000..ed45de3d9a --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Broadened_E_Q_process.comp @@ -0,0 +1,131 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Broadened_E_Q_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE Broadened_E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/Broadened_E_Q_Kernel.icc) +* +* Union process: Isotropic dispersion E(Q) broadened by a Gaussian of Q-dependent width. +* +* %D +* S(Q,E) = S(Q) G(E - E(Q); sigma(Q)) with G a normalised Gaussian of standard +* deviation sigma(Q). +* Q is sampled uniformly in [Qmin,Qmax]; the energy offset is sampled from the +* line shape (up to 100 attempts). Neutrons with Ei below min(E(Q)-3w(Q)) do not +* scatter. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_Broadened_E_Q (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_Broadened_E_Q_process(E_Q="20*sin(Q*1.5)^2", S_Q="1", sigma_Q="0.5", Qmin=0, Qmax=10, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression [meV], variable Q [AA^-1] +* S_Q: [str] S(Q) expression +* sigma_Q: [str] Gaussian sigma(Q) [meV] +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (retries without acceptance correction: over-weights when part of the Q range is forbidden). 1: single attempt, unbiased +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Broadened_E_Q_process + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", string sigma_Q="1", Qmin=0, Qmax=10, int unbiased=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_Broadened_E_Q_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Broadened_E_Q kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_W_Q, sigma_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_lorentzian = 0; + kernel.m_unbiased = unbiased; + mcvine_Broadened_E_Q_init (&kernel); + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Broadened_E_Q; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer.comp b/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer.comp new file mode 100644 index 0000000000..01b5f0d52e --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer.comp @@ -0,0 +1,120 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantEnergyTransfer +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantEnergyTransferKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantEnergyTransferKernel.cc) +* +* Isotropic scatterer with a fixed energy transfer. +* +* %D +* Every scattered neutron loses exactly the energy E (E<0: gains) and leaves in a +* uniformly random direction over 4pi. Useful for testing and resolution studies. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_ConstantEnergyTransfer(E=10, scattering_coefficient=10, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* E: [meV] Energy transfer Ei-Ef +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantEnergyTransfer + +SETTING PARAMETERS (E=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_ConstantEnergyTransfer kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_E = E; + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_ConstantEnergyTransfer, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer_process.comp b/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer_process.comp new file mode 100644 index 0000000000..c32fb76a23 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantEnergyTransfer_process.comp @@ -0,0 +1,102 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantEnergyTransfer_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantEnergyTransferKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantEnergyTransferKernel.cc) +* +* Union process: Isotropic scatterer with a fixed energy transfer. +* +* %D +* Every scattered neutron loses exactly the energy E (E<0: gains) and leaves in a +* uniformly random direction over 4pi. Useful for testing and resolution studies. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_ConstantEnergyTransfer (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_ConstantEnergyTransfer_process(E=10, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* E: [meV] Energy transfer Ei-Ef +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantEnergyTransfer_process + +SETTING PARAMETERS (E=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_ConstantEnergyTransfer_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_ConstantEnergyTransfer kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_E = E; + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_ConstantEnergyTransfer; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantQE.comp b/mcstas-comps/contrib/MCViNE_ConstantQE.comp new file mode 100644 index 0000000000..5ff5f5683d --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantQE.comp @@ -0,0 +1,122 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantQE +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantQEKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantQEKernel.cc) +* +* Scatterer with fixed momentum transfer |Q| and energy transfer E. +* +* %D +* Scattered neutrons have energy transfer E and |Q| fixed; the azimuth around ki +* is random. S(Q,E) = delta(|Q|-Q0) delta(E-E0) (unnormalised, as in MCViNE). +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_ConstantQE(Q=3, E=20, scattering_coefficient=10, xwidth=0.02, yheight=0.05, zdepth=0.002) +* +* %P +* INPUT PARAMETERS: +* Q: [AA^-1] Momentum transfer |Q| +* E: [meV] Energy transfer +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantQE + +SETTING PARAMETERS (Q=1, E=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_ConstantQE kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_Q = Q; + kernel.m_E = E; + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_ConstantQE, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantQE_process.comp b/mcstas-comps/contrib/MCViNE_ConstantQE_process.comp new file mode 100644 index 0000000000..07acfcc5bd --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantQE_process.comp @@ -0,0 +1,104 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantQE_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantQEKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantQEKernel.cc) +* +* Union process: Scatterer with fixed momentum transfer |Q| and energy transfer E. +* +* %D +* Scattered neutrons have energy transfer E and |Q| fixed; the azimuth around ki +* is random. S(Q,E) = delta(|Q|-Q0) delta(E-E0) (unnormalised, as in MCViNE). +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_ConstantQE (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_ConstantQE_process(Q=3, E=20, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* Q: [AA^-1] Momentum transfer |Q| +* E: [meV] Energy transfer +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantQE_process + +SETTING PARAMETERS (Q=1, E=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_ConstantQE_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_ConstantQE kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_Q = Q; + kernel.m_E = E; + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_ConstantQE; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantvQE.comp b/mcstas-comps/contrib/MCViNE_ConstantvQE.comp new file mode 100644 index 0000000000..6109ce2ef7 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantvQE.comp @@ -0,0 +1,134 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantvQE +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantvQEKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantvQEKernel.cc) +* +* Scatterer with a fixed momentum-transfer vector Q, weighted by a Gaussian in E. +* +* %D +* kf = ki - Q (Q vector fixed in the sample frame); the event weight is multiplied +* by exp(-(E-E0)^2/(2 dE^2)) where E = Ei-Ef. Used for single-crystal resolution +* studies. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_ConstantvQE(Qx=1, Qy=0, Qz=0.5, E=10, dE=1, scattering_coefficient=10, xwidth=0.01, yheight=0.01, zdepth=0.01) +* +* %P +* INPUT PARAMETERS: +* Qx: [AA^-1] Q vector x +* Qy: [AA^-1] Q vector y +* Qz: [AA^-1] Q vector z +* E: [meV] Nominal energy transfer +* dE: [meV] Gaussian sigma of the energy weight +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantvQE + +SETTING PARAMETERS (Qx=0, Qy=0, Qz=0, E=0, dE=1, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_ConstantvQE kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_Q[0] = Qx; + kernel.m_Q[1] = Qy; + kernel.m_Q[2] = Qz; + kernel.m_E = E; + kernel.m_dE = dE; + if (!(dE > 0)) { + fprintf (stderr, "%s: dE must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_ConstantvQE, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_ConstantvQE_process.comp b/mcstas-comps/contrib/MCViNE_ConstantvQE_process.comp new file mode 100644 index 0000000000..3e56f71680 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_ConstantvQE_process.comp @@ -0,0 +1,117 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_ConstantvQE_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE ConstantvQEKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/ConstantvQEKernel.cc) +* +* Union process: Scatterer with a fixed momentum-transfer vector Q, weighted by a Gaussian in E. +* +* %D +* kf = ki - Q (Q vector fixed in the sample frame); the event weight is multiplied +* by exp(-(E-E0)^2/(2 dE^2)) where E = Ei-Ef. Used for single-crystal resolution +* studies. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Orientation: this process is anisotropic; its frame (Q vectors, reciprocal +* vectors, atom positions) follows the ROTATED placement of this component. +* The kernel code is shared with the standalone component MCViNE_ConstantvQE (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_ConstantvQE_process(Qx=1, Qy=0, Qz=0.5, E=10, dE=1, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* Qx: [AA^-1] Q vector x +* Qy: [AA^-1] Q vector y +* Qz: [AA^-1] Q vector z +* E: [meV] Nominal energy transfer +* dE: [meV] Gaussian sigma of the energy weight +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_ConstantvQE_process + +SETTING PARAMETERS (Qx=0, Qy=0, Qz=0, E=0, dE=1, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_ConstantvQE_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_ConstantvQE kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_Q[0] = Qx; + kernel.m_Q[1] = Qy; + kernel.m_Q[2] = Qz; + kernel.m_E = E; + kernel.m_dE = dE; + if (!(dE > 0)) { + fprintf (stderr, "%s: dE must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_ConstantvQE; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 1, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_DGSSXRes.comp b/mcstas-comps/contrib/MCViNE_DGSSXRes.comp new file mode 100644 index 0000000000..52eb1c6c39 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_DGSSXRes.comp @@ -0,0 +1,145 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_DGSSXRes +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE DGSSXResKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/DGSSXResKernel.cc) +* +* Resolution kernel for direct-geometry single-crystal spectrometers (aims at a pixel and TOF window). +* +* %D +* Scatters towards a target disk (position target_x/y/z or target_index, radius +* focus_r) and picks the arrival time at the target uniformly in +* tof_at_target +/- dtof/2 (absolute neutron time, s). The final speed follows +* from the flight distance. Weight: solid_angle/4pi * dtof * dE/dt * vf/vi, as in +* MCViNE. Record ki/kf with monitors to build the resolution ellipsoid (similar +* in purpose to McStas' TOFRes_sample, with MCViNE's weighting). +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_DGSSXRes(target_index=2, focus_r=0.0125, tof_at_target=0.0052, dtof=1e-5, scattering_coefficient=10, xwidth=0.01, yheight=0.01, zdepth=0.01) +* +* %P +* INPUT PARAMETERS: +* target_x: [m] Target position (component frame) x +* target_y: [m] Target position y +* target_z: [m] Target position z +* target_index: [1] Relative index of a component to aim at (overrides target_x/y/z when non-zero) +* focus_r: [m] Radius of the target disk +* tof_at_target: [s] Desired absolute time of arrival at the target +* dtof: [s] Width of the time window +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_DGSSXRes + +SETTING PARAMETERS (target_x=0, target_y=0, target_z=0, int target_index=0, focus_r=0.01, tof_at_target=0.001, dtof=1e-5, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_DGSSXRes kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + { + double tx = target_x, ty = target_y, tz = target_z; + if (target_index) { + Coords ToTarget = coords_sub (POS_A_COMP_INDEX (INDEX_CURRENT_COMP + target_index), POS_A_CURRENT_COMP); + ToTarget = rot_apply (ROT_A_CURRENT_COMP, ToTarget); + coords_get (ToTarget, &tx, &ty, &tz); + } + kernel.m_target[0] = tx; + kernel.m_target[1] = ty; + kernel.m_target[2] = tz; + } + + kernel.m_target_radius = focus_r; + kernel.m_tof_at_target = tof_at_target; + kernel.m_dtof = dtof; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_DGSSXRes, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_DGSSXRes_process.comp b/mcstas-comps/contrib/MCViNE_DGSSXRes_process.comp new file mode 100644 index 0000000000..662a4d2542 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_DGSSXRes_process.comp @@ -0,0 +1,111 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_DGSSXRes_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE DGSSXResKernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/DGSSXResKernel.cc) +* +* Union process: Resolution kernel for direct-geometry single-crystal spectrometers (aims at a pixel and TOF window). +* +* %D +* Scatters towards a target disk (position target_x/y/z or target_index, radius +* focus_r) and picks the arrival time at the target uniformly in +* tof_at_target +/- dtof/2 (absolute neutron time, s). The final speed follows +* from the flight distance. Weight: solid_angle/4pi * dtof * dE/dt * vf/vi, as in +* MCViNE. Record ki/kf with monitors to build the resolution ellipsoid (similar +* in purpose to McStas' TOFRes_sample, with MCViNE's weighting). +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The target is the Union focusing of the geometry (target_index / target_x.. and +* focus_r / focus_xw,focus_xh / focus_aw,focus_ah on Union_box etc.). +* The kernel code is shared with the standalone component MCViNE_DGSSXRes (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_DGSSXRes_process(focus_r=0.0125, tof_at_target=0.0052, dtof=1e-5, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* tof_at_target: [s] Desired absolute time of arrival at the target +* dtof: [s] Width of the time window +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_DGSSXRes_process + +SETTING PARAMETERS (tof_at_target=0.001, dtof=1e-5, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_DGSSXRes_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_DGSSXRes kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + kernel.m_tof_at_target = tof_at_target; + kernel.m_dtof = dtof; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_DGSSXRes; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_DGSSXRES; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_E_Q.comp b/mcstas-comps/contrib/MCViNE_E_Q.comp new file mode 100644 index 0000000000..0c6d4a6559 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_E_Q.comp @@ -0,0 +1,142 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_E_Q +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/E_Q_Kernel.icc) +* +* Isotropic dispersion: S(Q,E) = S(Q) delta(E - E(Q)) with analytic E(Q), S(Q). +* +* %D +* Powder/liquid-like excitation with dispersion E(|Q|) given as an expression in Q +* [AA^-1] returning meV, and intensity S(Q). |Q| is sampled uniformly in +* [Qmin,Qmax] (up to 100 attempts to find a kinematically allowed Q). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_E_Q(E_Q="20*sin(Q*1.5)^2", S_Q="1", Qmin=0, Qmax=10, scattering_coefficient=10, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression, variable Q [AA^-1], result [meV] +* S_Q: [str] S(Q) expression, variable Q +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (up to 100 retries, weight/attempts; slightly biased when part of [Qmin,Qmax] is forbidden). 1: single attempt, unbiased +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_E_Q + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", Qmin=0, Qmax=10, int unbiased=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_E_Q kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_unbiased = unbiased; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_E_Q, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_E_Q_process.comp b/mcstas-comps/contrib/MCViNE_E_Q_process.comp new file mode 100644 index 0000000000..733408dde6 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_E_Q_process.comp @@ -0,0 +1,124 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_E_Q_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/E_Q_Kernel.icc) +* +* Union process: Isotropic dispersion: S(Q,E) = S(Q) delta(E - E(Q)) with analytic E(Q), S(Q). +* +* %D +* Powder/liquid-like excitation with dispersion E(|Q|) given as an expression in Q +* [AA^-1] returning meV, and intensity S(Q). |Q| is sampled uniformly in +* [Qmin,Qmax] (up to 100 attempts to find a kinematically allowed Q). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_E_Q (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_E_Q_process(E_Q="20*sin(Q*1.5)^2", S_Q="1", Qmin=0, Qmax=10, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression, variable Q [AA^-1], result [meV] +* S_Q: [str] S(Q) expression, variable Q +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (up to 100 retries, weight/attempts; slightly biased when part of [Qmin,Qmax] is forbidden). 1: single attempt, unbiased +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_E_Q_process + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", Qmin=0, Qmax=10, int unbiased=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_E_Q_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_E_Q kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_unbiased = unbiased; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_E_Q; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_E_vQ.comp b/mcstas-comps/contrib/MCViNE_E_vQ.comp new file mode 100644 index 0000000000..f31dc2167d --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_E_vQ.comp @@ -0,0 +1,140 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_E_vQ +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE E_vQ_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/E_vQ_Kernel.icc) +* +* Single-crystal dispersion: S(Q,E) = S(Q) delta(E - E(Q)) with analytic E(Qx,Qy,Qz). +* +* %D +* Excitation with dispersion E(Qx,Qy,Qz) [meV] and intensity S(Qx,Qy,Qz), given as +* expressions of the Q vector in the sample (component) frame [AA^-1]. For a +* random final direction, all solutions kf of Ei - Ef(kf) = E(ki - kf) with +* Ef in [Ei-Emax, Ei] are found (nsteps sub-intervals + Ridders' method) and one +* is picked; the weight contains the Jacobian of the delta function. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_E_vQ(E_Q="20*(sin(Qx*1.57)^2+sin(Qy*1.57)^2+sin(Qz*1.57)^2)", S_Q="1", Emax=60, scattering_coefficient=10, xwidth=0.02, yheight=0.02, zdepth=0.02) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Qx,Qy,Qz) expression [meV] +* S_Q: [str] S(Qx,Qy,Qz) expression +* Emax: [meV] Maximum energy transfer considered +* nsteps: [1] Number of sub-intervals for the kf root search (MCViNE: 1000) +* xacc: [AA^-1] Root accuracy in kf (MCViNE: 1e-3) +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_E_vQ + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", Emax=10, int nsteps=1000, xacc=1e-3, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_E_vQ kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Qx", "Qy", "Qz" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Emax = Emax; + kernel.m_nsteps = nsteps > 0 ? nsteps : 1000; + kernel.m_xacc = xacc; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_E_vQ, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_E_vQ_process.comp b/mcstas-comps/contrib/MCViNE_E_vQ_process.comp new file mode 100644 index 0000000000..e2438c43a0 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_E_vQ_process.comp @@ -0,0 +1,123 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_E_vQ_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE E_vQ_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/E_vQ_Kernel.icc) +* +* Union process: Single-crystal dispersion: S(Q,E) = S(Q) delta(E - E(Q)) with analytic E(Qx,Qy,Qz). +* +* %D +* Excitation with dispersion E(Qx,Qy,Qz) [meV] and intensity S(Qx,Qy,Qz), given as +* expressions of the Q vector in the sample (component) frame [AA^-1]. For a +* random final direction, all solutions kf of Ei - Ef(kf) = E(ki - kf) with +* Ef in [Ei-Emax, Ei] are found (nsteps sub-intervals + Ridders' method) and one +* is picked; the weight contains the Jacobian of the delta function. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Orientation: this process is anisotropic; its frame (Q vectors, reciprocal +* vectors, atom positions) follows the ROTATED placement of this component. +* The kernel code is shared with the standalone component MCViNE_E_vQ (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_E_vQ_process(E_Q="20*(sin(Qx*1.57)^2+sin(Qy*1.57)^2+sin(Qz*1.57)^2)", S_Q="1", Emax=60, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Qx,Qy,Qz) expression [meV] +* S_Q: [str] S(Qx,Qy,Qz) expression +* Emax: [meV] Maximum energy transfer considered +* nsteps: [1] Number of sub-intervals for the kf root search (MCViNE: 1000) +* xacc: [AA^-1] Root accuracy in kf (MCViNE: 1e-3) +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_E_vQ_process + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", Emax=10, int nsteps=1000, xacc=1e-3, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_E_vQ_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_E_vQ kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Qx", "Qy", "Qz" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Emax = Emax; + kernel.m_nsteps = nsteps > 0 ? nsteps : 1000; + kernel.m_xacc = xacc; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_E_vQ; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 1, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q.comp b/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q.comp new file mode 100644 index 0000000000..9c7f0684a2 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q.comp @@ -0,0 +1,149 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_LorentzianBroadened_E_Q +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE LorentzianBroadened_E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/LorentzianBroadened_E_Q_Kernel.icc) +* +* Isotropic dispersion E(Q) broadened by a Lorentzian of Q-dependent width. +* +* %D +* S(Q,E) = S(Q) L(E - E(Q); gamma(Q)) with L a Lorentzian of half width at half +* maximum gamma(Q). +* Q is sampled uniformly in [Qmin,Qmax]; the energy offset is sampled from the +* line shape (up to 100 attempts). Neutrons with Ei below min(E(Q)-3w(Q)) do not +* scatter. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_LorentzianBroadened_E_Q(E_Q="20*sin(Q*1.5)^2", S_Q="1", gamma_Q="0.5", Qmin=0, Qmax=10, scattering_coefficient=10, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression [meV], variable Q [AA^-1] +* S_Q: [str] S(Q) expression +* gamma_Q: [str] Lorentzian HWHM gamma(Q) [meV] +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (retries without acceptance correction: over-weights when part of the Q range is forbidden). 1: single attempt, unbiased +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_LorentzianBroadened_E_Q + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", string gamma_Q="1", Qmin=0, Qmax=10, int unbiased=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Broadened_E_Q kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_W_Q, gamma_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_lorentzian = 1; + kernel.m_unbiased = unbiased; + mcvine_Broadened_E_Q_init (&kernel); + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Broadened_E_Q, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q_process.comp b/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q_process.comp new file mode 100644 index 0000000000..2bfa6f0bd2 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_LorentzianBroadened_E_Q_process.comp @@ -0,0 +1,131 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_LorentzianBroadened_E_Q_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE LorentzianBroadened_E_Q_Kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/LorentzianBroadened_E_Q_Kernel.icc) +* +* Union process: Isotropic dispersion E(Q) broadened by a Lorentzian of Q-dependent width. +* +* %D +* S(Q,E) = S(Q) L(E - E(Q); gamma(Q)) with L a Lorentzian of half width at half +* maximum gamma(Q). +* Q is sampled uniformly in [Qmin,Qmax]; the energy offset is sampled from the +* line shape (up to 100 attempts). Neutrons with Ei below min(E(Q)-3w(Q)) do not +* scatter. +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_LorentzianBroadened_E_Q (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_LorentzianBroadened_E_Q_process(E_Q="20*sin(Q*1.5)^2", S_Q="1", gamma_Q="0.5", Qmin=0, Qmax=10, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* E_Q: [str] E(Q) expression [meV], variable Q [AA^-1] +* S_Q: [str] S(Q) expression +* gamma_Q: [str] Lorentzian HWHM gamma(Q) [meV] +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* unbiased: [1] 0: MCViNE sampling (retries without acceptance correction: over-weights when part of the Q range is forbidden). 1: single attempt, unbiased +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_LorentzianBroadened_E_Q_process + +SETTING PARAMETERS (string E_Q="10", string S_Q="1", string gamma_Q="1", Qmin=0, Qmax=10, int unbiased=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_LorentzianBroadened_E_Q_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Broadened_E_Q kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_E_Q, E_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_S_Q, S_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (mcvine_func_setup (&kernel.m_W_Q, gamma_Q, NULL, 0, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + if (Qmin < 0 || Qmin >= Qmax) { + fprintf (stderr, "%s: need 0 <= Qmin < Qmax\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_lorentzian = 1; + kernel.m_unbiased = unbiased; + mcvine_Broadened_E_Q_init (&kernel); + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Broadened_E_Q; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal.comp b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal.comp new file mode 100644 index 0000000000..c20df9eec8 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal.comp @@ -0,0 +1,161 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_CoherentInelastic_PolyXtal +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon CoherentInelastic_PolyXtal kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/CoherentInelastic_PolyXtal.cc) +* +* Coherent one-phonon scattering from a powder, using a full phonon dispersion (energies + polarizations) on a grid. +* +* %D +* Powder average of the coherent one-phonon cross section, computed from phonon +* energies and polarization vectors tabulated on a grid over one reciprocal cell +* (MCViNE IDF format, e.g. from phonopy via MCViNE tools). A random branch and a +* random Q vector in a cube are drawn until the event is kinematically allowed; +* phonon creation/annihilation, Bose factor and Debye-Waller factor included. +* Scattering coefficient: total coherent cross section / Vc. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_Phonon_CoherentInelastic_PolyXtal(idf_dir="MCViNE/fcc_toy_phonons", atoms="MCViNE/fcc_toy_atoms.dat", T=300, max_omega=45, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* idf_dir: [str] Directory with MCViNE IDF phonon files: Qgridinfo, Omega2, Polarizations[, DOS] +* atoms: [str] Atoms file: one row per atom 'x y z mass b_coh sigma_inc sigma_abs' ([AA] cartesian, [amu], [fm], [barn], [barn]), same order as in the IDF files +* T: [K] Temperature +* dw_core: [AA^2] Debye-Waller core; <0: computed from the DOS (idf_dir/DOS or dos) +* dos: [str] Optional DOS file for the Debye-Waller factor (default: idf_dir/DOS) +* Vc: [AA^3] Unit cell volume; 0: (2pi)^3/|b1.(b2 x b3)| from Qgridinfo +* max_omega: [meV] Maximum phonon energy +* min_omega: [meV] Phonons below this energy are skipped +* unbiased: [1] 0: MCViNE sampling (rejection + empirical accessible reciprocal volume, a few % high in tests). 1: single Q sample in the cube with its exact volume, unbiased +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_CoherentInelastic_PolyXtal + +SETTING PARAMETERS (string idf_dir=0, string atoms=0, T=300, dw_core=-1, string dos=0, Vc=0, max_omega=50, min_omega=0.01, int unbiased=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Phonon_CoherentInelastic_PolyXtal kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + { + int i; + double mass = 0, xs_abs = 0, V; + mcvine_dispersion* dp = (mcvine_dispersion*)calloc (1, sizeof (mcvine_dispersion)); + if (mcvine_dispersion_load_idf (dp, idf_dir, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_natoms = mcvine_atoms_load (&kernel.m_atoms, atoms, NAME_CURRENT_COMP); + if (kernel.m_natoms < 0) + exit (-1); + if (kernel.m_natoms != dp->natoms) { + fprintf (stderr, "%s: atoms file has %d atoms but the dispersion has %d\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->natoms); + exit (-1); + } + kernel.m_disp = dp; + kernel.m_T = T; + kernel.m_xs_coh_tot = 0; + for (i = 0; i < kernel.m_natoms; i++) { + mass += kernel.m_atoms[i].mass; + kernel.m_xs_coh_tot += kernel.m_atoms[i].xs_coh; + xs_abs += kernel.m_atoms[i].xs_abs; + } + mass /= kernel.m_natoms; + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (dos && dos[0]) { + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + } else if (dp->has_dos) + d = dp->m_dos; + else { + fprintf (stderr, "%s: no DOS for the Debye-Waller factor (give dw_core, dos, or idf_dir/DOS)\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, mass, T, 100); + } + V = Vc > 0 ? Vc : dp->ucvol; + mu = mcvine_xs2coeff (xs_abs, V); + sig = mcvine_xs2coeff (kernel.m_xs_coh_tot, V); + printf ("%s: %d atoms, %d branches, grid %dx%dx%d, Vc=%g AA^3, sigma_coh=%g barn, DW core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->nbranches, + dp->n[0], dp->n[1], dp->n[2], V, kernel.m_xs_coh_tot, kernel.m_dw_core); + } + kernel.m_max_omega = max_omega; + kernel.m_min_omega = min_omega; + kernel.m_unbiased = unbiased; + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Phonon_CoherentInelastic_PolyXtal, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal_process.comp b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal_process.comp new file mode 100644 index 0000000000..c1b1e83f82 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_PolyXtal_process.comp @@ -0,0 +1,149 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_CoherentInelastic_PolyXtal_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon CoherentInelastic_PolyXtal kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/CoherentInelastic_PolyXtal.cc) +* +* Union process: Coherent one-phonon scattering from a powder, using a full phonon dispersion (energies + polarizations) on a grid. +* +* %D +* Powder average of the coherent one-phonon cross section, computed from phonon +* energies and polarization vectors tabulated on a grid over one reciprocal cell +* (MCViNE IDF format, e.g. from phonopy via MCViNE tools). A random branch and a +* random Q vector in a cube are drawn until the event is kinematically allowed; +* phonon creation/annihilation, Bose factor and Debye-Waller factor included. +* Scattering coefficient: total coherent cross section / Vc. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_Phonon_CoherentInelastic_PolyXtal (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_Phonon_CoherentInelastic_PolyXtal_process(idf_dir="MCViNE/fcc_toy_phonons", atoms="MCViNE/fcc_toy_atoms.dat", T=300, max_omega=45) +* +* %P +* INPUT PARAMETERS: +* idf_dir: [str] Directory with MCViNE IDF phonon files: Qgridinfo, Omega2, Polarizations[, DOS] +* atoms: [str] Atoms file: one row per atom 'x y z mass b_coh sigma_inc sigma_abs' ([AA] cartesian, [amu], [fm], [barn], [barn]), same order as in the IDF files +* T: [K] Temperature +* dw_core: [AA^2] Debye-Waller core; <0: computed from the DOS (idf_dir/DOS or dos) +* dos: [str] Optional DOS file for the Debye-Waller factor (default: idf_dir/DOS) +* Vc: [AA^3] Unit cell volume; 0: (2pi)^3/|b1.(b2 x b3)| from Qgridinfo +* max_omega: [meV] Maximum phonon energy +* min_omega: [meV] Phonons below this energy are skipped +* unbiased: [1] 0: MCViNE sampling (rejection + empirical accessible reciprocal volume, a few % high in tests). 1: single Q sample in the cube with its exact volume, unbiased +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_CoherentInelastic_PolyXtal_process + +SETTING PARAMETERS (string idf_dir=0, string atoms=0, T=300, dw_core=-1, string dos=0, Vc=0, max_omega=50, min_omega=0.01, int unbiased=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_Phonon_CoherentInelastic_PolyXtal_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Phonon_CoherentInelastic_PolyXtal kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + { + int i; + double mass = 0, xs_abs = 0, V; + mcvine_dispersion* dp = (mcvine_dispersion*)calloc (1, sizeof (mcvine_dispersion)); + if (mcvine_dispersion_load_idf (dp, idf_dir, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_natoms = mcvine_atoms_load (&kernel.m_atoms, atoms, NAME_CURRENT_COMP); + if (kernel.m_natoms < 0) + exit (-1); + if (kernel.m_natoms != dp->natoms) { + fprintf (stderr, "%s: atoms file has %d atoms but the dispersion has %d\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->natoms); + exit (-1); + } + kernel.m_disp = dp; + kernel.m_T = T; + kernel.m_xs_coh_tot = 0; + for (i = 0; i < kernel.m_natoms; i++) { + mass += kernel.m_atoms[i].mass; + kernel.m_xs_coh_tot += kernel.m_atoms[i].xs_coh; + xs_abs += kernel.m_atoms[i].xs_abs; + } + mass /= kernel.m_natoms; + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (dos && dos[0]) { + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + } else if (dp->has_dos) + d = dp->m_dos; + else { + fprintf (stderr, "%s: no DOS for the Debye-Waller factor (give dw_core, dos, or idf_dir/DOS)\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, mass, T, 100); + } + V = Vc > 0 ? Vc : dp->ucvol; + mu = mcvine_xs2coeff (xs_abs, V); + sig = mcvine_xs2coeff (kernel.m_xs_coh_tot, V); + printf ("%s: %d atoms, %d branches, grid %dx%dx%d, Vc=%g AA^3, sigma_coh=%g barn, DW core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->nbranches, + dp->n[0], dp->n[1], dp->n[2], V, kernel.m_xs_coh_tot, kernel.m_dw_core); + } + kernel.m_max_omega = max_omega; + kernel.m_min_omega = min_omega; + kernel.m_unbiased = unbiased; + printf ("%s: absorption is not part of the process; set Union_make_material(my_absorption=%g) for this material\n", NAME_CURRENT_COMP, mu); + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Phonon_CoherentInelastic_PolyXtal; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal.comp b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal.comp new file mode 100644 index 0000000000..10f739fbc4 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal.comp @@ -0,0 +1,184 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_CoherentInelastic_SingleXtal +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon CoherentInelastic_SingleXtal kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/CoherentInelastic_SingleXtal.cc) +* +* Coherent one-phonon scattering from a single crystal, using a full phonon dispersion on a grid. +* +* %D +* Single-crystal coherent one-phonon scattering with dispersion and polarization +* vectors from MCViNE IDF files (periodic over the reciprocal cell b1,b2,b3 given +* in Qgridinfo; orient the crystal by rotating the component). For a final +* direction (4pi, or a cone towards a target when focus_r>0) and a random +* branch among those with Emin < 1.5 Ei, all final speeds solving +* omega(Q) = |Ei-Ef| are found (Ridders' method on nsteps sub-intervals of +* [0,2vi]); one is chosen and weighted by the delta-function Jacobian, +* |sum_d b_d/sqrt(M_d) exp(iQ.d)(Q.e_d)|^2, Bose and Debye-Waller factors. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_Phonon_CoherentInelastic_SingleXtal(idf_dir="MCViNE/fcc_toy_phonons", atoms="MCViNE/fcc_toy_atoms.dat", T=300, xwidth=0.01, yheight=0.01, zdepth=0.01) +* +* %P +* INPUT PARAMETERS: +* idf_dir: [str] Directory with MCViNE IDF phonon files: Qgridinfo, Omega2, Polarizations[, DOS] +* atoms: [str] Atoms file: one row per atom 'x y z mass b_coh sigma_inc sigma_abs' ([AA] cartesian, [amu], [fm], [barn], [barn]), same order as in the IDF files +* T: [K] Temperature +* dw_core: [AA^2] Debye-Waller core; <0: computed from the DOS (idf_dir/DOS or dos) +* dos: [str] Optional DOS file for the Debye-Waller factor (default: idf_dir/DOS) +* Vc: [AA^3] Unit cell volume; 0: (2pi)^3/|b1.(b2 x b3)| from Qgridinfo +* target_x: [m] Target position (component frame) x +* target_y: [m] Target position y +* target_z: [m] Target position z +* target_index: [1] Relative index of a component to aim at (overrides target_x/y/z when non-zero) +* focus_r: [m] Radius of the target disk; 0: scatter into 4pi (MCViNE default) +* deltaV_Jacobi: [1] Relative velocity step for the numerical Jacobian +* nsteps: [1] Sub-intervals for the root search in vf +* xacc: [m/s] Root accuracy in vf +* unbiased: [1] 0: MCViNE sampling (retries up to 100 direction/branch draws until omega(Q)=|Ei-Ef| has a solution, without correcting the weight: over-estimates when many directions have no solution). 1: single attempt, unbiased +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_CoherentInelastic_SingleXtal + +SETTING PARAMETERS (string idf_dir=0, string atoms=0, T=300, dw_core=-1, string dos=0, Vc=0, target_x=0, target_y=0, target_z=0, int target_index=0, focus_r=0, deltaV_Jacobi=0.001, int nsteps=100, xacc=10, int unbiased=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Phonon_CoherentInelastic_SingleXtal kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + { + int i; + double mass = 0, xs_abs = 0, V; + mcvine_dispersion* dp = (mcvine_dispersion*)calloc (1, sizeof (mcvine_dispersion)); + if (mcvine_dispersion_load_idf (dp, idf_dir, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_natoms = mcvine_atoms_load (&kernel.m_atoms, atoms, NAME_CURRENT_COMP); + if (kernel.m_natoms < 0) + exit (-1); + if (kernel.m_natoms != dp->natoms) { + fprintf (stderr, "%s: atoms file has %d atoms but the dispersion has %d\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->natoms); + exit (-1); + } + kernel.m_disp = dp; + kernel.m_T = T; + kernel.m_xs_coh_tot = 0; + for (i = 0; i < kernel.m_natoms; i++) { + mass += kernel.m_atoms[i].mass; + kernel.m_xs_coh_tot += kernel.m_atoms[i].xs_coh; + xs_abs += kernel.m_atoms[i].xs_abs; + } + mass /= kernel.m_natoms; + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (dos && dos[0]) { + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + } else if (dp->has_dos) + d = dp->m_dos; + else { + fprintf (stderr, "%s: no DOS for the Debye-Waller factor (give dw_core, dos, or idf_dir/DOS)\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, mass, T, 100); + } + V = Vc > 0 ? Vc : dp->ucvol; + mu = mcvine_xs2coeff (xs_abs, V); + sig = mcvine_xs2coeff (kernel.m_xs_coh_tot, V); + printf ("%s: %d atoms, %d branches, grid %dx%dx%d, Vc=%g AA^3, sigma_coh=%g barn, DW core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->nbranches, + dp->n[0], dp->n[1], dp->n[2], V, kernel.m_xs_coh_tot, kernel.m_dw_core); + } + + { + double tx = target_x, ty = target_y, tz = target_z; + if (target_index) { + Coords ToTarget = coords_sub (POS_A_COMP_INDEX (INDEX_CURRENT_COMP + target_index), POS_A_CURRENT_COMP); + ToTarget = rot_apply (ROT_A_CURRENT_COMP, ToTarget); + coords_get (ToTarget, &tx, &ty, &tz); + } + kernel.m_target[0] = tx; + kernel.m_target[1] = ty; + kernel.m_target[2] = tz; + } + + kernel.m_target_radius = focus_r; + kernel.m_deltaV_Jacobi = deltaV_Jacobi; + kernel.m_nsteps = nsteps > 0 ? nsteps : 100; + kernel.m_xacc = xacc; + kernel.m_unbiased = unbiased; + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Phonon_CoherentInelastic_SingleXtal, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal_process.comp b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal_process.comp new file mode 100644 index 0000000000..d1b0f7a8ec --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_CoherentInelastic_SingleXtal_process.comp @@ -0,0 +1,156 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_CoherentInelastic_SingleXtal_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon CoherentInelastic_SingleXtal kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/CoherentInelastic_SingleXtal.cc) +* +* Union process: Coherent one-phonon scattering from a single crystal, using a full phonon dispersion on a grid. +* +* %D +* Single-crystal coherent one-phonon scattering with dispersion and polarization +* vectors from MCViNE IDF files (periodic over the reciprocal cell b1,b2,b3 given +* in Qgridinfo; orient the crystal by rotating the component). For a final +* direction (4pi, or a cone towards a target when focus_r>0) and a random +* branch among those with Emin < 1.5 Ei, all final speeds solving +* omega(Q) = |Ei-Ef| are found (Ridders' method on nsteps sub-intervals of +* [0,2vi]); one is chosen and weighted by the delta-function Jacobian, +* |sum_d b_d/sqrt(M_d) exp(iQ.d)(Q.e_d)|^2, Bose and Debye-Waller factors. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Orientation: this process is anisotropic; its frame (Q vectors, reciprocal +* vectors, atom positions) follows the ROTATED placement of this component. +* The kernel code is shared with the standalone component MCViNE_Phonon_CoherentInelastic_SingleXtal (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_Phonon_CoherentInelastic_SingleXtal_process(idf_dir="MCViNE/fcc_toy_phonons", atoms="MCViNE/fcc_toy_atoms.dat", T=300) +* +* %P +* INPUT PARAMETERS: +* idf_dir: [str] Directory with MCViNE IDF phonon files: Qgridinfo, Omega2, Polarizations[, DOS] +* atoms: [str] Atoms file: one row per atom 'x y z mass b_coh sigma_inc sigma_abs' ([AA] cartesian, [amu], [fm], [barn], [barn]), same order as in the IDF files +* T: [K] Temperature +* dw_core: [AA^2] Debye-Waller core; <0: computed from the DOS (idf_dir/DOS or dos) +* dos: [str] Optional DOS file for the Debye-Waller factor (default: idf_dir/DOS) +* Vc: [AA^3] Unit cell volume; 0: (2pi)^3/|b1.(b2 x b3)| from Qgridinfo +* deltaV_Jacobi: [1] Relative velocity step for the numerical Jacobian +* nsteps: [1] Sub-intervals for the root search in vf +* xacc: [m/s] Root accuracy in vf +* unbiased: [1] 0: MCViNE sampling (retries up to 100 direction/branch draws until omega(Q)=|Ei-Ef| has a solution, without correcting the weight: over-estimates when many directions have no solution). 1: single attempt, unbiased +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_CoherentInelastic_SingleXtal_process + +SETTING PARAMETERS (string idf_dir=0, string atoms=0, T=300, dw_core=-1, string dos=0, Vc=0, deltaV_Jacobi=0.001, int nsteps=100, xacc=10, int unbiased=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_Phonon_CoherentInelastic_SingleXtal_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Phonon_CoherentInelastic_SingleXtal kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + { + int i; + double mass = 0, xs_abs = 0, V; + mcvine_dispersion* dp = (mcvine_dispersion*)calloc (1, sizeof (mcvine_dispersion)); + if (mcvine_dispersion_load_idf (dp, idf_dir, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_natoms = mcvine_atoms_load (&kernel.m_atoms, atoms, NAME_CURRENT_COMP); + if (kernel.m_natoms < 0) + exit (-1); + if (kernel.m_natoms != dp->natoms) { + fprintf (stderr, "%s: atoms file has %d atoms but the dispersion has %d\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->natoms); + exit (-1); + } + kernel.m_disp = dp; + kernel.m_T = T; + kernel.m_xs_coh_tot = 0; + for (i = 0; i < kernel.m_natoms; i++) { + mass += kernel.m_atoms[i].mass; + kernel.m_xs_coh_tot += kernel.m_atoms[i].xs_coh; + xs_abs += kernel.m_atoms[i].xs_abs; + } + mass /= kernel.m_natoms; + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (dos && dos[0]) { + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + } else if (dp->has_dos) + d = dp->m_dos; + else { + fprintf (stderr, "%s: no DOS for the Debye-Waller factor (give dw_core, dos, or idf_dir/DOS)\n", NAME_CURRENT_COMP); + exit (-1); + } + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, mass, T, 100); + } + V = Vc > 0 ? Vc : dp->ucvol; + mu = mcvine_xs2coeff (xs_abs, V); + sig = mcvine_xs2coeff (kernel.m_xs_coh_tot, V); + printf ("%s: %d atoms, %d branches, grid %dx%dx%d, Vc=%g AA^3, sigma_coh=%g barn, DW core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_natoms, dp->nbranches, + dp->n[0], dp->n[1], dp->n[2], V, kernel.m_xs_coh_tot, kernel.m_dw_core); + } + + kernel.m_deltaV_Jacobi = deltaV_Jacobi; + kernel.m_nsteps = nsteps > 0 ? nsteps : 100; + kernel.m_xacc = xacc; + kernel.m_unbiased = unbiased; + kernel.m_target_radius = 0; /* Union version: 4pi, as MCViNE's default */ + printf ("%s: absorption is not part of the process; set Union_make_material(my_absorption=%g) for this material\n", NAME_CURRENT_COMP, mu); + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Phonon_CoherentInelastic_SingleXtal; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 1, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic.comp b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic.comp new file mode 100644 index 0000000000..06976bbbfa --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic.comp @@ -0,0 +1,131 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_IncoherentElastic +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon IncoherentElastic kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/IncoherentElastic.cc) +* +* Incoherent elastic scattering with Debye-Waller factor exp(-2W), 2W = dw_core*Q^2. +* +* %D +* Isotropic incoherent elastic scattering damped by the Debye-Waller factor. +* dw_core [AA^2] is given directly, or (dw_core<0) computed from a phonon DOS, +* temperature and average atomic mass exactly as MCViNE's DWFromDOS. +* McStas' Incoherent has no Debye-Waller factor. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_Phonon_IncoherentElastic(dw_core=0.0067, sigma_inc=10, sigma_abs=10, Vc=27.6, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* dw_core: [AA^2] Debye-Waller core u^2 (2W = dw_core*Q^2); <0: compute from dos +* dos: [str] Phonon DOS file (2-column E[meV] g, or MCViNE IDF DOS) for dw_core<0 +* T: [K] Temperature (for dw_core from DOS) +* average_mass: [amu] Average atomic mass (for dw_core from DOS) +* sigma_inc: [barn] Incoherent scattering cross section per unit cell +* sigma_abs: [barn] Absorption cross section per unit cell at 2200 m/s +* Vc: [AA^3] Unit cell volume +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_IncoherentElastic + +SETTING PARAMETERS (dw_core=-1, string dos=0, T=300, average_mass=0, sigma_inc=0, sigma_abs=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Phonon_IncoherentElastic kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (!(average_mass > 0)) { + fprintf (stderr, "%s: average_mass needed to compute dw_core\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, average_mass, T, 100); + printf ("%s: Debye-Waller core from DOS: %g AA^2\n", NAME_CURRENT_COMP, kernel.m_dw_core); + } + + if (!(Vc > 0) || !(sigma_inc > 0)) { + fprintf (stderr, "%s: need sigma_inc>0 and Vc>0\n", NAME_CURRENT_COMP); + exit (-1); + } + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_inc, Vc); + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Phonon_IncoherentElastic, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic_process.comp b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic_process.comp new file mode 100644 index 0000000000..42beb50c10 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentElastic_process.comp @@ -0,0 +1,116 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_IncoherentElastic_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon IncoherentElastic kernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/IncoherentElastic.cc) +* +* Union process: Incoherent elastic scattering with Debye-Waller factor exp(-2W), 2W = dw_core*Q^2. +* +* %D +* Isotropic incoherent elastic scattering damped by the Debye-Waller factor. +* dw_core [AA^2] is given directly, or (dw_core<0) computed from a phonon DOS, +* temperature and average atomic mass exactly as MCViNE's DWFromDOS. +* McStas' Incoherent has no Debye-Waller factor. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_Phonon_IncoherentElastic (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_Phonon_IncoherentElastic_process(dw_core=0.0067, sigma_inc=10, Vc=27.6) +* +* %P +* INPUT PARAMETERS: +* dw_core: [AA^2] Debye-Waller core u^2 (2W = dw_core*Q^2); <0: compute from dos +* dos: [str] Phonon DOS file (2-column E[meV] g, or MCViNE IDF DOS) for dw_core<0 +* T: [K] Temperature (for dw_core from DOS) +* average_mass: [amu] Average atomic mass (for dw_core from DOS) +* sigma_inc: [barn] Incoherent scattering cross section per unit cell +* Vc: [AA^3] Unit cell volume +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_IncoherentElastic_process + +SETTING PARAMETERS (dw_core=-1, string dos=0, T=300, average_mass=0, sigma_inc=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_Phonon_IncoherentElastic_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Phonon_IncoherentElastic kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (dw_core >= 0) + kernel.m_dw_core = dw_core; + else { + mcvine_dos d; + if (!(average_mass > 0)) { + fprintf (stderr, "%s: average_mass needed to compute dw_core\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_dos_load (&d, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_dw_core = mcvine_dw_core_from_dos (&d, average_mass, T, 100); + printf ("%s: Debye-Waller core from DOS: %g AA^2\n", NAME_CURRENT_COMP, kernel.m_dw_core); + } + + if (!(Vc > 0) || !(sigma_inc > 0)) { + fprintf (stderr, "%s: need sigma_inc>0 and Vc>0\n", NAME_CURRENT_COMP); + exit (-1); + } + sig = mcvine_xs2coeff (sigma_inc, Vc); + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Phonon_IncoherentElastic; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic.comp b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic.comp new file mode 100644 index 0000000000..7daaf234e3 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic.comp @@ -0,0 +1,142 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_IncoherentInelastic +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon IncoherentInelastic / IncoherentInelastic_EnergyFocusing kernels; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/IncoherentInelastic.cc, IncoherentInelastic_EnergyFocusing.cc) +* +* One-phonon incoherent inelastic scattering from a phonon DOS (incoherent approximation), optional Ef focusing. +* +* %D +* S_inc(Q,E) = exp(-2W) hbar^2Q^2/(2M) g(|E|)/|E| [n(E)+1 or n(E)] with the DOS +* g(E) normalised to 1, Debye-Waller factor computed from the DOS (MCViNE +* DWFromDOS), and the DOS preprocessed like MCViNE (resampled to >=500 points, +* parabolic low-energy fit, normalised). The final direction is uniform over 4pi; +* Ef is uniform in [Ei-Emax_dos, Ei+Emax_dos]. With dEf>0, Ef is restricted to +* Ef +/- dEf/2 (MCViNE IncoherentInelastic_EnergyFocusing). +* DOS file: 2 columns E [meV] g(E) (a '#...THz' comment switches the unit to THz) +* or an MCViNE IDF binary 'DOS' file. Multiphonon terms are not included (see +* Union IncoherentPhonon_process or NCrystal for those). +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_Phonon_IncoherentInelastic(dos="MCViNE/Debye_dos.dat", T=300, average_mass=50.94, sigma_inc=10.1, sigma_abs=10.1, Vc=27.6, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* dos: [str] Phonon DOS file +* T: [K] Temperature +* average_mass: [amu] Average atomic mass +* Ef: [meV] Final energy for energy focusing (used when dEf>0) +* dEf: [meV] Full width of the final-energy window; 0 disables focusing +* sigma_inc: [barn] Incoherent scattering cross section per unit cell +* sigma_abs: [barn] Absorption cross section per unit cell at 2200 m/s +* Vc: [AA^3] Unit cell volume +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_IncoherentInelastic + +SETTING PARAMETERS (string dos=0, T=300, average_mass=0, Ef=0, dEf=0, sigma_inc=0, sigma_abs=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_Phonon_IncoherentInelastic kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (!(average_mass > 0)) { + fprintf (stderr, "%s: average_mass must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + if (!(T > 0)) { + fprintf (stderr, "%s: T must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_dos_load (&kernel.m_dos, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_T = T; + kernel.m_mass = average_mass; + kernel.m_max_omega = kernel.m_dos.emax; + kernel.m_dw_core = mcvine_dw_core_from_dos (&kernel.m_dos, average_mass, T, 100); + kernel.m_focusing = dEf > 0; + kernel.m_Ef = Ef; + kernel.m_dEf = dEf; + printf ("%s: DOS Emax=%g meV, Debye-Waller core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_dos.emax, kernel.m_dw_core); + + if (!(Vc > 0) || !(sigma_inc > 0)) { + fprintf (stderr, "%s: need sigma_inc>0 and Vc>0\n", NAME_CURRENT_COMP); + exit (-1); + } + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_inc, Vc); + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_Phonon_IncoherentInelastic, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic_process.comp b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic_process.comp new file mode 100644 index 0000000000..655e991306 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_Phonon_IncoherentInelastic_process.comp @@ -0,0 +1,127 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_Phonon_IncoherentInelastic_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE phonon IncoherentInelastic / IncoherentInelastic_EnergyFocusing kernels; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/phonon/IncoherentInelastic.cc, IncoherentInelastic_EnergyFocusing.cc) +* +* Union process: One-phonon incoherent inelastic scattering from a phonon DOS (incoherent approximation), optional Ef focusing. +* +* %D +* S_inc(Q,E) = exp(-2W) hbar^2Q^2/(2M) g(|E|)/|E| [n(E)+1 or n(E)] with the DOS +* g(E) normalised to 1, Debye-Waller factor computed from the DOS (MCViNE +* DWFromDOS), and the DOS preprocessed like MCViNE (resampled to >=500 points, +* parabolic low-energy fit, normalised). The final direction is uniform over 4pi; +* Ef is uniform in [Ei-Emax_dos, Ei+Emax_dos]. With dEf>0, Ef is restricted to +* Ef +/- dEf/2 (MCViNE IncoherentInelastic_EnergyFocusing). +* DOS file: 2 columns E [meV] g(E) (a '#...THz' comment switches the unit to THz) +* or an MCViNE IDF binary 'DOS' file. Multiphonon terms are not included (see +* Union IncoherentPhonon_process or NCrystal for those). +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_Phonon_IncoherentInelastic (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_Phonon_IncoherentInelastic_process(dos="MCViNE/Debye_dos.dat", T=300, average_mass=50.94, sigma_inc=10.1, Vc=27.6) +* +* %P +* INPUT PARAMETERS: +* dos: [str] Phonon DOS file +* T: [K] Temperature +* average_mass: [amu] Average atomic mass +* Ef: [meV] Final energy for energy focusing (used when dEf>0) +* dEf: [meV] Full width of the final-energy window; 0 disables focusing +* sigma_inc: [barn] Incoherent scattering cross section per unit cell +* Vc: [AA^3] Unit cell volume +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_Phonon_IncoherentInelastic_process + +SETTING PARAMETERS (string dos=0, T=300, average_mass=0, Ef=0, dEf=0, sigma_inc=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_Phonon_IncoherentInelastic_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_Phonon_IncoherentInelastic kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (!(average_mass > 0)) { + fprintf (stderr, "%s: average_mass must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + if (!(T > 0)) { + fprintf (stderr, "%s: T must be > 0\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_dos_load (&kernel.m_dos, dos, 0, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_T = T; + kernel.m_mass = average_mass; + kernel.m_max_omega = kernel.m_dos.emax; + kernel.m_dw_core = mcvine_dw_core_from_dos (&kernel.m_dos, average_mass, T, 100); + kernel.m_focusing = dEf > 0; + kernel.m_Ef = Ef; + kernel.m_dEf = dEf; + printf ("%s: DOS Emax=%g meV, Debye-Waller core=%g AA^2\n", NAME_CURRENT_COMP, kernel.m_dos.emax, kernel.m_dw_core); + + if (!(Vc > 0) || !(sigma_inc > 0)) { + fprintf (stderr, "%s: need sigma_inc>0 and Vc>0\n", NAME_CURRENT_COMP); + exit (-1); + } + sig = mcvine_xs2coeff (sigma_inc, Vc); + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_Phonon_IncoherentInelastic; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SANS2D_ongrid.comp b/mcstas-comps/contrib/MCViNE_SANS2D_ongrid.comp new file mode 100644 index 0000000000..6da79df966 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SANS2D_ongrid.comp @@ -0,0 +1,130 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SANS2D_ongrid +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SANS2D_ongrid_Kernel (mcvine.acc); MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/acc (acc/kernels/SANS2D_ongrid.py) +* +* SANS from a 2D S(Qx,Qy) map on a grid (beam along z). +* +* %D +* Qx, Qy are sampled uniformly over the grid range; the neutron gets +* v_perp -= Q*K2V and vz = sqrt(vi^2 - vx^2 - vy^2) (elastic). The weight is the +* bilinearly interpolated S(Qx,Qy) (no solid-angle Jacobian, as in mcvine.acc; +* use scattering_coefficient to set the absolute scale). File layout: first +* numeric row Qx values (nx, ascending), second row Qy values (ny), then ny rows of +* nx values (row index = Qy), i.e. the (y,x) image layout used by mcvine.acc. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_SANS2D_ongrid(S_QxQy="MCViNE/SANS2D_example.dat", scattering_coefficient=1, xwidth=0.01, yheight=0.01, zdepth=0.001) +* +* %P +* INPUT PARAMETERS: +* S_QxQy: [str] 2D grid file (see description) +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SANS2D_ongrid + +SETTING PARAMETERS (string S_QxQy=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_SANS2D_ongrid kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (mcvine_grid2d_load_image (&kernel.m_S, S_QxQy, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Qx_min = kernel.m_S.x[0]; + kernel.m_Qx_max = kernel.m_S.x[kernel.m_S.nx - 1]; + kernel.m_Qy_min = kernel.m_S.y[0]; + kernel.m_Qy_max = kernel.m_S.y[kernel.m_S.ny - 1]; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_SANS2D_ongrid, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SANS2D_ongrid_process.comp b/mcstas-comps/contrib/MCViNE_SANS2D_ongrid_process.comp new file mode 100644 index 0000000000..2aa75f0646 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SANS2D_ongrid_process.comp @@ -0,0 +1,113 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SANS2D_ongrid_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SANS2D_ongrid_Kernel (mcvine.acc); MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/acc (acc/kernels/SANS2D_ongrid.py) +* +* Union process: SANS from a 2D S(Qx,Qy) map on a grid (beam along z). +* +* %D +* Qx, Qy are sampled uniformly over the grid range; the neutron gets +* v_perp -= Q*K2V and vz = sqrt(vi^2 - vx^2 - vy^2) (elastic). The weight is the +* bilinearly interpolated S(Qx,Qy) (no solid-angle Jacobian, as in mcvine.acc; +* use scattering_coefficient to set the absolute scale). File layout: first +* numeric row Qx values (nx, ascending), second row Qy values (ny), then ny rows of +* nx values (row index = Qy), i.e. the (y,x) image layout used by mcvine.acc. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Orientation: this process is anisotropic; its frame (Q vectors, reciprocal +* vectors, atom positions) follows the ROTATED placement of this component. +* The kernel code is shared with the standalone component MCViNE_SANS2D_ongrid (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_SANS2D_ongrid_process(S_QxQy="MCViNE/SANS2D_example.dat", scattering_coefficient=1) +* +* %P +* INPUT PARAMETERS: +* S_QxQy: [str] 2D grid file (see description) +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SANS2D_ongrid_process + +SETTING PARAMETERS (string S_QxQy=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_SANS2D_ongrid_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_SANS2D_ongrid kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + if (mcvine_grid2d_load_image (&kernel.m_S, S_QxQy, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Qx_min = kernel.m_S.x[0]; + kernel.m_Qx_max = kernel.m_S.x[kernel.m_S.nx - 1]; + kernel.m_Qy_min = kernel.m_S.y[0]; + kernel.m_Qy_max = kernel.m_S.y[kernel.m_S.ny - 1]; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_SANS2D_ongrid; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 1, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SQ.comp b/mcstas-comps/contrib/MCViNE_SQ.comp new file mode 100644 index 0000000000..c5e3f4d01d --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SQ.comp @@ -0,0 +1,134 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SQ +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SQkernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SQkernel.cc (+ GridSQ, SQ_fromexpression)) +* +* Elastic isotropic scatterer with structure factor S(|Q|) (expression or table). +* +* %D +* Elastic scattering with angular distribution given by S(|Q|), for liquids, +* glasses or powder-averaged diffuse scattering. S(Q) is either an expression in Q +* or a 2-column text file (Q [AA^-1], S), linearly interpolated (0 outside). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_SQ(SQ="1+sin(Q*3)/(Q*3)", Qmin=0, Qmax=20, scattering_coefficient=10, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* SQ: [str] S(Q) expression (ignored if SQ_file given) +* SQ_file: [str] 2-column file Q S +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SQ + +SETTING PARAMETERS (string SQ="1", string SQ_file=0, Qmin=0, Qmax=100, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_SQ kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_S, SQ, SQ_file, 2, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_SQ, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SQE.comp b/mcstas-comps/contrib/MCViNE_SQE.comp new file mode 100644 index 0000000000..5718b5ce5e --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SQE.comp @@ -0,0 +1,157 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SQE +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SQEkernel / SQE_EnergyFocusing_Kernel (+ SQE_fromexpression); MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SQEkernel.cc, SQE_EnergyFocusing_Kernel.cc) +* +* Isotropic S(Q,E) scatterer from an analytic expression or grid, with optional final-energy focusing. +* +* %D +* Isotropic (powder / liquid) S(|Q|,E). E is sampled uniformly in [Emin, min(Ei,Emax)] +* and |Q| uniformly in the kinematically allowed part of [Qmin,Qmax]. S(Q,E) is an +* expression in Q [AA^-1] and E [meV], or a grid file in the Isotropic_Sqw format +* (first numeric row: q values; second: energy values; then nq rows of nw values), +* bilinearly interpolated. For grid data McStas' Isotropic_Sqw already exists; the +* new parts are the analytic S(Q,E) and the energy focusing: when dEf>0, E is +* restricted so that Ef lies in [Ef-dEf, Ef+dEf] (MCViNE SQE_EnergyFocusing_Kernel). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_SQE(SQE="exp(-(E-10)^2/2)*Q^2*exp(-Q^2/4)", Qmin=0, Qmax=10, Emin=-5, Emax=30, sigma_scat=5, sigma_abs=0.5, Vc=50, radius=0.01, yheight=0.05) +* +* %P +* INPUT PARAMETERS: +* SQE: [str] S(Q,E) expression (ignored if SQE_file given) +* SQE_file: [str] S(q,w) grid file (Isotropic_Sqw layout) +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* Emin: [meV] Lower energy transfer bound +* Emax: [meV] Upper energy transfer bound +* Ef: [meV] Final-energy focusing centre (used when dEf>0) +* dEf: [meV] Final-energy focusing half range; 0 disables focusing +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SQE + +SETTING PARAMETERS (string SQE="1", string SQE_file=0, Qmin=0, Qmax=10, Emin=-10, Emax=10, Ef=0, dEf=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_SQE kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q", "E" }; + if (mcvine_func_setup (&kernel.m_S, SQE, SQE_file, 3, 2, vars, NAME_CURRENT_COMP)) + exit (-1); + if (SQE_file && SQE_file[0]) { + if (Qmin < kernel.m_S.g2.x[0]) + Qmin = kernel.m_S.g2.x[0]; + if (Qmax > kernel.m_S.g2.x[kernel.m_S.g2.nx - 1]) + Qmax = kernel.m_S.g2.x[kernel.m_S.g2.nx - 1]; + if (Emin < kernel.m_S.g2.y[0]) + Emin = kernel.m_S.g2.y[0]; + if (Emax > kernel.m_S.g2.y[kernel.m_S.g2.ny - 1]) + Emax = kernel.m_S.g2.y[kernel.m_S.g2.ny - 1]; + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_Emin = Emin; + kernel.m_Emax = Emax; + kernel.m_Ef = Ef; + kernel.m_dEf = dEf; + kernel.m_focusing = dEf > 0; + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_SQE, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SQE_process.comp b/mcstas-comps/contrib/MCViNE_SQE_process.comp new file mode 100644 index 0000000000..d84a0ce36c --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SQE_process.comp @@ -0,0 +1,139 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SQE_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SQEkernel / SQE_EnergyFocusing_Kernel (+ SQE_fromexpression); MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SQEkernel.cc, SQE_EnergyFocusing_Kernel.cc) +* +* Union process: Isotropic S(Q,E) scatterer from an analytic expression or grid, with optional final-energy focusing. +* +* %D +* Isotropic (powder / liquid) S(|Q|,E). E is sampled uniformly in [Emin, min(Ei,Emax)] +* and |Q| uniformly in the kinematically allowed part of [Qmin,Qmax]. S(Q,E) is an +* expression in Q [AA^-1] and E [meV], or a grid file in the Isotropic_Sqw format +* (first numeric row: q values; second: energy values; then nq rows of nw values), +* bilinearly interpolated. For grid data McStas' Isotropic_Sqw already exists; the +* new parts are the analytic S(Q,E) and the energy focusing: when dEf>0, E is +* restricted so that Ef lies in [Ef-dEf, Ef+dEf] (MCViNE SQE_EnergyFocusing_Kernel). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_SQE (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_SQE_process(SQE="exp(-(E-10)^2/2)*Q^2*exp(-Q^2/4)", Qmin=0, Qmax=10, Emin=-5, Emax=30, sigma_scat=5, Vc=50) +* +* %P +* INPUT PARAMETERS: +* SQE: [str] S(Q,E) expression (ignored if SQE_file given) +* SQE_file: [str] S(q,w) grid file (Isotropic_Sqw layout) +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* Emin: [meV] Lower energy transfer bound +* Emax: [meV] Upper energy transfer bound +* Ef: [meV] Final-energy focusing centre (used when dEf>0) +* dEf: [meV] Final-energy focusing half range; 0 disables focusing +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SQE_process + +SETTING PARAMETERS (string SQE="1", string SQE_file=0, Qmin=0, Qmax=10, Emin=-10, Emax=10, Ef=0, dEf=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_SQE_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_SQE kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q", "E" }; + if (mcvine_func_setup (&kernel.m_S, SQE, SQE_file, 3, 2, vars, NAME_CURRENT_COMP)) + exit (-1); + if (SQE_file && SQE_file[0]) { + if (Qmin < kernel.m_S.g2.x[0]) + Qmin = kernel.m_S.g2.x[0]; + if (Qmax > kernel.m_S.g2.x[kernel.m_S.g2.nx - 1]) + Qmax = kernel.m_S.g2.x[kernel.m_S.g2.nx - 1]; + if (Emin < kernel.m_S.g2.y[0]) + Emin = kernel.m_S.g2.y[0]; + if (Emax > kernel.m_S.g2.y[kernel.m_S.g2.ny - 1]) + Emax = kernel.m_S.g2.y[kernel.m_S.g2.ny - 1]; + } + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + kernel.m_Emin = Emin; + kernel.m_Emax = Emax; + kernel.m_Ef = Ef; + kernel.m_dEf = dEf; + kernel.m_focusing = dEf > 0; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_SQE; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SQ_process.comp b/mcstas-comps/contrib/MCViNE_SQ_process.comp new file mode 100644 index 0000000000..cd3e809d19 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SQ_process.comp @@ -0,0 +1,116 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SQ_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SQkernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SQkernel.cc (+ GridSQ, SQ_fromexpression)) +* +* Union process: Elastic isotropic scatterer with structure factor S(|Q|) (expression or table). +* +* %D +* Elastic scattering with angular distribution given by S(|Q|), for liquids, +* glasses or powder-averaged diffuse scattering. S(Q) is either an expression in Q +* or a 2-column text file (Q [AA^-1], S), linearly interpolated (0 outside). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Isotropic process (powder/liquid-like); rotation is irrelevant. +* The kernel code is shared with the standalone component MCViNE_SQ (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_SQ_process(SQ="1+sin(Q*3)/(Q*3)", Qmin=0, Qmax=20, scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* SQ: [str] S(Q) expression (ignored if SQ_file given) +* SQ_file: [str] 2-column file Q S +* Qmin: [AA^-1] Lower Q bound +* Qmax: [AA^-1] Upper Q bound +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SQ_process + +SETTING PARAMETERS (string SQ="1", string SQ_file=0, Qmin=0, Qmax=100, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_SQ_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_SQ kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Q" }; + if (mcvine_func_setup (&kernel.m_S, SQ, SQ_file, 2, 1, vars, NAME_CURRENT_COMP)) + exit (-1); + kernel.m_Qmin = Qmin; + kernel.m_Qmax = Qmax; + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_SQ; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 0, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SvQ.comp b/mcstas-comps/contrib/MCViNE_SvQ.comp new file mode 100644 index 0000000000..b524093cfb --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SvQ.comp @@ -0,0 +1,131 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SvQ +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SvQkernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SvQkernel.cc (+ GridSvQ)) +* +* Elastic scatterer with a vector structure factor S(Qx,Qy,Qz) (expression or 3D grid). +* +* %D +* Elastic scattering into a uniformly random direction, weighted by S(Q) with +* Q = ki - kf in the sample frame. S is either an expression in Qx,Qy,Qz or a 3D +* grid file: three rows 'min max n' for Qx, Qy, Qz followed by nx*ny*nz values +* (Qx slowest, Qz fastest), trilinearly interpolated (0 outside). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Transport (same as MCViNE HomogeneousNeutronScatterer): on the first +* passage the neutron is forced to scatter at a uniformly chosen depth, weighted +* by path length, attenuation exp(-(mu+sigma)x) and the scattering coefficient; +* on exit it is attenuated by exp(-(mu+sigma)L_out). With order>1 further +* scatterings are sampled analogically (truncated exponential). With +* p_transmit>0 that fraction of events is kept as the attenuated direct beam. +* mu(v) = absorption_coefficient*2200/v. Events for which the kernel cannot +* scatter (kinematically forbidden) are absorbed. +* +* Geometry: box (xwidth,yheight,zdepth), cylinder (radius,yheight), hollow +* cylinder (+thickness) or sphere (radius only). All vectors (Q, targets, +* reciprocal vectors, atom positions) are in the component's local frame. +* +* Uses the shared runtime share/mcvine-lib.h/.c. +* +* Example: MCViNE_SvQ(SvQ="exp(-((Qx-1)^2+Qy^2+Qz^2)/0.01)", scattering_coefficient=10, xwidth=0.01, yheight=0.01, zdepth=0.01) +* +* %P +* INPUT PARAMETERS: +* SvQ: [str] S(Qx,Qy,Qz) expression (ignored if SvQ_file given) +* SvQ_file: [str] 3D grid file (see description) +* absorption_coefficient: [m^-1] Absorption coefficient at 2200 m/s (MCViNE convention; scales as 1/v) +* scattering_coefficient: [m^-1] Scattering coefficient +* sigma_abs: [barn] Alternative: absorption cross section per unit cell at 2200 m/s (used when Vc>0) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0, coefficients are computed from sigma_abs, sigma_scat +* radius: [m] Outer radius of a cylinder (with yheight) or of a sphere (yheight=0) +* xwidth: [m] Width of a box sample +* yheight: [m] Height of a box or cylinder sample +* zdepth: [m] Depth of a box sample +* thickness: [m] Wall thickness of a hollow cylinder (0: filled) +* pack: [1] Packing factor (scales absorption and scattering coefficients) +* p_transmit: [1] Monte Carlo fraction of events kept as unscattered transmitted beam (0: always scatter) +* order: [1] Maximum number of scattering events per neutron (1: single scattering) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SvQ + +SETTING PARAMETERS (string SvQ="1", string SvQ_file=0, absorption_coefficient=0, scattering_coefficient=0, sigma_abs=0, sigma_scat=0, Vc=0, radius=0, xwidth=0, yheight=0, zdepth=0, thickness=0, pack=1, p_transmit=0, int order=1) + +NOACC + +SHARE +%{ +%include "read_table-lib" +%include "mcvine-lib" +%} + +DECLARE +%{ + mcvine_kernel_SvQ kernel; + mcvine_scatterer scatterer; +%} + +INITIALIZE +%{ + mcvine_shape shape; + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Qx", "Qy", "Qz" }; + if (mcvine_func_setup (&kernel.m_S, SvQ, SvQ_file, 4, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + + if (Vc > 0) { + mu = mcvine_xs2coeff (sigma_abs, Vc); + sig = mcvine_xs2coeff (sigma_scat, Vc); + } else { + mu = absorption_coefficient; + sig = scattering_coefficient; + } + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + if (mcvine_shape_init (&shape, radius, xwidth, yheight, zdepth, thickness, NAME_CURRENT_COMP)) + exit (-1); + mcvine_scatterer_init (&scatterer, &shape, mu, sig, pack, p_transmit, order); +%} + +TRACE +%{ + int ret = mcvine_scatterer_interact (&scatterer, &kernel, mcvine_S_SvQ, _particle); + if (ret < 0) + ABSORB; + if (ret > 0) + SCATTER; +%} + +MCDISPLAY +%{ + if (scatterer.shape.type == MCVINE_SHAPE_BOX) { + box (0, 0, 0, xwidth, yheight, zdepth, 0, 0, 1, 0); + } else if (scatterer.shape.type == MCVINE_SHAPE_CYLINDER) { + cylinder (0, 0, 0, radius, yheight, 0, 0, 1, 0); + if (thickness > 0) + cylinder (0, 0, 0, radius - thickness, yheight, 0, 0, 1, 0); + } else { + sphere (0, 0, 0, radius); + } +%} + +END diff --git a/mcstas-comps/contrib/MCViNE_SvQ_process.comp b/mcstas-comps/contrib/MCViNE_SvQ_process.comp new file mode 100644 index 0000000000..1352f162f5 --- /dev/null +++ b/mcstas-comps/contrib/MCViNE_SvQ_process.comp @@ -0,0 +1,114 @@ +/******************************************************************************* +* +* McStas, neutron ray-tracing package +* +* Component: MCViNE_SvQ_process +* +* %I +* Written by: Fahima Islam (McStas port of the MCViNE SvQkernel; MCViNE by J. Y. Y. Lin et al.) +* Date: 2026-09-29 +* Origin: MCViNE, https://github.com/mcvine/mcvine (mccomponents/lib/kernels/sample/SvQkernel.cc (+ GridSvQ)) +* +* Union process: Elastic scatterer with a vector structure factor S(Qx,Qy,Qz) (expression or 3D grid). +* +* %D +* Elastic scattering into a uniformly random direction, weighted by S(Q) with +* Q = ki - kf in the sample frame. S is either an expression in Qx,Qy,Qz or a 3D +* grid file: three rows 'min max n' for Qx, Qy, Qz followed by nx*ny*nz values +* (Qx slowest, Qz fastest), trilinearly interpolated (0 outside). +* +* Functions are given as strings evaluated at run time (MCViNE uses fparser): +* + - * / ^ (or **), % , comparisons, && ||, if(c,a,b), sin cos tan asin acos +* atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt, +* pow atan2 min max hypot fmod, constants pi and e. +* +* Union process. Part of the Union components: define this process, collect it +* into a material with Union_make_material (absorption is set there with +* my_absorption, the absorption inverse penetration depth at 2200 m/s), assign +* the material to Union_box/Union_cylinder/Union_sphere/Union_mesh geometries, +* and add a Union_master after them. Geometry, attenuation and multiple +* scattering are handled by Union_master; this component provides the MCViNE +* kernel: the scattering coefficient and the final-state sampling (weight). +* Orientation: this process is anisotropic; its frame (Q vectors, reciprocal +* vectors, atom positions) follows the ROTATED placement of this component. +* The kernel code is shared with the standalone component MCViNE_SvQ (mcvine-lib.c). +* Uses share/mcvine-lib.h/.c and share/mcvine-union-lib.h/.c; the Union core +* registers the process type MCViNE (share/union-lib.c, share/union-suffix.c). +* +* Example: MCViNE_SvQ_process(SvQ="exp(-((Qx-1)^2+Qy^2+Qz^2)/0.01)", scattering_coefficient=10) +* +* %P +* INPUT PARAMETERS: +* SvQ: [str] S(Qx,Qy,Qz) expression (ignored if SvQ_file given) +* SvQ_file: [str] 3D grid file (see description) +* scattering_coefficient: [m^-1] Scattering coefficient (inverse penetration depth for scattering) +* sigma_scat: [barn] Alternative: scattering cross section per unit cell (used when Vc>0) +* Vc: [AA^3] Unit cell volume; when >0 the coefficient is sigma_scat/Vc +* packing_factor: [1] Packing factor (scales the scattering coefficient) +* interact_fraction: [1] Union: fraction of interactions forced to this process (-1: by cross section) +* +* %L +* MCViNE documentation: https://mcvine.github.io +* +* %E +*******************************************************************************/ + +DEFINE COMPONENT MCViNE_SvQ_process + +SETTING PARAMETERS (string SvQ="1", string SvQ_file=0, scattering_coefficient=0, sigma_scat=0, Vc=0, packing_factor=1, interact_fraction=-1) + +NOACC + +SHARE +%{ + #ifndef Union + #error "ERROR: MCViNE_SvQ_process requires the Union library. Add a Union_master component to load the libraries." + #endif + %include "read_table-lib" + %include "mcvine-lib" + %include "mcvine-union-lib" + #ifndef PROCESS_DETECTOR + #define PROCESS_DETECTOR dummy + #endif + #ifndef PROCESS_MCVINE_DETECTOR + #define PROCESS_MCVINE_DETECTOR dummy + #endif +%} + +DECLARE +%{ + mcvine_kernel_SvQ kernel; + struct MCViNE_physics_storage_struct storage; + struct scattering_process_struct This_process; + struct global_process_element_struct global_process_element; +%} + +INITIALIZE +%{ + double mu = 0, sig = 0; + memset (&kernel, 0, sizeof (kernel)); + const char* vars[] = { "Qx", "Qy", "Qz" }; + if (mcvine_func_setup (&kernel.m_S, SvQ, SvQ_file, 4, 3, vars, NAME_CURRENT_COMP)) + exit (-1); + + if (Vc > 0) + sig = mcvine_xs2coeff (sigma_scat, Vc); + else + sig = scattering_coefficient; + if (!(sig > 0)) { + fprintf (stderr, "%s: give scattering_coefficient>0 (or sigma_scat>0 and Vc>0)\n", NAME_CURRENT_COMP); + exit (-1); + } + storage.m_kernel = &kernel; + storage.m_S = mcvine_S_SvQ; + storage.m_my_scattering = sig * packing_factor; + storage.m_kind = MCVINE_UNION_GENERIC; + mcvine_union_register (&This_process, &global_process_element, &storage, NAME_CURRENT_COMP, INDEX_CURRENT_COMP, interact_fraction, 1, ROT_A_CURRENT_COMP); +%} + +TRACE +%{ + // the simulation is done in Union_master +%} + +END diff --git a/mcstas-comps/contrib/doc/MCViNE_kernels.md b/mcstas-comps/contrib/doc/MCViNE_kernels.md new file mode 100644 index 0000000000..892f879a1d --- /dev/null +++ b/mcstas-comps/contrib/doc/MCViNE_kernels.md @@ -0,0 +1,167 @@ +# MCViNE sample kernels in McStas + +This note documents the McStas components ported from the sample scattering kernels of MCViNE (https://github.com/mcvine/mcvine, mccomponents/lib/kernels/sample, and the SANS2D_ongrid kernel of https://github.com/mcvine/acc). + +Each kernel comes in two forms that run the same kernel code (`share/mcvine-lib.c`): + +- **Union process** `contrib/MCViNE__process.comp`: geometry, containers, absorption and multiple scattering are handled by Union (`Union_make_material`, `Union_box/cylinder/sphere/mesh`, `Union_master`). +- **Standalone sample** `contrib/MCViNE_.comp`: a box, (hollow) cylinder or sphere with its own ray tracing (MCViNE's HomogeneousNeutronScatterer). + +Test instruments: `examples/Tests_samples/Test_MCViNE_/`. Each runs the same sample either as the Union process (`comp_select=1`) or as the standalone component (`comp_select=2`), so the two `%Example` values can be compared directly. Test data is in `data/MCViNE/`. + +## 1. Kernels and their McStas status + +| MCViNE kernel | Closest McStas component(s) | Status | Port | +|---|---|---|---| +| IsotropicKernel | `Incoherent`, `Isotropic_Sqw` (no S(q,w) file) | covered | – | +| SQEkernel + GridSQE | `Isotropic_Sqw` | covered | (also in `MCViNE_SQE`) | +| SimplePowderDiffractionKernel | `PowderN`, `Powder1`, Union `Powder_process` | covered | – | +| SingleCrystalDiffractionKernel | `Single_crystal`, Union `Single_crystal_process` | covered | – | +| SANSSpheresKernel, SANSSphereModelKernel | `Sans_spheres`, `SANS_spheres2`, SasView models | covered | – | +| MultiPhonon_Kernel (S(Q,E) from DOS → SQEkernel) | Union `IncoherentPhonon_process`, `NCrystal_sample` | covered | – | +| ConstantEnergyTransferKernel | none (`Res_sample` is a uniform band) | **missing** | `MCViNE_ConstantEnergyTransfer` | +| ConstantQEKernel | none (`Spot_sample` fixes 2θ, not \|Q\|) | **missing** | `MCViNE_ConstantQE` | +| ConstantvQEKernel | none | **missing** | `MCViNE_ConstantvQE` | +| E_Q_Kernel (analytic E(\|Q\|), S(Q)) | none | **missing** | `MCViNE_E_Q` | +| Broadened_E_Q_Kernel (Gaussian) | none | **missing** | `MCViNE_Broadened_E_Q` | +| LorentzianBroadened_E_Q_Kernel | none | **missing** | `MCViNE_LorentzianBroadened_E_Q` | +| E_vQ_Kernel (analytic E(**Q**), S(**Q**)) | only fixed models (`Phonon_simple`, `Magnon_bcc`, `SpinWave_BCO`, `Phonon_BvK_PG`) or 4D grids (`Single_crystal_inelastic`) | **missing** | `MCViNE_E_vQ` | +| SQkernel (+ GridSQ / SQ_fromexpression) | none (elastic isotropic S(\|Q\|)) | **missing** | `MCViNE_SQ` | +| SvQkernel (+ GridSvQ) | none (elastic S(**Q**)) | **missing** | `MCViNE_SvQ` | +| SQE_fromexpression, SQE_EnergyFocusing_Kernel | `Isotropic_Sqw` has neither analytic S nor Ef focusing | **missing** | `MCViNE_SQE` | +| DGSSXResKernel | `TOFRes_sample` (same idea, different weighting) | partial | `MCViNE_DGSSXRes` | +| phonon IncoherentElastic (Debye–Waller) | `Incoherent` (no DW); NCrystal | partial | `MCViNE_Phonon_IncoherentElastic` | +| phonon IncoherentInelastic (+ EnergyFocusing) | Union `IncoherentPhonon_process`, NCrystal (not standalone one-phonon, no Ef focusing) | partial | `MCViNE_Phonon_IncoherentInelastic` | +| phonon CoherentInelastic_PolyXtal (dispersion + polarizations on grid) | none | **missing** | `MCViNE_Phonon_CoherentInelastic_PolyXtal` | +| phonon CoherentInelastic_SingleXtal (dispersion + polarizations on grid) | `Single_crystal_inelastic` needs a precomputed 4D S(q,w), not eigenvectors | **missing** | `MCViNE_Phonon_CoherentInelastic_SingleXtal` | +| SANS2D_ongrid (mcvine/acc) | none (McStas SANS components are isotropic in \|Q\|) | **missing** | `MCViNE_SANS2D_ongrid` | +| EPSCDiffractionKernel | – | not ported: unfinished in MCViNE (the .cc contains stray Python and is not in the CMake build) | – | + + +## 2. Files + +| Location | Content | +|---|---| +| `share/mcvine-lib.h/.c` | kernel physics, run-time expression evaluator, table/grid readers, DOS and Debye–Waller helpers, MCViNE IDF phonon readers, shapes and standalone transport | +| `share/mcvine-union-lib.h/.c` | Union glue: a single process type `MCViNE` used by all kernels | +| `share/union-lib.c`, `share/union-suffix.c` | registration of the `MCViNE` process type (enum entry, `data_transfer_union` member, two dispatch cases) | +| `contrib/MCViNE_*_process.comp` | 16 Union processes | +| `contrib/MCViNE_*.comp` | 16 standalone samples | +| `examples/Tests_samples/Test_MCViNE_*` | 16 test instruments (Union and standalone) | +| `data/MCViNE/` | test inputs: toy fcc phonon IDF set and atoms file, Debye DOS, S(q,w) grid, SANS map | + +All components are `NOACC` (CPU only). + +## 3. Using the Union processes + +``` +COMPONENT phon = MCViNE_Phonon_CoherentInelastic_SingleXtal_process( + idf_dir="MCViNE/fcc_toy_phonons", atoms="MCViNE/fcc_toy_atoms.dat", T=300) + AT (0,0,0) ABSOLUTE ROTATED (0, 30, 0) ABSOLUTE // crystal orientation +COMPONENT mat = Union_make_material(my_absorption=1.39, process_string="phon") AT (0,0,0) ABSOLUTE +COMPONENT samp = Union_box(xwidth=0.01, yheight=0.01, zdepth=0.01, priority=1, material_string="mat") AT (0,0,5) ABSOLUTE +COMPONENT master = Union_master() AT (0,0,5) ABSOLUTE +``` + +- **Absorption** is a material property: `Union_make_material(my_absorption=...)` (inverse penetration depth at 2200 m/s). The coherent phonon processes print the value implied by their atoms file. +- **Parameters:** processes take `packing_factor` and `interact_fraction` like the other Union processes, and `scattering_coefficient` [1/m] or `sigma_scat` [barn] with `Vc` [ų] (phonon kernels: `sigma_inc` and `Vc`, or the atoms file). +- **Orientation:** the anisotropic kernels (ConstantvQE, E_vQ, SvQ, SANS2D_ongrid, CoherentInelastic_SingleXtal) follow the ROTATED placement of the process component, as `Single_crystal_process` does. +- **DGSSXRes** aims with the Union focusing of the geometry (`target_index` or `target_x/y/z`, and `focus_r`, `focus_xw/focus_xh` or `focus_aw/focus_ah`). The other kernels sample their own final directions, as in MCViNE. + +### Implementation note on the Union core + +Union selects the physics functions with a `switch` on `enum process` (no function pointers, for GPU builds). One new entry, `MCViNE`, is added. Its storage struct carries a pointer to the kernel and to its sampling function, so further MCViNE kernels can be added without touching the Union core again. The change adds 12 lines (`share/union-lib.c`: enum entry and union member; `share/union-suffix.c`: two `case MCViNE:` blocks guarded by `PROCESS_MCVINE_DETECTOR`) and does not affect existing processes. + +## 4. Standalone components: transport, expressions and data formats + +- **Geometry:** box (`xwidth,yheight,zdepth`), cylinder (`radius,yheight`), hollow cylinder (+`thickness`), or sphere (`radius`). Q vectors, targets, reciprocal vectors and atom positions are in the component frame; rotate the component to orient a crystal. +- **Cross sections:** `absorption_coefficient` (at 2200 m/s) and `scattering_coefficient` in 1/m, as in MCViNE, or `sigma_abs`, `sigma_scat` [barn] with `Vc` [ų]. +- **Transport:** forced scattering at a uniformly chosen depth, weighted by `L·exp(-(μ+σ)x)·σ` and the exit attenuation, exactly like MCViNE's `interact_path1`. `p_transmit` keeps a fraction as attenuated direct beam, `order>1` adds further (analog) scatterings, and `pack` scales μ and σ. + +### Expressions + +`E_Q`, `S_Q`, `sigma_Q`, `gamma_Q`, `SQ`, `SvQ` and `SQE` are strings evaluated at run time, like MCViNE's fparser. The supported syntax is: +- operators `+ - * / ^ ** %`, comparisons, `&& ||` +- `if(c,a,b)` +- functions `sin cos tan asin acos atan sinh cosh tanh exp log log10 log2 sqrt abs floor ceil int sign cbrt pow atan2 min max hypot fmod` +- constants `pi`, `e` + +The variables are `Q` (Å⁻¹), `E` (meV), and `Qx Qy Qz`. + +### Data formats + +- **S(Q) table:** two columns, Q and S. +- **S(Q,E) grid:** the `Isotropic_Sqw` layout: a row of q values, a row of ω values, then nq rows of nω values. +- **S(**Q**) grid:** three rows of `min max n`, then nx·ny·nz values with Qx slowest. +- **SANS2D map:** a row of Qx, a row of Qy, then ny rows of nx values. +- **DOS:** two ASCII columns, E [meV] and g. A `#...THz` comment switches the energy unit to THz. The MCViNE IDF binary `DOS` file is also read. +- **Phonons:** an MCViNE IDF directory containing `Qgridinfo`, `Omega2`, `Polarizations` and optionally `DOS`, e.g. from phonopy through MCViNE's tools. It needs an atoms file with columns `x y z [Å] mass [amu] b_coh [fm] σ_inc σ_abs [barn]`, in the same atom order as the IDF files. + + +## 5. Where the port differs from MCViNE + +1. **Kinematically forbidden events are absorbed.** In MCViNE, the neutron carries on unchanged but keeps the scattering weight. +2. **Grids are interpolated.** Grids are point values with linear, bilinear or trilinear interpolation, and give 0 outside the grid. MCViNE's `Grid*` functors use nearest-bin lookup and throw an error out of range. +3. **Three MCViNE sampling loops are biased, and each has an `unbiased=1` switch.** The default (`unbiased=0`) reproduces MCViNE: + - **E_Q:** retries and divides the weight by the number of attempts, which is about +1.7 % in the test below. + - **Broadened / Lorentzian E_Q:** retry without an acceptance correction. + - **CoherentInelastic_SingleXtal:** retries directions until a root exists. The error was small in the tests. + - **CoherentInelastic_PolyXtal:** uses an empirical accessible-volume formula, which comes out about +8 % in the tests. +4. **PolyXtal ×2 factor:** the factor for "two choices of E_f" now tests Ei against the phonon energy. MCViNE tests it against the signed energy transfer, which doubles the weight even when only annihilation is possible. +5. **SANS2D_ongrid:** the port uses vz = √(vi² − vx² − vy²). mcvine/acc has `vx²·vy²` there, which is a bug. +6. **b_coh** is read with its sign from the atoms file. MCViNE derives |b| from σ_coh using `periodictable`. +7. **Multiple scattering:** MCViNE splits each event into transmitted, absorbed and scattered copies (`mcweights`, default 1:1:1). McStas can't split events, so the absorbed branch is folded into the weight and further scatterings are sampled analogically. The expected values are the same. + + +## 6. Validation + +Scripts (attached to the pull request) built dedicated test instruments and compare the ports against analytic integrals, McStas's own components, or independent Python calculations. Ratios are relative to McStas `Incoherent` with the same σ, and ± is the Monte Carlo statistical error. + +| Test | Result | Expected | +|---|---|---| +| SQ, S=1 vs `Incoherent` | 1.0008 ± 0.0024 | 1 | +| SQ, S=Q² (expression / table) | 57.89 ± 0.17 / 58.04 ± 0.17 | 57.91 (=2ki²) | +| E_Q, MCViNE mode / unbiased | 0.8735 / 0.8593 ± 0.0021 | 0.8734 (MCViNE algorithm) / 0.8587 (exact) | +| Broadened σ=3, Lorentzian γ=1 (unbiased) | 0.8537 / 0.8443 | 0.8541 / 0.8434 (2D quadrature) | +| ConstantEnergyTransfer, ConstantQE | 1.0000, 0.9995; E and \|Q\| exact to 1e-7 | 1 | +| E_vQ with flat E=15 | 0.8660 ± 0.0019 | √(45/60)=0.8660 | +| E_vQ, dispersive | max \|E−E(**Q**)\| = 7e-6 meV | 0 | +| SvQ, S=Qx² (expression / 3D grid) | 9.658 / 9.673 ± 0.026 | ki²/3 = 9.652 | +| SQE (expression / grid / Ef focusing) | 2.761 / 2.729 / 2.396 | 2.769 / 2.769 / 2.402 | +| Phonon IncoherentElastic, DW core from DOS | 0.004309 Ų | 0.004316 Ų (independent quadrature) | +| Phonon IncoherentInelastic, Debye DOS (plain / Ef focusing) | 0.1543 / 0.0130 | 0.1544 / 0.0130 | +| CoherentInelastic_SingleXtal, fixed orientation | 0.214 (grid kinematics: median 0.06 meV) | 0.207 (independent Python, exact eigenvectors) | +| CoherentInelastic_PolyXtal (unbiased / MCViNE mode) | 0.226 / 0.246 | ≈ incoherent approximation 0.247; average of 24 orientations 0.21 | +| DGSSXRes | arrival times within ±1.00e-5 s of target; angle 60.00° | ±1e-5 s | +| Transport, order=1 (cylinder / box / sphere) | = `Incoherent` within 0.3 % | | +| Transport, hollow cylinder | 0.18657 | 0.18659 (independent) | +| Transport, sphere order=2 | 0.4512 | 0.4520 (analog MC) | +| p_transmit | transmitted 0.5335 | exp(−μL) = 0.5327 | + +### Union processes vs standalone components + +A second set compared each process with its standalone component. Both use the same cylinder (r=5 mm, h=10 mm) and absorption, with full multiple scattering: Union_master on one side and `order=20` on the other. The table shows the scattered intensity ratio and the weighted mean E and |Q| of the scattered neutrons. + +| Kernel | I_union / I_standalone | ⟨E⟩ standalone / Union (meV) | ⟨\|Q\|⟩ standalone / Union (Å⁻¹) | +|---|---|---|---| +| ConstantEnergyTransfer | 1.003 ± 0.004 | 15.71 / 15.72 | 6.714 / 6.707 | +| ConstantQE | 0.999 ± 0.004 | 15.76 / 15.77 | 4.045 / 4.045 | +| ConstantvQE | 0.999 ± 0.008 | 33.72 / 33.72 | 2.291 / 2.291 | +| E_Q | 0.998 ± 0.009 | 11.07 / 11.02 | 6.698 / 6.673 | +| Broadened_E_Q | 1.000 ± 0.009 | 11.06 / 11.13 | 6.693 / 6.708 | +| LorentzianBroadened_E_Q | 1.000 ± 0.008 | 10.33 / 10.30 | 6.671 / 6.676 | +| E_vQ | 0.979 ± 0.027 | 34.74 / 35.06 | 6.108 / 6.091 | +| SQ | 1.000 ± 0.005 | 0 / 0 | 7.127 / 7.131 | +| SvQ | 1.001 ± 0.004 | 0 / 0 | 7.153 / 7.157 | +| SQE (grid) | 0.964 ± 0.037 | 11.86 / 11.48 | 3.923 / 3.889 | +| SANS2D_ongrid | 0.996 ± 0.007 | 0 / 0 | 0.123 / 0.123 | +| Phonon_IncoherentElastic | 0.995 ± 0.009 | 0 / 0 | 6.366 / 6.378 | +| Phonon_IncoherentInelastic | 0.995 ± 0.004 | 1.77 / 1.75 | 8.250 / 8.246 | +| Phonon_CoherentInelastic_PolyXtal | 0.995 ± 0.022 | 3.53 / 3.41 | 7.943 / 7.893 | +| Phonon_CoherentInelastic_SingleXtal | 1.023 ± 0.102 | 3.19 / 2.80 | 7.920 / 8.011 | + +With the process rotated 30° about y, ConstantvQE gives 1.003 ± 0.006 and the same mean final velocity vector to 0.1 m/s. SvQ and SingleXtal agree within their (large) errors. DGSSXRes with Union geometry focusing gives 1.003 ± 0.006, with the same mean final velocity as the standalone target. + +McStas `Incoherent` disagrees for two cases. For a hollow cylinder, its hole has closed ends. With `order=2` it overshoots the analog-MC value, so it can't be used as the reference there. + +The phonon test data is a toy fcc nearest-neighbour Born–von Kármán model, not real Al. `data/MCViNE/make_fcc_toy_phonons.py` regenerates it. diff --git a/mcstas-comps/data/MCViNE/Debye_dos.dat b/mcstas-comps/data/MCViNE/Debye_dos.dat new file mode 100644 index 0000000000..9623223c9c --- /dev/null +++ b/mcstas-comps/data/MCViNE/Debye_dos.dat @@ -0,0 +1,1003 @@ +# Debye phonon DOS g(E)=3E^2/E_D^3, E_D = 40 meV (test data for MCViNE_Phonon_* components) +# E [meV] g [1/meV] +0 0 +0.04 7.5e-08 +0.08 3e-07 +0.12 6.75e-07 +0.16 1.2e-06 +0.2 1.875e-06 +0.24 2.7e-06 +0.28 3.675e-06 +0.32 4.8e-06 +0.36 6.075e-06 +0.4 7.5e-06 +0.44 9.075e-06 +0.48 1.08e-05 +0.52 1.2675e-05 +0.56 1.47e-05 +0.6 1.6875e-05 +0.64 1.92e-05 +0.68 2.1675e-05 +0.72 2.43e-05 +0.76 2.7075e-05 +0.8 3e-05 +0.84 3.3075e-05 +0.88 3.63e-05 +0.92 3.9675e-05 +0.96 4.32e-05 +1 4.6875e-05 +1.04 5.07e-05 +1.08 5.4675e-05 +1.12 5.88e-05 +1.16 6.3075e-05 +1.2 6.75e-05 +1.24 7.2075e-05 +1.28 7.68e-05 +1.32 8.1675e-05 +1.36 8.67e-05 +1.4 9.1875e-05 +1.44 9.72e-05 +1.48 0.000102675 +1.52 0.0001083 +1.56 0.000114075 +1.6 0.00012 +1.64 0.000126075 +1.68 0.0001323 +1.72 0.000138675 +1.76 0.0001452 +1.8 0.000151875 +1.84 0.0001587 +1.88 0.000165675 +1.92 0.0001728 +1.96 0.000180075 +2 0.0001875 +2.04 0.000195075 +2.08 0.0002028 +2.12 0.000210675 +2.16 0.0002187 +2.2 0.000226875 +2.24 0.0002352 +2.28 0.000243675 +2.32 0.0002523 +2.36 0.000261075 +2.4 0.00027 +2.44 0.000279075 +2.48 0.0002883 +2.52 0.000297675 +2.56 0.0003072 +2.6 0.000316875 +2.64 0.0003267 +2.68 0.000336675 +2.72 0.0003468 +2.76 0.000357075 +2.8 0.0003675 +2.84 0.000378075 +2.88 0.0003888 +2.92 0.000399675 +2.96 0.0004107 +3 0.000421875 +3.04 0.0004332 +3.08 0.000444675 +3.12 0.0004563 +3.16 0.000468075 +3.2 0.00048 +3.24 0.000492075 +3.28 0.0005043 +3.32 0.000516675 +3.36 0.0005292 +3.4 0.000541875 +3.44 0.0005547 +3.48 0.000567675 +3.52 0.0005808 +3.56 0.000594075 +3.6 0.0006075 +3.64 0.000621075 +3.68 0.0006348 +3.72 0.000648675 +3.76 0.0006627 +3.8 0.000676875 +3.84 0.0006912 +3.88 0.000705675 +3.92 0.0007203 +3.96 0.000735075 +4 0.00075 +4.04 0.000765075 +4.08 0.0007803 +4.12 0.000795675 +4.16 0.0008112 +4.2 0.000826875 +4.24 0.0008427 +4.28 0.000858675 +4.32 0.0008748 +4.36 0.000891075 +4.4 0.0009075 +4.44 0.000924075 +4.48 0.0009408 +4.52 0.000957675 +4.56 0.0009747 +4.6 0.000991875 +4.64 0.0010092 +4.68 0.00102667 +4.72 0.0010443 +4.76 0.00106207 +4.8 0.00108 +4.84 0.00109808 +4.88 0.0011163 +4.92 0.00113467 +4.96 0.0011532 +5 0.00117187 +5.04 0.0011907 +5.08 0.00120968 +5.12 0.0012288 +5.16 0.00124807 +5.2 0.0012675 +5.24 0.00128708 +5.28 0.0013068 +5.32 0.00132668 +5.36 0.0013467 +5.4 0.00136688 +5.44 0.0013872 +5.48 0.00140768 +5.52 0.0014283 +5.56 0.00144908 +5.6 0.00147 +5.64 0.00149107 +5.68 0.0015123 +5.72 0.00153367 +5.76 0.0015552 +5.8 0.00157687 +5.84 0.0015987 +5.88 0.00162067 +5.92 0.0016428 +5.96 0.00166507 +6 0.0016875 +6.04 0.00171007 +6.08 0.0017328 +6.12 0.00175568 +6.16 0.0017787 +6.2 0.00180188 +6.24 0.0018252 +6.28 0.00184868 +6.32 0.0018723 +6.36 0.00189608 +6.4 0.00192 +6.44 0.00194408 +6.48 0.0019683 +6.52 0.00199268 +6.56 0.0020172 +6.6 0.00204188 +6.64 0.0020667 +6.68 0.00209167 +6.72 0.0021168 +6.76 0.00214207 +6.8 0.0021675 +6.84 0.00219308 +6.88 0.0022188 +6.92 0.00224467 +6.96 0.0022707 +7 0.00229687 +7.04 0.0023232 +7.08 0.00234968 +7.12 0.0023763 +7.16 0.00240307 +7.2 0.00243 +7.24 0.00245707 +7.28 0.0024843 +7.32 0.00251168 +7.36 0.0025392 +7.4 0.00256688 +7.44 0.0025947 +7.48 0.00262268 +7.52 0.0026508 +7.56 0.00267907 +7.6 0.0027075 +7.64 0.00273608 +7.68 0.0027648 +7.72 0.00279367 +7.76 0.0028227 +7.8 0.00285187 +7.84 0.0028812 +7.88 0.00291067 +7.92 0.0029403 +7.96 0.00297007 +8 0.003 +8.04 0.00303008 +8.08 0.0030603 +8.12 0.00309068 +8.16 0.0031212 +8.2 0.00315187 +8.24 0.0031827 +8.28 0.00321367 +8.32 0.0032448 +8.36 0.00327607 +8.4 0.0033075 +8.44 0.00333907 +8.48 0.0033708 +8.52 0.00340267 +8.56 0.0034347 +8.6 0.00346687 +8.64 0.0034992 +8.68 0.00353167 +8.72 0.0035643 +8.76 0.00359708 +8.8 0.00363 +8.84 0.00366308 +8.88 0.0036963 +8.92 0.00372968 +8.96 0.0037632 +9 0.00379687 +9.04 0.0038307 +9.08 0.00386468 +9.12 0.0038988 +9.16 0.00393308 +9.2 0.0039675 +9.24 0.00400207 +9.28 0.0040368 +9.32 0.00407168 +9.36 0.0041067 +9.4 0.00414188 +9.44 0.0041772 +9.48 0.00421267 +9.52 0.0042483 +9.56 0.00428408 +9.6 0.00432 +9.64 0.00435608 +9.68 0.0043923 +9.72 0.00442867 +9.76 0.0044652 +9.8 0.00450188 +9.84 0.0045387 +9.88 0.00457568 +9.92 0.0046128 +9.96 0.00465008 +10 0.0046875 +10.04 0.00472508 +10.08 0.0047628 +10.12 0.00480068 +10.16 0.0048387 +10.2 0.00487688 +10.24 0.0049152 +10.28 0.00495367 +10.32 0.0049923 +10.36 0.00503107 +10.4 0.00507 +10.44 0.00510907 +10.48 0.0051483 +10.52 0.00518767 +10.56 0.0052272 +10.6 0.00526687 +10.64 0.0053067 +10.68 0.00534667 +10.72 0.0053868 +10.76 0.00542707 +10.8 0.0054675 +10.84 0.00550807 +10.88 0.0055488 +10.92 0.00558967 +10.96 0.0056307 +11 0.00567187 +11.04 0.0057132 +11.08 0.00575468 +11.12 0.0057963 +11.16 0.00583807 +11.2 0.00588 +11.24 0.00592208 +11.28 0.0059643 +11.32 0.00600668 +11.36 0.0060492 +11.4 0.00609188 +11.44 0.0061347 +11.48 0.00617768 +11.52 0.0062208 +11.56 0.00626408 +11.6 0.0063075 +11.64 0.00635108 +11.68 0.0063948 +11.72 0.00643868 +11.76 0.0064827 +11.8 0.00652688 +11.84 0.0065712 +11.88 0.00661568 +11.92 0.0066603 +11.96 0.00670508 +12 0.00675 +12.04 0.00679508 +12.08 0.0068403 +12.12 0.00688568 +12.16 0.0069312 +12.2 0.00697688 +12.24 0.0070227 +12.28 0.00706868 +12.32 0.0071148 +12.36 0.00716108 +12.4 0.0072075 +12.44 0.00725407 +12.48 0.0073008 +12.52 0.00734767 +12.56 0.0073947 +12.6 0.00744187 +12.64 0.0074892 +12.68 0.00753667 +12.72 0.0075843 +12.76 0.00763208 +12.8 0.00768 +12.84 0.00772808 +12.88 0.0077763 +12.92 0.00782467 +12.96 0.0078732 +13 0.00792188 +13.04 0.0079707 +13.08 0.00801967 +13.12 0.0080688 +13.16 0.00811807 +13.2 0.0081675 +13.24 0.00821708 +13.28 0.0082668 +13.32 0.00831668 +13.36 0.0083667 +13.4 0.00841688 +13.44 0.0084672 +13.48 0.00851768 +13.52 0.0085683 +13.56 0.00861908 +13.6 0.00867 +13.64 0.00872108 +13.68 0.0087723 +13.72 0.00882368 +13.76 0.0088752 +13.8 0.00892688 +13.84 0.0089787 +13.88 0.00903068 +13.92 0.0090828 +13.96 0.00913508 +14 0.0091875 +14.04 0.00924008 +14.08 0.0092928 +14.12 0.00934568 +14.16 0.0093987 +14.2 0.00945188 +14.24 0.0095052 +14.28 0.00955868 +14.32 0.0096123 +14.36 0.00966607 +14.4 0.00972 +14.44 0.00977408 +14.48 0.0098283 +14.52 0.00988267 +14.56 0.0099372 +14.6 0.00999188 +14.64 0.0100467 +14.68 0.0101017 +14.72 0.0101568 +14.76 0.0102121 +14.8 0.0102675 +14.84 0.0103231 +14.88 0.0103788 +14.92 0.0104347 +14.96 0.0104907 +15 0.0105469 +15.04 0.0106032 +15.08 0.0106597 +15.12 0.0107163 +15.16 0.0107731 +15.2 0.01083 +15.24 0.0108871 +15.28 0.0109443 +15.32 0.0110017 +15.36 0.0110592 +15.4 0.0111169 +15.44 0.0111747 +15.48 0.0112327 +15.52 0.0112908 +15.56 0.0113491 +15.6 0.0114075 +15.64 0.0114661 +15.68 0.0115248 +15.72 0.0115837 +15.76 0.0116427 +15.8 0.0117019 +15.84 0.0117612 +15.88 0.0118207 +15.92 0.0118803 +15.96 0.0119401 +16 0.012 +16.04 0.0120601 +16.08 0.0121203 +16.12 0.0121807 +16.16 0.0122412 +16.2 0.0123019 +16.24 0.0123627 +16.28 0.0124237 +16.32 0.0124848 +16.36 0.0125461 +16.4 0.0126075 +16.44 0.0126691 +16.48 0.0127308 +16.52 0.0127927 +16.56 0.0128547 +16.6 0.0129169 +16.64 0.0129792 +16.68 0.0130417 +16.72 0.0131043 +16.76 0.0131671 +16.8 0.01323 +16.84 0.0132931 +16.88 0.0133563 +16.92 0.0134197 +16.96 0.0134832 +17 0.0135469 +17.04 0.0136107 +17.08 0.0136747 +17.12 0.0137388 +17.16 0.0138031 +17.2 0.0138675 +17.24 0.0139321 +17.28 0.0139968 +17.32 0.0140617 +17.36 0.0141267 +17.4 0.0141919 +17.44 0.0142572 +17.48 0.0143227 +17.52 0.0143883 +17.56 0.0144541 +17.6 0.01452 +17.64 0.0145861 +17.68 0.0146523 +17.72 0.0147187 +17.76 0.0147852 +17.8 0.0148519 +17.84 0.0149187 +17.88 0.0149857 +17.92 0.0150528 +17.96 0.0151201 +18 0.0151875 +18.04 0.0152551 +18.08 0.0153228 +18.12 0.0153907 +18.16 0.0154587 +18.2 0.0155269 +18.24 0.0155952 +18.28 0.0156637 +18.32 0.0157323 +18.36 0.0158011 +18.4 0.01587 +18.44 0.0159391 +18.48 0.0160083 +18.52 0.0160777 +18.56 0.0161472 +18.6 0.0162169 +18.64 0.0162867 +18.68 0.0163567 +18.72 0.0164268 +18.76 0.0164971 +18.8 0.0165675 +18.84 0.0166381 +18.88 0.0167088 +18.92 0.0167797 +18.96 0.0168507 +19 0.0169219 +19.04 0.0169932 +19.08 0.0170647 +19.12 0.0171363 +19.16 0.0172081 +19.2 0.01728 +19.24 0.0173521 +19.28 0.0174243 +19.32 0.0174967 +19.36 0.0175692 +19.4 0.0176419 +19.44 0.0177147 +19.48 0.0177877 +19.52 0.0178608 +19.56 0.0179341 +19.6 0.0180075 +19.64 0.0180811 +19.68 0.0181548 +19.72 0.0182287 +19.76 0.0183027 +19.8 0.0183769 +19.84 0.0184512 +19.88 0.0185257 +19.92 0.0186003 +19.96 0.0186751 +20 0.01875 +20.04 0.0188251 +20.08 0.0189003 +20.12 0.0189757 +20.16 0.0190512 +20.2 0.0191269 +20.24 0.0192027 +20.28 0.0192787 +20.32 0.0193548 +20.36 0.0194311 +20.4 0.0195075 +20.44 0.0195841 +20.48 0.0196608 +20.52 0.0197377 +20.56 0.0198147 +20.6 0.0198919 +20.64 0.0199692 +20.68 0.0200467 +20.72 0.0201243 +20.76 0.0202021 +20.8 0.02028 +20.84 0.0203581 +20.88 0.0204363 +20.92 0.0205147 +20.96 0.0205932 +21 0.0206719 +21.04 0.0207507 +21.08 0.0208297 +21.12 0.0209088 +21.16 0.0209881 +21.2 0.0210675 +21.24 0.0211471 +21.28 0.0212268 +21.32 0.0213067 +21.36 0.0213867 +21.4 0.0214669 +21.44 0.0215472 +21.48 0.0216277 +21.52 0.0217083 +21.56 0.0217891 +21.6 0.02187 +21.64 0.0219511 +21.68 0.0220323 +21.72 0.0221137 +21.76 0.0221952 +21.8 0.0222769 +21.84 0.0223587 +21.88 0.0224407 +21.92 0.0225228 +21.96 0.0226051 +22 0.0226875 +22.04 0.0227701 +22.08 0.0228528 +22.12 0.0229357 +22.16 0.0230187 +22.2 0.0231019 +22.24 0.0231852 +22.28 0.0232687 +22.32 0.0233523 +22.36 0.0234361 +22.4 0.02352 +22.44 0.0236041 +22.48 0.0236883 +22.52 0.0237727 +22.56 0.0238572 +22.6 0.0239419 +22.64 0.0240267 +22.68 0.0241117 +22.72 0.0241968 +22.76 0.0242821 +22.8 0.0243675 +22.84 0.0244531 +22.88 0.0245388 +22.92 0.0246247 +22.96 0.0247107 +23 0.0247969 +23.04 0.0248832 +23.08 0.0249697 +23.12 0.0250563 +23.16 0.0251431 +23.2 0.02523 +23.24 0.0253171 +23.28 0.0254043 +23.32 0.0254917 +23.36 0.0255792 +23.4 0.0256669 +23.44 0.0257547 +23.48 0.0258427 +23.52 0.0259308 +23.56 0.0260191 +23.6 0.0261075 +23.64 0.0261961 +23.68 0.0262848 +23.72 0.0263737 +23.76 0.0264627 +23.8 0.0265519 +23.84 0.0266412 +23.88 0.0267307 +23.92 0.0268203 +23.96 0.0269101 +24 0.027 +24.04 0.0270901 +24.08 0.0271803 +24.12 0.0272707 +24.16 0.0273612 +24.2 0.0274519 +24.24 0.0275427 +24.28 0.0276337 +24.32 0.0277248 +24.36 0.0278161 +24.4 0.0279075 +24.44 0.0279991 +24.48 0.0280908 +24.52 0.0281827 +24.56 0.0282747 +24.6 0.0283669 +24.64 0.0284592 +24.68 0.0285517 +24.72 0.0286443 +24.76 0.0287371 +24.8 0.02883 +24.84 0.0289231 +24.88 0.0290163 +24.92 0.0291097 +24.96 0.0292032 +25 0.0292969 +25.04 0.0293907 +25.08 0.0294847 +25.12 0.0295788 +25.16 0.0296731 +25.2 0.0297675 +25.24 0.0298621 +25.28 0.0299568 +25.32 0.0300517 +25.36 0.0301467 +25.4 0.0302419 +25.44 0.0303372 +25.48 0.0304327 +25.52 0.0305283 +25.56 0.0306241 +25.6 0.03072 +25.64 0.0308161 +25.68 0.0309123 +25.72 0.0310087 +25.76 0.0311052 +25.8 0.0312019 +25.84 0.0312987 +25.88 0.0313957 +25.92 0.0314928 +25.96 0.0315901 +26 0.0316875 +26.04 0.0317851 +26.08 0.0318828 +26.12 0.0319807 +26.16 0.0320787 +26.2 0.0321769 +26.24 0.0322752 +26.28 0.0323737 +26.32 0.0324723 +26.36 0.0325711 +26.4 0.03267 +26.44 0.0327691 +26.48 0.0328683 +26.52 0.0329677 +26.56 0.0330672 +26.6 0.0331669 +26.64 0.0332667 +26.68 0.0333667 +26.72 0.0334668 +26.76 0.0335671 +26.8 0.0336675 +26.84 0.0337681 +26.88 0.0338688 +26.92 0.0339697 +26.96 0.0340707 +27 0.0341719 +27.04 0.0342732 +27.08 0.0343747 +27.12 0.0344763 +27.16 0.0345781 +27.2 0.03468 +27.24 0.0347821 +27.28 0.0348843 +27.32 0.0349867 +27.36 0.0350892 +27.4 0.0351919 +27.44 0.0352947 +27.48 0.0353977 +27.52 0.0355008 +27.56 0.0356041 +27.6 0.0357075 +27.64 0.0358111 +27.68 0.0359148 +27.72 0.0360187 +27.76 0.0361227 +27.8 0.0362269 +27.84 0.0363312 +27.88 0.0364357 +27.92 0.0365403 +27.96 0.0366451 +28 0.03675 +28.04 0.0368551 +28.08 0.0369603 +28.12 0.0370657 +28.16 0.0371712 +28.2 0.0372769 +28.24 0.0373827 +28.28 0.0374887 +28.32 0.0375948 +28.36 0.0377011 +28.4 0.0378075 +28.44 0.0379141 +28.48 0.0380208 +28.52 0.0381277 +28.56 0.0382347 +28.6 0.0383419 +28.64 0.0384492 +28.68 0.0385567 +28.72 0.0386643 +28.76 0.0387721 +28.8 0.03888 +28.84 0.0389881 +28.88 0.0390963 +28.92 0.0392047 +28.96 0.0393132 +29 0.0394219 +29.04 0.0395307 +29.08 0.0396397 +29.12 0.0397488 +29.16 0.0398581 +29.2 0.0399675 +29.24 0.0400771 +29.28 0.0401868 +29.32 0.0402967 +29.36 0.0404067 +29.4 0.0405169 +29.44 0.0406272 +29.48 0.0407377 +29.52 0.0408483 +29.56 0.0409591 +29.6 0.04107 +29.64 0.0411811 +29.68 0.0412923 +29.72 0.0414037 +29.76 0.0415152 +29.8 0.0416269 +29.84 0.0417387 +29.88 0.0418507 +29.92 0.0419628 +29.96 0.0420751 +30 0.0421875 +30.04 0.0423001 +30.08 0.0424128 +30.12 0.0425257 +30.16 0.0426387 +30.2 0.0427519 +30.24 0.0428652 +30.28 0.0429787 +30.32 0.0430923 +30.36 0.0432061 +30.4 0.04332 +30.44 0.0434341 +30.48 0.0435483 +30.52 0.0436627 +30.56 0.0437772 +30.6 0.0438919 +30.64 0.0440067 +30.68 0.0441217 +30.72 0.0442368 +30.76 0.0443521 +30.8 0.0444675 +30.84 0.0445831 +30.88 0.0446988 +30.92 0.0448147 +30.96 0.0449307 +31 0.0450469 +31.04 0.0451632 +31.08 0.0452797 +31.12 0.0453963 +31.16 0.0455131 +31.2 0.04563 +31.24 0.0457471 +31.28 0.0458643 +31.32 0.0459817 +31.36 0.0460992 +31.4 0.0462169 +31.44 0.0463347 +31.48 0.0464527 +31.52 0.0465708 +31.56 0.0466891 +31.6 0.0468075 +31.64 0.0469261 +31.68 0.0470448 +31.72 0.0471637 +31.76 0.0472827 +31.8 0.0474019 +31.84 0.0475212 +31.88 0.0476407 +31.92 0.0477603 +31.96 0.0478801 +32 0.048 +32.04 0.0481201 +32.08 0.0482403 +32.12 0.0483607 +32.16 0.0484812 +32.2 0.0486019 +32.24 0.0487227 +32.28 0.0488437 +32.32 0.0489648 +32.36 0.0490861 +32.4 0.0492075 +32.44 0.0493291 +32.48 0.0494508 +32.52 0.0495727 +32.56 0.0496947 +32.6 0.0498169 +32.64 0.0499392 +32.68 0.0500617 +32.72 0.0501843 +32.76 0.0503071 +32.8 0.05043 +32.84 0.0505531 +32.88 0.0506763 +32.92 0.0507997 +32.96 0.0509232 +33 0.0510469 +33.04 0.0511707 +33.08 0.0512947 +33.12 0.0514188 +33.16 0.0515431 +33.2 0.0516675 +33.24 0.0517921 +33.28 0.0519168 +33.32 0.0520417 +33.36 0.0521667 +33.4 0.0522919 +33.44 0.0524172 +33.48 0.0525427 +33.52 0.0526683 +33.56 0.0527941 +33.6 0.05292 +33.64 0.0530461 +33.68 0.0531723 +33.72 0.0532987 +33.76 0.0534252 +33.8 0.0535519 +33.84 0.0536787 +33.88 0.0538057 +33.92 0.0539328 +33.96 0.0540601 +34 0.0541875 +34.04 0.0543151 +34.08 0.0544428 +34.12 0.0545707 +34.16 0.0546987 +34.2 0.0548269 +34.24 0.0549552 +34.28 0.0550837 +34.32 0.0552123 +34.36 0.0553411 +34.4 0.05547 +34.44 0.0555991 +34.48 0.0557283 +34.52 0.0558577 +34.56 0.0559872 +34.6 0.0561169 +34.64 0.0562467 +34.68 0.0563767 +34.72 0.0565068 +34.76 0.0566371 +34.8 0.0567675 +34.84 0.0568981 +34.88 0.0570288 +34.92 0.0571597 +34.96 0.0572907 +35 0.0574219 +35.04 0.0575532 +35.08 0.0576847 +35.12 0.0578163 +35.16 0.0579481 +35.2 0.05808 +35.24 0.0582121 +35.28 0.0583443 +35.32 0.0584767 +35.36 0.0586092 +35.4 0.0587419 +35.44 0.0588747 +35.48 0.0590077 +35.52 0.0591408 +35.56 0.0592741 +35.6 0.0594075 +35.64 0.0595411 +35.68 0.0596748 +35.72 0.0598087 +35.76 0.0599427 +35.8 0.0600769 +35.84 0.0602112 +35.88 0.0603457 +35.92 0.0604803 +35.96 0.0606151 +36 0.06075 +36.04 0.0608851 +36.08 0.0610203 +36.12 0.0611557 +36.16 0.0612912 +36.2 0.0614269 +36.24 0.0615627 +36.28 0.0616987 +36.32 0.0618348 +36.36 0.0619711 +36.4 0.0621075 +36.44 0.0622441 +36.48 0.0623808 +36.52 0.0625177 +36.56 0.0626547 +36.6 0.0627919 +36.64 0.0629292 +36.68 0.0630667 +36.72 0.0632043 +36.76 0.0633421 +36.8 0.06348 +36.84 0.0636181 +36.88 0.0637563 +36.92 0.0638947 +36.96 0.0640332 +37 0.0641719 +37.04 0.0643107 +37.08 0.0644497 +37.12 0.0645888 +37.16 0.0647281 +37.2 0.0648675 +37.24 0.0650071 +37.28 0.0651468 +37.32 0.0652867 +37.36 0.0654267 +37.4 0.0655669 +37.44 0.0657072 +37.48 0.0658477 +37.52 0.0659883 +37.56 0.0661291 +37.6 0.06627 +37.64 0.0664111 +37.68 0.0665523 +37.72 0.0666937 +37.76 0.0668352 +37.8 0.0669769 +37.84 0.0671187 +37.88 0.0672607 +37.92 0.0674028 +37.96 0.0675451 +38 0.0676875 +38.04 0.0678301 +38.08 0.0679728 +38.12 0.0681157 +38.16 0.0682587 +38.2 0.0684019 +38.24 0.0685452 +38.28 0.0686887 +38.32 0.0688323 +38.36 0.0689761 +38.4 0.06912 +38.44 0.0692641 +38.48 0.0694083 +38.52 0.0695527 +38.56 0.0696972 +38.6 0.0698419 +38.64 0.0699867 +38.68 0.0701317 +38.72 0.0702768 +38.76 0.0704221 +38.8 0.0705675 +38.84 0.0707131 +38.88 0.0708588 +38.92 0.0710047 +38.96 0.0711507 +39 0.0712969 +39.04 0.0714432 +39.08 0.0715897 +39.12 0.0717363 +39.16 0.0718831 +39.2 0.07203 +39.24 0.0721771 +39.28 0.0723243 +39.32 0.0724717 +39.36 0.0726192 +39.4 0.0727669 +39.44 0.0729147 +39.48 0.0730627 +39.52 0.0732108 +39.56 0.0733591 +39.6 0.0735075 +39.64 0.0736561 +39.68 0.0738048 +39.72 0.0739537 +39.76 0.0741027 +39.8 0.0742519 +39.84 0.0744012 +39.88 0.0745507 +39.92 0.0747003 +39.96 0.0748501 +40 0.075 diff --git a/mcstas-comps/data/MCViNE/SANS2D_example.dat b/mcstas-comps/data/MCViNE/SANS2D_example.dat new file mode 100644 index 0000000000..b6e31b7c56 --- /dev/null +++ b/mcstas-comps/data/MCViNE/SANS2D_example.dat @@ -0,0 +1,84 @@ +# SANS2D_ongrid example: row1 Qx [1/AA], row2 Qy [1/AA], then S rows (row index = Qy) +-0.2 -0.195 -0.19 -0.185 -0.18 -0.175 -0.17 -0.165 -0.16 -0.155 -0.15 -0.145 -0.14 -0.135 -0.13 -0.125 -0.12 -0.115 -0.11 -0.105 -0.1 -0.095 -0.09 -0.085 -0.08 -0.075 -0.07 -0.065 -0.06 -0.055 -0.05 -0.045 -0.04 -0.035 -0.03 -0.025 -0.02 -0.015 -0.01 -0.005 0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 0.055 0.06 0.065 0.07 0.075 0.08 0.085 0.09 0.095 0.1 0.105 0.11 0.115 0.12 0.125 0.13 0.135 0.14 0.145 0.15 0.155 0.16 0.165 0.17 0.175 0.18 0.185 0.19 0.195 0.2 +-0.2 -0.195 -0.19 -0.185 -0.18 -0.175 -0.17 -0.165 -0.16 -0.155 -0.15 -0.145 -0.14 -0.135 -0.13 -0.125 -0.12 -0.115 -0.11 -0.105 -0.1 -0.095 -0.09 -0.085 -0.08 -0.075 -0.07 -0.065 -0.06 -0.055 -0.05 -0.045 -0.04 -0.035 -0.03 -0.025 -0.02 -0.015 -0.01 -0.005 0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 0.055 0.06 0.065 0.07 0.075 0.08 0.085 0.09 0.095 0.1 0.105 0.11 0.115 0.12 0.125 0.13 0.135 0.14 0.145 0.15 0.155 0.16 0.165 0.17 0.175 0.18 0.185 0.19 0.195 0.2 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100004 0.100008 0.100016 0.100031 0.100054 0.10009 0.100141 0.100209 0.10029 0.10038 0.100469 0.100545 0.100596 0.100614 0.100596 0.100545 0.100469 0.10038 0.10029 0.100209 0.100141 0.10009 0.100054 0.100031 0.100016 0.100008 0.100004 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100001 0.100003 0.100007 0.100015 0.100029 0.100055 0.100098 0.100163 0.100255 0.100377 0.100525 0.100688 0.100848 0.100986 0.101078 0.101111 0.101078 0.100986 0.100848 0.100688 0.100525 0.100377 0.100255 0.100163 0.100098 0.100055 0.100029 0.100015 0.100007 0.100003 0.100001 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100006 0.100012 0.100026 0.100052 0.100099 0.100174 0.10029 0.100455 0.100672 0.100935 0.101225 0.101511 0.101756 0.101921 0.10198 0.101921 0.101756 0.101511 0.101225 0.100935 0.100672 0.100455 0.10029 0.100174 0.100099 0.100052 0.100026 0.100012 0.100006 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100004 0.10001 0.100022 0.100046 0.100092 0.100173 0.100306 0.100509 0.100799 0.10118 0.101641 0.10215 0.102652 0.103082 0.103372 0.103474 0.103372 0.103082 0.102652 0.10215 0.101641 0.10118 0.100799 0.100509 0.100306 0.100173 0.100092 0.100046 0.100022 0.10001 0.100004 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100007 0.100017 0.100038 0.10008 0.100159 0.100299 0.100529 0.100881 0.101381 0.10204 0.102838 0.103717 0.104586 0.105328 0.105829 0.106007 0.105829 0.105328 0.104586 0.103717 0.102838 0.10204 0.101381 0.100881 0.100529 0.100299 0.100159 0.10008 0.100038 0.100017 0.100007 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100005 0.100012 0.100029 0.100064 0.100136 0.100271 0.100509 0.100901 0.1015 0.102352 0.103474 0.104833 0.106331 0.10781 0.109074 0.109929 0.110231 0.109929 0.109074 0.10781 0.106331 0.104833 0.103474 0.102352 0.1015 0.100901 0.100509 0.100271 0.100136 0.100064 0.100029 0.100012 0.100005 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.10002 0.100048 0.100108 0.100228 0.100455 0.100855 0.101511 0.102517 0.103947 0.105829 0.108109 0.110622 0.113104 0.115225 0.116659 0.117166 0.116659 0.115225 0.113104 0.110622 0.108109 0.105829 0.103947 0.102517 0.101511 0.100855 0.100455 0.100228 0.100108 0.100048 0.10002 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100005 0.100013 0.100033 0.100079 0.100178 0.100377 0.100752 0.101413 0.102498 0.10416 0.106524 0.109635 0.113402 0.117557 0.121659 0.125164 0.127534 0.128373 0.127534 0.125164 0.121659 0.117557 0.113402 0.109635 0.106524 0.10416 0.102498 0.101413 0.100752 0.100377 0.100178 0.100079 0.100033 0.100013 0.100005 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.100021 0.100054 0.100129 0.10029 0.100614 0.101225 0.1023 0.104067 0.106773 0.110622 0.115688 0.121822 0.128586 0.135266 0.140973 0.144832 0.146197 0.144832 0.140973 0.135266 0.128586 0.121822 0.115688 0.110622 0.106773 0.104067 0.1023 0.101225 0.100614 0.10029 0.100129 0.100054 0.100021 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100013 0.100034 0.100087 0.100207 0.100466 0.100986 0.101965 0.103689 0.106524 0.110864 0.117038 0.125164 0.135003 0.145852 0.156567 0.165721 0.171911 0.174101 0.171911 0.165721 0.156567 0.145852 0.135003 0.125164 0.117038 0.110864 0.106524 0.103689 0.101965 0.100986 0.100466 0.100207 0.100087 0.100034 0.100013 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100007 0.10002 0.100054 0.100137 0.100327 0.100736 0.101557 0.103105 0.105829 0.110308 0.117166 0.126922 0.139763 0.155308 0.172452 0.189383 0.203848 0.213627 0.217088 0.213627 0.203848 0.189383 0.172452 0.155308 0.139763 0.126922 0.117166 0.110308 0.105829 0.103105 0.101557 0.100736 0.100327 0.100137 0.100054 0.10002 0.100007 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100011 0.100031 0.100084 0.100213 0.100509 0.101145 0.102424 0.104833 0.109074 0.116045 0.12672 0.141906 0.161894 0.186093 0.212778 0.239132 0.261649 0.276872 0.282258 0.276872 0.261649 0.239132 0.212778 0.186093 0.161894 0.141906 0.12672 0.116045 0.109074 0.104833 0.102424 0.101145 0.100509 0.100213 0.100084 0.100031 0.100011 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100006 0.100017 0.100048 0.100129 0.100327 0.100781 0.101756 0.103717 0.107411 0.113914 0.124604 0.140973 0.164259 0.19491 0.232016 0.272937 0.313348 0.347875 0.371219 0.379479 0.371219 0.347875 0.313348 0.272937 0.232016 0.19491 0.164259 0.140973 0.124604 0.113914 0.107411 0.103717 0.101756 0.100781 0.100327 0.100129 0.100048 0.100017 0.100006 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.100025 0.100072 0.100195 0.100494 0.10118 0.102652 0.105615 0.111195 0.121019 0.137167 0.161894 0.197069 0.24337 0.299422 0.361236 0.422282 0.474438 0.5097 0.522177 0.5097 0.474438 0.422282 0.361236 0.299422 0.24337 0.197069 0.161894 0.137167 0.121019 0.111195 0.105615 0.102652 0.10118 0.100494 0.100195 0.100072 0.100025 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100012 0.100038 0.100108 0.10029 0.100736 0.101756 0.103947 0.108356 0.116659 0.131278 0.155308 0.192105 0.244449 0.313348 0.396761 0.488746 0.579587 0.657201 0.709675 0.728242 0.709675 0.657201 0.579587 0.488746 0.396761 0.313348 0.244449 0.192105 0.155308 0.131278 0.116659 0.108356 0.103947 0.101756 0.100736 0.10029 0.100108 0.100038 0.100012 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100006 0.100018 0.100055 0.100158 0.100425 0.101078 0.102574 0.105786 0.112249 0.124421 0.145852 0.181079 0.23502 0.311754 0.412757 0.535035 0.66988 0.803048 0.916825 0.993749 1.02097 0.993749 0.916825 0.803048 0.66988 0.535035 0.412757 0.311754 0.23502 0.181079 0.145852 0.124421 0.112249 0.105786 0.102574 0.101078 0.100425 0.100158 0.100055 0.100018 0.100006 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100008 0.100026 0.10008 0.100228 0.100614 0.101557 0.103717 0.108356 0.117689 0.135266 0.166216 0.217088 0.294986 0.405798 0.551658 0.728242 0.922975 1.11529 1.27959 1.39068 1.42999 1.39068 1.27959 1.11529 0.922975 0.728242 0.551658 0.405798 0.294986 0.217088 0.166216 0.135266 0.117689 0.108356 0.103717 0.101557 0.100614 0.100228 0.10008 0.100026 0.100008 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100037 0.100114 0.100325 0.100874 0.102215 0.105288 0.111887 0.125164 0.15017 0.1942 0.266572 0.37739 0.535035 0.742538 0.993749 1.27078 1.54437 1.77811 1.93615 1.99207 1.93615 1.77811 1.54437 1.27078 0.993749 0.742538 0.535035 0.37739 0.266572 0.1942 0.15017 0.125164 0.111887 0.105288 0.102215 0.100874 0.100325 0.100114 0.100037 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100005 0.100016 0.100052 0.100159 0.100455 0.101225 0.103105 0.107411 0.116659 0.135266 0.170311 0.232016 0.33344 0.488746 0.709675 1.00048 1.35254 1.74078 2.12419 2.45177 2.67325 2.75162 2.67325 2.45177 2.12419 1.74078 1.35254 1.00048 0.709675 0.488746 0.33344 0.232016 0.170311 0.135266 0.116659 0.107411 0.103105 0.101225 0.100455 0.100159 0.100052 0.100016 0.100005 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100022 0.100072 0.10022 0.100628 0.101691 0.104286 0.110231 0.122998 0.148688 0.197069 0.282258 0.422282 0.636693 0.941702 1.34318 1.82922 2.36522 2.89455 3.3468 3.65257 3.76076 3.65257 3.3468 2.89455 2.36522 1.82922 1.34318 0.941702 0.636693 0.422282 0.282258 0.197069 0.148688 0.122998 0.110231 0.104286 0.101691 0.100628 0.10022 0.100072 0.100022 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100009 0.100031 0.100099 0.100299 0.100855 0.1023 0.105829 0.113914 0.131278 0.166216 0.232016 0.347875 0.53831 0.829913 1.24473 1.79075 2.45177 3.18074 3.90064 4.51572 4.93156 5.07871 4.93156 4.51572 3.90064 3.18074 2.45177 1.79075 1.24473 0.829913 0.53831 0.347875 0.232016 0.166216 0.131278 0.113914 0.105829 0.1023 0.100855 0.100299 0.100099 0.100031 0.100009 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100041 0.100132 0.100401 0.101145 0.103082 0.10781 0.118642 0.141906 0.188715 0.276872 0.432096 0.687235 1.07792 1.63368 2.36522 3.25084 4.22749 5.192 6.01606 6.5732 6.77034 6.5732 6.01606 5.192 4.22749 3.25084 2.36522 1.63368 1.07792 0.687235 0.432096 0.276872 0.188715 0.141906 0.118642 0.10781 0.103082 0.101145 0.100401 0.100132 0.100041 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100016 0.100054 0.100174 0.100529 0.101511 0.104067 0.110308 0.124604 0.155308 0.217088 0.33344 0.53831 0.875048 1.39068 2.12419 3.08969 4.25857 5.54757 6.82055 7.90817 8.6435 8.90368 8.6435 7.90817 6.82055 5.54757 4.25857 3.08969 2.12419 1.39068 0.875048 0.53831 0.33344 0.217088 0.155308 0.124604 0.110308 0.104067 0.101511 0.100529 0.100174 0.100054 0.100016 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100006 0.100021 0.10007 0.100227 0.100688 0.101965 0.105288 0.113402 0.13199 0.171911 0.252235 0.403513 0.66988 1.1077 1.77811 2.73181 3.98713 5.50687 7.18281 8.8379 10.252 11.2081 11.5463 11.2081 10.252 8.8379 7.18281 5.50687 3.98713 2.73181 1.77811 1.1077 0.66988 0.403513 0.252235 0.171911 0.13199 0.113402 0.105288 0.101965 0.100688 0.100227 0.10007 0.100021 0.100006 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100026 0.10009 0.10029 0.100881 0.102517 0.106773 0.117166 0.140973 0.192105 0.294986 0.488746 0.829913 1.39068 2.24936 3.47087 5.07871 7.02522 9.1718 11.2917 13.1029 14.3274 14.7607 14.3274 13.1029 11.2917 9.1718 7.02522 5.07871 3.47087 2.24936 1.39068 0.829913 0.488746 0.294986 0.192105 0.140973 0.117166 0.106773 0.102517 0.100881 0.10029 0.10009 0.100026 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100009 0.100033 0.100114 0.100366 0.101111 0.103175 0.108546 0.121659 0.151698 0.216213 0.346023 0.5905 1.02097 1.72852 2.81196 4.35319 6.38189 8.8379 11.5463 14.2211 16.5064 18.0514 18.5981 18.0514 16.5064 14.2211 11.5463 8.8379 6.38189 4.35319 2.81196 1.72852 1.02097 0.5905 0.346023 0.216213 0.151698 0.121659 0.108546 0.103175 0.101111 0.100366 0.100114 0.100033 0.100009 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100041 0.100141 0.100455 0.101381 0.103947 0.110622 0.126922 0.164259 0.244449 0.405798 0.709675 1.24473 2.12419 3.47087 5.38657 7.90817 10.9609 14.3274 17.652 20.4926 22.413 23.0925 22.413 20.4926 17.652 14.3274 10.9609 7.90817 5.38657 3.47087 2.12419 1.24473 0.709675 0.405798 0.244449 0.164259 0.126922 0.110622 0.103947 0.101381 0.100455 0.100141 0.100041 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100014 0.100051 0.100173 0.100557 0.101691 0.104833 0.113006 0.132964 0.178683 0.276872 0.474438 0.846522 1.50168 2.57854 4.22749 6.5732 9.66079 13.3988 17.5209 21.5918 25.0699 27.4214 28.2535 27.4214 25.0699 21.5918 17.5209 13.3988 9.66079 6.5732 4.22749 2.57854 1.50168 0.846522 0.474438 0.276872 0.178683 0.132964 0.113006 0.104833 0.101691 0.100557 0.100173 0.100051 0.100014 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100017 0.100061 0.100209 0.100672 0.10204 0.105829 0.115688 0.139763 0.19491 0.313348 0.551658 1.00048 1.79075 3.08969 5.07871 7.90817 11.6325 16.1414 21.1136 26.024 30.2194 33.0559 34.0596 33.0559 30.2194 26.024 21.1136 16.1414 11.6325 7.90817 5.07871 3.08969 1.79075 1.00048 0.551658 0.313348 0.19491 0.139763 0.115688 0.105829 0.10204 0.100672 0.100209 0.100061 0.100017 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100005 0.10002 0.100072 0.100248 0.100799 0.102424 0.106927 0.118642 0.147249 0.212778 0.353516 0.636693 1.17001 2.10907 3.65257 6.01606 9.37822 13.8038 19.1615 25.0699 30.9048 35.8901 39.2606 40.4532 39.2606 35.8901 30.9048 25.0699 19.1615 13.8038 9.37822 6.01606 3.65257 2.10907 1.17001 0.636693 0.353516 0.212778 0.147249 0.118642 0.106927 0.102424 0.100799 0.100248 0.100072 0.10002 0.100005 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100006 0.100023 0.100085 0.10029 0.100935 0.102838 0.108109 0.121822 0.155308 0.232016 0.396761 0.728242 1.35254 2.45177 4.25857 7.02522 10.9609 16.1414 22.413 29.3293 36.1595 41.9952 45.9406 47.3367 45.9406 41.9952 36.1595 29.3293 22.413 16.1414 10.9609 7.02522 4.25857 2.45177 1.35254 0.728242 0.396761 0.232016 0.155308 0.121822 0.108109 0.102838 0.100935 0.10029 0.100085 0.100023 0.100006 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100027 0.100098 0.100335 0.101078 0.103272 0.10935 0.125164 0.163779 0.252235 0.44221 0.824459 1.54437 2.81196 4.89546 8.08584 12.6243 18.5981 25.8303 33.8058 41.6821 48.4115 52.9612 54.5711 52.9612 48.4115 41.6821 33.8058 25.8303 18.5981 12.6243 8.08584 4.89546 2.81196 1.54437 0.824459 0.44221 0.252235 0.163779 0.125164 0.10935 0.103272 0.101078 0.100335 0.100098 0.100027 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100008 0.100031 0.100111 0.10038 0.101225 0.103717 0.110622 0.128586 0.172452 0.272937 0.488746 0.922975 1.74078 3.18074 5.54757 9.1718 14.3274 21.1136 29.3293 38.3893 47.3367 54.9812 60.1496 61.9783 60.1496 54.9812 47.3367 38.3893 29.3293 21.1136 14.3274 9.1718 5.54757 3.18074 1.74078 0.922975 0.488746 0.272937 0.172452 0.128586 0.110622 0.103717 0.101225 0.10038 0.100111 0.100031 0.100008 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100009 0.100034 0.100124 0.100425 0.101371 0.10416 0.111887 0.13199 0.181079 0.293529 0.535035 1.02097 1.93615 3.54757 6.19623 10.252 16.0215 23.6157 32.8097 42.9485 52.9612 61.516 67.2998 69.3463 67.2998 61.516 52.9612 42.9485 32.8097 23.6157 16.0215 10.252 6.19623 3.54757 1.93615 1.02097 0.535035 0.293529 0.181079 0.13199 0.111887 0.10416 0.101371 0.100425 0.100124 0.100034 0.100009 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.10001 0.100038 0.100137 0.100469 0.101511 0.104586 0.113104 0.135266 0.189383 0.313348 0.579587 1.11529 2.12419 3.90064 6.82055 11.2917 17.652 26.024 36.1595 47.3367 58.3748 67.8057 74.1818 76.4379 74.1818 67.8057 58.3748 47.3367 36.1595 26.024 17.652 11.2917 6.82055 3.90064 2.12419 1.11529 0.579587 0.313348 0.189383 0.135266 0.113104 0.104586 0.101511 0.100469 0.100137 0.100038 0.10001 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100041 0.100149 0.100509 0.101641 0.10498 0.114231 0.138299 0.197069 0.331696 0.620831 1.2026 2.29827 4.22749 7.39851 12.2541 19.1615 28.2535 39.2606 51.3989 63.3864 73.6283 80.5528 83.0029 80.5528 73.6283 63.3864 51.3989 39.2606 28.2535 19.1615 12.2541 7.39851 4.22749 2.29827 1.2026 0.620831 0.331696 0.197069 0.138299 0.114231 0.10498 0.101641 0.100509 0.100149 0.100041 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100044 0.100159 0.100545 0.101756 0.105328 0.115225 0.140973 0.203848 0.347875 0.657201 1.27959 2.45177 4.51572 7.90817 13.1029 20.4926 30.2194 41.9952 54.9812 67.8057 78.7628 86.1708 88.792 86.1708 78.7628 67.8057 54.9812 41.9952 30.2194 20.4926 13.1029 7.90817 4.51572 2.45177 1.27959 0.657201 0.347875 0.203848 0.140973 0.115225 0.105328 0.101756 0.100545 0.100159 0.100044 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100046 0.100168 0.100574 0.10185 0.105615 0.116045 0.143182 0.209445 0.361236 0.687235 1.34318 2.57854 4.75374 8.32905 13.8038 21.5918 31.8429 44.2534 57.9394 71.4552 83.0029 90.8102 93.5728 90.8102 83.0029 71.4552 57.9394 44.2534 31.8429 21.5918 13.8038 8.32905 4.75374 2.57854 1.34318 0.687235 0.361236 0.209445 0.143182 0.116045 0.105615 0.10185 0.100574 0.100168 0.100046 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100048 0.100174 0.100596 0.101921 0.105829 0.116659 0.144832 0.213627 0.371219 0.709675 1.39068 2.67325 4.93156 8.6435 14.3274 22.413 33.0559 45.9406 60.1496 74.1818 86.1708 94.2765 97.1446 94.2765 86.1708 74.1818 60.1496 45.9406 33.0559 22.413 14.3274 8.6435 4.93156 2.67325 1.39068 0.709675 0.371219 0.213627 0.144832 0.116659 0.105829 0.101921 0.100596 0.100174 0.100048 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100013 0.100049 0.100178 0.10061 0.101965 0.105962 0.117038 0.145852 0.216213 0.37739 0.723548 1.42005 2.73181 5.04151 8.8379 14.6512 22.9207 33.8058 46.9837 61.516 75.8676 88.1293 96.4194 99.3528 96.4194 88.1293 75.8676 61.516 46.9837 33.8058 22.9207 14.6512 8.8379 5.04151 2.73181 1.42005 0.723548 0.37739 0.216213 0.145852 0.117038 0.105962 0.101965 0.10061 0.100178 0.100049 0.100013 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100013 0.100049 0.10018 0.100614 0.10198 0.106007 0.117166 0.146197 0.217088 0.379479 0.728242 1.42999 2.75162 5.07871 8.90368 14.7607 23.0925 34.0596 47.3367 61.9783 76.4379 88.792 97.1446 100.1 97.1446 88.792 76.4379 61.9783 47.3367 34.0596 23.0925 14.7607 8.90368 5.07871 2.75162 1.42999 0.728242 0.379479 0.217088 0.146197 0.117166 0.106007 0.10198 0.100614 0.10018 0.100049 0.100013 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100013 0.100049 0.100178 0.10061 0.101965 0.105962 0.117038 0.145852 0.216213 0.37739 0.723548 1.42005 2.73181 5.04151 8.8379 14.6512 22.9207 33.8058 46.9837 61.516 75.8676 88.1293 96.4194 99.3528 96.4194 88.1293 75.8676 61.516 46.9837 33.8058 22.9207 14.6512 8.8379 5.04151 2.73181 1.42005 0.723548 0.37739 0.216213 0.145852 0.117038 0.105962 0.101965 0.10061 0.100178 0.100049 0.100013 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100048 0.100174 0.100596 0.101921 0.105829 0.116659 0.144832 0.213627 0.371219 0.709675 1.39068 2.67325 4.93156 8.6435 14.3274 22.413 33.0559 45.9406 60.1496 74.1818 86.1708 94.2765 97.1446 94.2765 86.1708 74.1818 60.1496 45.9406 33.0559 22.413 14.3274 8.6435 4.93156 2.67325 1.39068 0.709675 0.371219 0.213627 0.144832 0.116659 0.105829 0.101921 0.100596 0.100174 0.100048 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100046 0.100168 0.100574 0.10185 0.105615 0.116045 0.143182 0.209445 0.361236 0.687235 1.34318 2.57854 4.75374 8.32905 13.8038 21.5918 31.8429 44.2534 57.9394 71.4552 83.0029 90.8102 93.5728 90.8102 83.0029 71.4552 57.9394 44.2534 31.8429 21.5918 13.8038 8.32905 4.75374 2.57854 1.34318 0.687235 0.361236 0.209445 0.143182 0.116045 0.105615 0.10185 0.100574 0.100168 0.100046 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100044 0.100159 0.100545 0.101756 0.105328 0.115225 0.140973 0.203848 0.347875 0.657201 1.27959 2.45177 4.51572 7.90817 13.1029 20.4926 30.2194 41.9952 54.9812 67.8057 78.7628 86.1708 88.792 86.1708 78.7628 67.8057 54.9812 41.9952 30.2194 20.4926 13.1029 7.90817 4.51572 2.45177 1.27959 0.657201 0.347875 0.203848 0.140973 0.115225 0.105328 0.101756 0.100545 0.100159 0.100044 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100041 0.100149 0.100509 0.101641 0.10498 0.114231 0.138299 0.197069 0.331696 0.620831 1.2026 2.29827 4.22749 7.39851 12.2541 19.1615 28.2535 39.2606 51.3989 63.3864 73.6283 80.5528 83.0029 80.5528 73.6283 63.3864 51.3989 39.2606 28.2535 19.1615 12.2541 7.39851 4.22749 2.29827 1.2026 0.620831 0.331696 0.197069 0.138299 0.114231 0.10498 0.101641 0.100509 0.100149 0.100041 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.10001 0.100038 0.100137 0.100469 0.101511 0.104586 0.113104 0.135266 0.189383 0.313348 0.579587 1.11529 2.12419 3.90064 6.82055 11.2917 17.652 26.024 36.1595 47.3367 58.3748 67.8057 74.1818 76.4379 74.1818 67.8057 58.3748 47.3367 36.1595 26.024 17.652 11.2917 6.82055 3.90064 2.12419 1.11529 0.579587 0.313348 0.189383 0.135266 0.113104 0.104586 0.101511 0.100469 0.100137 0.100038 0.10001 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100009 0.100034 0.100124 0.100425 0.101371 0.10416 0.111887 0.13199 0.181079 0.293529 0.535035 1.02097 1.93615 3.54757 6.19623 10.252 16.0215 23.6157 32.8097 42.9485 52.9612 61.516 67.2998 69.3463 67.2998 61.516 52.9612 42.9485 32.8097 23.6157 16.0215 10.252 6.19623 3.54757 1.93615 1.02097 0.535035 0.293529 0.181079 0.13199 0.111887 0.10416 0.101371 0.100425 0.100124 0.100034 0.100009 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100008 0.100031 0.100111 0.10038 0.101225 0.103717 0.110622 0.128586 0.172452 0.272937 0.488746 0.922975 1.74078 3.18074 5.54757 9.1718 14.3274 21.1136 29.3293 38.3893 47.3367 54.9812 60.1496 61.9783 60.1496 54.9812 47.3367 38.3893 29.3293 21.1136 14.3274 9.1718 5.54757 3.18074 1.74078 0.922975 0.488746 0.272937 0.172452 0.128586 0.110622 0.103717 0.101225 0.10038 0.100111 0.100031 0.100008 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100027 0.100098 0.100335 0.101078 0.103272 0.10935 0.125164 0.163779 0.252235 0.44221 0.824459 1.54437 2.81196 4.89546 8.08584 12.6243 18.5981 25.8303 33.8058 41.6821 48.4115 52.9612 54.5711 52.9612 48.4115 41.6821 33.8058 25.8303 18.5981 12.6243 8.08584 4.89546 2.81196 1.54437 0.824459 0.44221 0.252235 0.163779 0.125164 0.10935 0.103272 0.101078 0.100335 0.100098 0.100027 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100006 0.100023 0.100085 0.10029 0.100935 0.102838 0.108109 0.121822 0.155308 0.232016 0.396761 0.728242 1.35254 2.45177 4.25857 7.02522 10.9609 16.1414 22.413 29.3293 36.1595 41.9952 45.9406 47.3367 45.9406 41.9952 36.1595 29.3293 22.413 16.1414 10.9609 7.02522 4.25857 2.45177 1.35254 0.728242 0.396761 0.232016 0.155308 0.121822 0.108109 0.102838 0.100935 0.10029 0.100085 0.100023 0.100006 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100005 0.10002 0.100072 0.100248 0.100799 0.102424 0.106927 0.118642 0.147249 0.212778 0.353516 0.636693 1.17001 2.10907 3.65257 6.01606 9.37822 13.8038 19.1615 25.0699 30.9048 35.8901 39.2606 40.4532 39.2606 35.8901 30.9048 25.0699 19.1615 13.8038 9.37822 6.01606 3.65257 2.10907 1.17001 0.636693 0.353516 0.212778 0.147249 0.118642 0.106927 0.102424 0.100799 0.100248 0.100072 0.10002 0.100005 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100017 0.100061 0.100209 0.100672 0.10204 0.105829 0.115688 0.139763 0.19491 0.313348 0.551658 1.00048 1.79075 3.08969 5.07871 7.90817 11.6325 16.1414 21.1136 26.024 30.2194 33.0559 34.0596 33.0559 30.2194 26.024 21.1136 16.1414 11.6325 7.90817 5.07871 3.08969 1.79075 1.00048 0.551658 0.313348 0.19491 0.139763 0.115688 0.105829 0.10204 0.100672 0.100209 0.100061 0.100017 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100014 0.100051 0.100173 0.100557 0.101691 0.104833 0.113006 0.132964 0.178683 0.276872 0.474438 0.846522 1.50168 2.57854 4.22749 6.5732 9.66079 13.3988 17.5209 21.5918 25.0699 27.4214 28.2535 27.4214 25.0699 21.5918 17.5209 13.3988 9.66079 6.5732 4.22749 2.57854 1.50168 0.846522 0.474438 0.276872 0.178683 0.132964 0.113006 0.104833 0.101691 0.100557 0.100173 0.100051 0.100014 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100011 0.100041 0.100141 0.100455 0.101381 0.103947 0.110622 0.126922 0.164259 0.244449 0.405798 0.709675 1.24473 2.12419 3.47087 5.38657 7.90817 10.9609 14.3274 17.652 20.4926 22.413 23.0925 22.413 20.4926 17.652 14.3274 10.9609 7.90817 5.38657 3.47087 2.12419 1.24473 0.709675 0.405798 0.244449 0.164259 0.126922 0.110622 0.103947 0.101381 0.100455 0.100141 0.100041 0.100011 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100009 0.100033 0.100114 0.100366 0.101111 0.103175 0.108546 0.121659 0.151698 0.216213 0.346023 0.5905 1.02097 1.72852 2.81196 4.35319 6.38189 8.8379 11.5463 14.2211 16.5064 18.0514 18.5981 18.0514 16.5064 14.2211 11.5463 8.8379 6.38189 4.35319 2.81196 1.72852 1.02097 0.5905 0.346023 0.216213 0.151698 0.121659 0.108546 0.103175 0.101111 0.100366 0.100114 0.100033 0.100009 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100026 0.10009 0.10029 0.100881 0.102517 0.106773 0.117166 0.140973 0.192105 0.294986 0.488746 0.829913 1.39068 2.24936 3.47087 5.07871 7.02522 9.1718 11.2917 13.1029 14.3274 14.7607 14.3274 13.1029 11.2917 9.1718 7.02522 5.07871 3.47087 2.24936 1.39068 0.829913 0.488746 0.294986 0.192105 0.140973 0.117166 0.106773 0.102517 0.100881 0.10029 0.10009 0.100026 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100006 0.100021 0.10007 0.100227 0.100688 0.101965 0.105288 0.113402 0.13199 0.171911 0.252235 0.403513 0.66988 1.1077 1.77811 2.73181 3.98713 5.50687 7.18281 8.8379 10.252 11.2081 11.5463 11.2081 10.252 8.8379 7.18281 5.50687 3.98713 2.73181 1.77811 1.1077 0.66988 0.403513 0.252235 0.171911 0.13199 0.113402 0.105288 0.101965 0.100688 0.100227 0.10007 0.100021 0.100006 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100016 0.100054 0.100174 0.100529 0.101511 0.104067 0.110308 0.124604 0.155308 0.217088 0.33344 0.53831 0.875048 1.39068 2.12419 3.08969 4.25857 5.54757 6.82055 7.90817 8.6435 8.90368 8.6435 7.90817 6.82055 5.54757 4.25857 3.08969 2.12419 1.39068 0.875048 0.53831 0.33344 0.217088 0.155308 0.124604 0.110308 0.104067 0.101511 0.100529 0.100174 0.100054 0.100016 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100041 0.100132 0.100401 0.101145 0.103082 0.10781 0.118642 0.141906 0.188715 0.276872 0.432096 0.687235 1.07792 1.63368 2.36522 3.25084 4.22749 5.192 6.01606 6.5732 6.77034 6.5732 6.01606 5.192 4.22749 3.25084 2.36522 1.63368 1.07792 0.687235 0.432096 0.276872 0.188715 0.141906 0.118642 0.10781 0.103082 0.101145 0.100401 0.100132 0.100041 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100009 0.100031 0.100099 0.100299 0.100855 0.1023 0.105829 0.113914 0.131278 0.166216 0.232016 0.347875 0.53831 0.829913 1.24473 1.79075 2.45177 3.18074 3.90064 4.51572 4.93156 5.07871 4.93156 4.51572 3.90064 3.18074 2.45177 1.79075 1.24473 0.829913 0.53831 0.347875 0.232016 0.166216 0.131278 0.113914 0.105829 0.1023 0.100855 0.100299 0.100099 0.100031 0.100009 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100007 0.100022 0.100072 0.10022 0.100628 0.101691 0.104286 0.110231 0.122998 0.148688 0.197069 0.282258 0.422282 0.636693 0.941702 1.34318 1.82922 2.36522 2.89455 3.3468 3.65257 3.76076 3.65257 3.3468 2.89455 2.36522 1.82922 1.34318 0.941702 0.636693 0.422282 0.282258 0.197069 0.148688 0.122998 0.110231 0.104286 0.101691 0.100628 0.10022 0.100072 0.100022 0.100007 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100005 0.100016 0.100052 0.100159 0.100455 0.101225 0.103105 0.107411 0.116659 0.135266 0.170311 0.232016 0.33344 0.488746 0.709675 1.00048 1.35254 1.74078 2.12419 2.45177 2.67325 2.75162 2.67325 2.45177 2.12419 1.74078 1.35254 1.00048 0.709675 0.488746 0.33344 0.232016 0.170311 0.135266 0.116659 0.107411 0.103105 0.101225 0.100455 0.100159 0.100052 0.100016 0.100005 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100012 0.100037 0.100114 0.100325 0.100874 0.102215 0.105288 0.111887 0.125164 0.15017 0.1942 0.266572 0.37739 0.535035 0.742538 0.993749 1.27078 1.54437 1.77811 1.93615 1.99207 1.93615 1.77811 1.54437 1.27078 0.993749 0.742538 0.535035 0.37739 0.266572 0.1942 0.15017 0.125164 0.111887 0.105288 0.102215 0.100874 0.100325 0.100114 0.100037 0.100012 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100008 0.100026 0.10008 0.100228 0.100614 0.101557 0.103717 0.108356 0.117689 0.135266 0.166216 0.217088 0.294986 0.405798 0.551658 0.728242 0.922975 1.11529 1.27959 1.39068 1.42999 1.39068 1.27959 1.11529 0.922975 0.728242 0.551658 0.405798 0.294986 0.217088 0.166216 0.135266 0.117689 0.108356 0.103717 0.101557 0.100614 0.100228 0.10008 0.100026 0.100008 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100002 0.100006 0.100018 0.100055 0.100158 0.100425 0.101078 0.102574 0.105786 0.112249 0.124421 0.145852 0.181079 0.23502 0.311754 0.412757 0.535035 0.66988 0.803048 0.916825 0.993749 1.02097 0.993749 0.916825 0.803048 0.66988 0.535035 0.412757 0.311754 0.23502 0.181079 0.145852 0.124421 0.112249 0.105786 0.102574 0.101078 0.100425 0.100158 0.100055 0.100018 0.100006 0.100002 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100012 0.100038 0.100108 0.10029 0.100736 0.101756 0.103947 0.108356 0.116659 0.131278 0.155308 0.192105 0.244449 0.313348 0.396761 0.488746 0.579587 0.657201 0.709675 0.728242 0.709675 0.657201 0.579587 0.488746 0.396761 0.313348 0.244449 0.192105 0.155308 0.131278 0.116659 0.108356 0.103947 0.101756 0.100736 0.10029 0.100108 0.100038 0.100012 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.100025 0.100072 0.100195 0.100494 0.10118 0.102652 0.105615 0.111195 0.121019 0.137167 0.161894 0.197069 0.24337 0.299422 0.361236 0.422282 0.474438 0.5097 0.522177 0.5097 0.474438 0.422282 0.361236 0.299422 0.24337 0.197069 0.161894 0.137167 0.121019 0.111195 0.105615 0.102652 0.10118 0.100494 0.100195 0.100072 0.100025 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100006 0.100017 0.100048 0.100129 0.100327 0.100781 0.101756 0.103717 0.107411 0.113914 0.124604 0.140973 0.164259 0.19491 0.232016 0.272937 0.313348 0.347875 0.371219 0.379479 0.371219 0.347875 0.313348 0.272937 0.232016 0.19491 0.164259 0.140973 0.124604 0.113914 0.107411 0.103717 0.101756 0.100781 0.100327 0.100129 0.100048 0.100017 0.100006 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100011 0.100031 0.100084 0.100213 0.100509 0.101145 0.102424 0.104833 0.109074 0.116045 0.12672 0.141906 0.161894 0.186093 0.212778 0.239132 0.261649 0.276872 0.282258 0.276872 0.261649 0.239132 0.212778 0.186093 0.161894 0.141906 0.12672 0.116045 0.109074 0.104833 0.102424 0.101145 0.100509 0.100213 0.100084 0.100031 0.100011 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100007 0.10002 0.100054 0.100137 0.100327 0.100736 0.101557 0.103105 0.105829 0.110308 0.117166 0.126922 0.139763 0.155308 0.172452 0.189383 0.203848 0.213627 0.217088 0.213627 0.203848 0.189383 0.172452 0.155308 0.139763 0.126922 0.117166 0.110308 0.105829 0.103105 0.101557 0.100736 0.100327 0.100137 0.100054 0.10002 0.100007 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100004 0.100013 0.100034 0.100087 0.100207 0.100466 0.100986 0.101965 0.103689 0.106524 0.110864 0.117038 0.125164 0.135003 0.145852 0.156567 0.165721 0.171911 0.174101 0.171911 0.165721 0.156567 0.145852 0.135003 0.125164 0.117038 0.110864 0.106524 0.103689 0.101965 0.100986 0.100466 0.100207 0.100087 0.100034 0.100013 0.100004 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.100021 0.100054 0.100129 0.10029 0.100614 0.101225 0.1023 0.104067 0.106773 0.110622 0.115688 0.121822 0.128586 0.135266 0.140973 0.144832 0.146197 0.144832 0.140973 0.135266 0.128586 0.121822 0.115688 0.110622 0.106773 0.104067 0.1023 0.101225 0.100614 0.10029 0.100129 0.100054 0.100021 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100005 0.100013 0.100033 0.100079 0.100178 0.100377 0.100752 0.101413 0.102498 0.10416 0.106524 0.109635 0.113402 0.117557 0.121659 0.125164 0.127534 0.128373 0.127534 0.125164 0.121659 0.117557 0.113402 0.109635 0.106524 0.10416 0.102498 0.101413 0.100752 0.100377 0.100178 0.100079 0.100033 0.100013 0.100005 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100008 0.10002 0.100048 0.100108 0.100228 0.100455 0.100855 0.101511 0.102517 0.103947 0.105829 0.108109 0.110622 0.113104 0.115225 0.116659 0.117166 0.116659 0.115225 0.113104 0.110622 0.108109 0.105829 0.103947 0.102517 0.101511 0.100855 0.100455 0.100228 0.100108 0.100048 0.10002 0.100008 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100005 0.100012 0.100029 0.100064 0.100136 0.100271 0.100509 0.100901 0.1015 0.102352 0.103474 0.104833 0.106331 0.10781 0.109074 0.109929 0.110231 0.109929 0.109074 0.10781 0.106331 0.104833 0.103474 0.102352 0.1015 0.100901 0.100509 0.100271 0.100136 0.100064 0.100029 0.100012 0.100005 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100003 0.100007 0.100017 0.100038 0.10008 0.100159 0.100299 0.100529 0.100881 0.101381 0.10204 0.102838 0.103717 0.104586 0.105328 0.105829 0.106007 0.105829 0.105328 0.104586 0.103717 0.102838 0.10204 0.101381 0.100881 0.100529 0.100299 0.100159 0.10008 0.100038 0.100017 0.100007 0.100003 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100004 0.10001 0.100022 0.100046 0.100092 0.100173 0.100306 0.100509 0.100799 0.10118 0.101641 0.10215 0.102652 0.103082 0.103372 0.103474 0.103372 0.103082 0.102652 0.10215 0.101641 0.10118 0.100799 0.100509 0.100306 0.100173 0.100092 0.100046 0.100022 0.10001 0.100004 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100006 0.100012 0.100026 0.100052 0.100099 0.100174 0.10029 0.100455 0.100672 0.100935 0.101225 0.101511 0.101756 0.101921 0.10198 0.101921 0.101756 0.101511 0.101225 0.100935 0.100672 0.100455 0.10029 0.100174 0.100099 0.100052 0.100026 0.100012 0.100006 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100001 0.100003 0.100007 0.100015 0.100029 0.100055 0.100098 0.100163 0.100255 0.100377 0.100525 0.100688 0.100848 0.100986 0.101078 0.101111 0.101078 0.100986 0.100848 0.100688 0.100525 0.100377 0.100255 0.100163 0.100098 0.100055 0.100029 0.100015 0.100007 0.100003 0.100001 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 +0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.100001 0.100002 0.100004 0.100008 0.100016 0.100031 0.100054 0.10009 0.100141 0.100209 0.10029 0.10038 0.100469 0.100545 0.100596 0.100614 0.100596 0.100545 0.100469 0.10038 0.10029 0.100209 0.100141 0.10009 0.100054 0.100031 0.100016 0.100008 0.100004 0.100002 0.100001 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 diff --git a/mcstas-comps/data/MCViNE/example.sqw b/mcstas-comps/data/MCViNE/example.sqw new file mode 100644 index 0000000000..08d023c7af --- /dev/null +++ b/mcstas-comps/data/MCViNE/example.sqw @@ -0,0 +1,128 @@ +# Example S(q,w) grid for MCViNE_SQE tests, Isotropic_Sqw layout: +# S = exp(-(w-10)^2/8) q^2 exp(-q^2/8) +# q [AA^-1] +0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10 10.1 10.2 10.3 10.4 10.5 10.6 10.7 10.8 10.9 11 11.1 11.2 11.3 11.4 11.5 11.6 11.7 11.8 11.9 12 +# w [meV] +-20 -19.5 -19 -18.5 -18 -17.5 -17 -16.5 -16 -15.5 -15 -14.5 -14 -13.5 -13 -12.5 -12 -11.5 -11 -10.5 -10 -9.5 -9 -8.5 -8 -7.5 -7 -6.5 -6 -5.5 -5 -4.5 -4 -3.5 -3 -2.5 -2 -1.5 -1 -0.5 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 6 6.5 7 7.5 8 8.5 9 9.5 10 10.5 11 11.5 12 12.5 13 13.5 14 14.5 15 15.5 16 16.5 17 17.5 18 18.5 19 19.5 20 20.5 21 21.5 22 22.5 23 23.5 24 24.5 25 25.5 26 26.5 27 27.5 28 28.5 29 29.5 30 30.5 31 31.5 32 32.5 33 33.5 34 34.5 35 35.5 36 36.5 37 37.5 38 38.5 39 39.5 40 +# S(q,w): one row per q +0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 +1.3846e-51 5.7064e-50 2.2093e-48 8.0352e-47 2.7454e-45 8.8116e-44 2.6569e-42 7.5257e-41 2.0025e-39 5.0056e-38 1.1754e-36 2.593e-35 5.3735e-34 1.0461e-32 1.9131e-31 3.2867e-30 5.3045e-29 8.0423e-28 1.1454e-26 1.5326e-25 1.9263e-24 2.2746e-23 2.523e-22 2.629e-21 2.5735e-20 2.3666e-19 2.0444e-18 1.6591e-17 1.2648e-16 9.0584e-16 6.0943e-15 3.8517e-14 2.2869e-13 1.2755e-12 6.6832e-12 3.2896e-11 1.5211e-10 6.6073e-10 2.6962e-09 1.0336e-08 3.722e-08 1.2591e-07 4.0015e-07 1.1946e-06 3.3504e-06 8.8272e-06 2.1848e-05 5.0797e-05 0.00011095 0.00022766 0.00043882 0.0007946 0.0013517 0.00216 0.0032425 0.0045726 0.0060577 0.007539 0.0088139 0.0096802 0.0099875 0.0096802 0.0088139 0.007539 0.0060577 0.0045726 0.0032425 0.00216 0.0013517 0.0007946 0.00043882 0.00022766 0.00011095 5.0797e-05 2.1848e-05 8.8272e-06 3.3504e-06 1.1946e-06 4.0015e-07 1.2591e-07 3.722e-08 1.0336e-08 2.6962e-09 6.6073e-10 1.5211e-10 3.2896e-11 6.6832e-12 1.2755e-12 2.2869e-13 3.8517e-14 6.0943e-15 9.0584e-16 1.2648e-16 1.6591e-17 2.0444e-18 2.3666e-19 2.5735e-20 2.629e-21 2.523e-22 2.2746e-23 1.9263e-24 1.5326e-25 1.1454e-26 8.0423e-28 5.3045e-29 3.2867e-30 1.9131e-31 1.0461e-32 5.3735e-34 2.593e-35 1.1754e-36 5.0056e-38 2.0025e-39 7.5257e-41 2.6569e-42 8.8116e-44 2.7454e-45 8.0352e-47 2.2093e-48 5.7064e-50 1.3846e-51 +5.5177e-51 2.274e-49 8.804e-48 3.202e-46 1.094e-44 3.5115e-43 1.0588e-41 2.999e-40 7.98e-39 1.9948e-37 4.6842e-36 1.0333e-34 2.1413e-33 4.1687e-32 7.6237e-31 1.3098e-29 2.1138e-28 3.2049e-27 4.5646e-26 6.1074e-25 7.6765e-24 9.0642e-23 1.0054e-21 1.0477e-20 1.0256e-19 9.4309e-19 8.147e-18 6.6116e-17 5.0404e-16 3.6098e-15 2.4286e-14 1.5349e-13 9.1133e-13 5.083e-12 2.6633e-11 1.3109e-10 6.0616e-10 2.633e-09 1.0744e-08 4.1188e-08 1.4832e-07 5.0177e-07 1.5946e-06 4.7607e-06 1.3352e-05 3.5177e-05 8.7063e-05 0.00020243 0.00044214 0.00090722 0.0017487 0.0031665 0.0053864 0.0086075 0.012921 0.018222 0.02414 0.030043 0.035124 0.038576 0.0398 0.038576 0.035124 0.030043 0.02414 0.018222 0.012921 0.0086075 0.0053864 0.0031665 0.0017487 0.00090722 0.00044214 0.00020243 8.7063e-05 3.5177e-05 1.3352e-05 4.7607e-06 1.5946e-06 5.0177e-07 1.4832e-07 4.1188e-08 1.0744e-08 2.633e-09 6.0616e-10 1.3109e-10 2.6633e-11 5.083e-12 9.1133e-13 1.5349e-13 2.4286e-14 3.6098e-15 5.0404e-16 6.6116e-17 8.147e-18 9.4309e-19 1.0256e-19 1.0477e-20 1.0054e-21 9.0642e-23 7.6765e-24 6.1074e-25 4.5646e-26 3.2049e-27 2.1138e-28 1.3098e-29 7.6237e-31 4.1687e-32 2.1413e-33 1.0333e-34 4.6842e-36 1.9948e-37 7.98e-39 2.999e-40 1.0588e-41 3.5115e-43 1.094e-44 3.202e-46 8.804e-48 2.274e-49 5.5177e-51 +1.2338e-50 5.0846e-49 1.9686e-47 7.1597e-46 2.4462e-44 7.8516e-43 2.3674e-41 6.7057e-40 1.7843e-38 4.4602e-37 1.0474e-35 2.3105e-34 4.788e-33 9.3211e-32 1.7046e-30 2.9286e-29 4.7265e-28 7.166e-27 1.0206e-25 1.3656e-24 1.7165e-23 2.0267e-22 2.2481e-21 2.3426e-20 2.2931e-19 2.1087e-18 1.8217e-17 1.4783e-16 1.127e-15 8.0714e-15 5.4303e-14 3.4321e-13 2.0377e-12 1.1365e-11 5.9551e-11 2.9312e-10 1.3554e-09 5.8874e-09 2.4024e-08 9.2095e-08 3.3165e-07 1.1219e-06 3.5655e-06 1.0645e-05 2.9854e-05 7.8655e-05 0.00019467 0.00045263 0.00098862 0.0020285 0.0039101 0.0070803 0.012044 0.019246 0.028892 0.040744 0.053977 0.067176 0.078536 0.086255 0.088993 0.086255 0.078536 0.067176 0.053977 0.040744 0.028892 0.019246 0.012044 0.0070803 0.0039101 0.0020285 0.00098862 0.00045263 0.00019467 7.8655e-05 2.9854e-05 1.0645e-05 3.5655e-06 1.1219e-06 3.3165e-07 9.2095e-08 2.4024e-08 5.8874e-09 1.3554e-09 2.9312e-10 5.9551e-11 1.1365e-11 2.0377e-12 3.4321e-13 5.4303e-14 8.0714e-15 1.127e-15 1.4783e-16 1.8217e-17 2.1087e-18 2.2931e-19 2.3426e-20 2.2481e-21 2.0267e-22 1.7165e-23 1.3656e-24 1.0206e-25 7.166e-27 4.7265e-28 2.9286e-29 1.7046e-30 9.3211e-32 4.788e-33 2.3105e-34 1.0474e-35 4.4602e-37 1.7843e-38 6.7057e-40 2.3674e-41 7.8516e-43 2.4462e-44 7.1597e-46 1.9686e-47 5.0846e-49 1.2338e-50 +2.1742e-50 8.9606e-49 3.4692e-47 1.2617e-45 4.311e-44 1.3837e-42 4.172e-41 1.1817e-39 3.1445e-38 7.8602e-37 1.8458e-35 4.0717e-34 8.4378e-33 1.6426e-31 3.0041e-30 5.161e-29 8.3295e-28 1.2629e-26 1.7987e-25 2.4066e-24 3.0249e-23 3.5717e-22 3.9618e-21 4.1283e-20 4.0412e-19 3.7162e-18 3.2103e-17 2.6053e-16 1.9861e-15 1.4224e-14 9.5698e-14 6.0483e-13 3.591e-12 2.0029e-11 1.0495e-10 5.1656e-10 2.3885e-09 1.0375e-08 4.2338e-08 1.623e-07 5.8446e-07 1.9772e-06 6.2835e-06 1.8759e-05 5.2611e-05 0.00013861 0.00034307 0.00079766 0.0017422 0.0035749 0.0068907 0.012477 0.021225 0.033917 0.050916 0.071803 0.095123 0.11838 0.1384 0.15201 0.15683 0.15201 0.1384 0.11838 0.095123 0.071803 0.050916 0.033917 0.021225 0.012477 0.0068907 0.0035749 0.0017422 0.00079766 0.00034307 0.00013861 5.2611e-05 1.8759e-05 6.2835e-06 1.9772e-06 5.8446e-07 1.623e-07 4.2338e-08 1.0375e-08 2.3885e-09 5.1656e-10 1.0495e-10 2.0029e-11 3.591e-12 6.0483e-13 9.5698e-14 1.4224e-14 1.9861e-15 2.6053e-16 3.2103e-17 3.7162e-18 4.0412e-19 4.1283e-20 3.9618e-21 3.5717e-22 3.0249e-23 2.4066e-24 1.7987e-25 1.2629e-26 8.3295e-28 5.161e-29 3.0041e-30 1.6426e-31 8.4378e-33 4.0717e-34 1.8458e-35 7.8602e-37 3.1445e-38 1.1817e-39 4.172e-41 1.3837e-42 4.311e-44 1.2617e-45 3.4692e-47 8.9606e-49 2.1742e-50 +3.3592e-50 1.3844e-48 5.36e-47 1.9494e-45 6.6605e-44 2.1378e-42 6.4459e-41 1.8258e-39 4.8583e-38 1.2144e-36 2.8518e-35 6.2909e-34 1.3037e-32 2.5379e-31 4.6414e-30 7.9739e-29 1.2869e-27 1.9511e-26 2.779e-25 3.7182e-24 4.6735e-23 5.5183e-22 6.1211e-21 6.3783e-20 6.2437e-19 5.7416e-18 4.96e-17 4.0252e-16 3.0686e-15 2.1977e-14 1.4785e-13 9.3447e-13 5.5482e-12 3.0945e-11 1.6214e-10 7.9809e-10 3.6904e-09 1.603e-08 6.5413e-08 2.5075e-07 9.03e-07 3.0548e-06 9.7082e-06 2.8983e-05 8.1285e-05 0.00021416 0.00053005 0.0012324 0.0026918 0.0055232 0.010646 0.019278 0.032793 0.052403 0.078666 0.11094 0.14697 0.1829 0.21384 0.23485 0.24231 0.23485 0.21384 0.1829 0.14697 0.11094 0.078666 0.052403 0.032793 0.019278 0.010646 0.0055232 0.0026918 0.0012324 0.00053005 0.00021416 8.1285e-05 2.8983e-05 9.7082e-06 3.0548e-06 9.03e-07 2.5075e-07 6.5413e-08 1.603e-08 3.6904e-09 7.9809e-10 1.6214e-10 3.0945e-11 5.5482e-12 9.3447e-13 1.4785e-13 2.1977e-14 3.0686e-15 4.0252e-16 4.96e-17 5.7416e-18 6.2437e-19 6.3783e-20 6.1211e-21 5.5183e-22 4.6735e-23 3.7182e-24 2.779e-25 1.9511e-26 1.2869e-27 7.9739e-29 4.6414e-30 2.5379e-31 1.3037e-32 6.2909e-34 2.8518e-35 1.2144e-36 4.8583e-38 1.8258e-39 6.4459e-41 2.1378e-42 6.6605e-44 1.9494e-45 5.36e-47 1.3844e-48 3.3592e-50 +4.7712e-50 1.9664e-48 7.6129e-47 2.7688e-45 9.4602e-44 3.0364e-42 9.1553e-41 2.5933e-39 6.9004e-38 1.7249e-36 4.0504e-35 8.9351e-34 1.8516e-32 3.6047e-31 6.5923e-30 1.1326e-28 1.8279e-27 2.7713e-26 3.9471e-25 5.2811e-24 6.638e-23 7.8379e-22 8.694e-21 9.0594e-20 8.8681e-19 8.155e-18 7.0448e-17 5.7171e-16 4.3585e-15 3.1214e-14 2.1e-13 1.3273e-12 7.8803e-12 4.3953e-11 2.303e-10 1.1336e-09 5.2415e-09 2.2768e-08 9.2908e-08 3.5615e-07 1.2826e-06 4.3388e-06 1.3789e-05 4.1166e-05 0.00011545 0.00030418 0.00075284 0.0017504 0.0038233 0.0078448 0.015121 0.027381 0.046577 0.07443 0.11173 0.15757 0.20874 0.25978 0.30372 0.33357 0.34416 0.33357 0.30372 0.25978 0.20874 0.15757 0.11173 0.07443 0.046577 0.027381 0.015121 0.0078448 0.0038233 0.0017504 0.00075284 0.00030418 0.00011545 4.1166e-05 1.3789e-05 4.3388e-06 1.2826e-06 3.5615e-07 9.2908e-08 2.2768e-08 5.2415e-09 1.1336e-09 2.303e-10 4.3953e-11 7.8803e-12 1.3273e-12 2.1e-13 3.1214e-14 4.3585e-15 5.7171e-16 7.0448e-17 8.155e-18 8.8681e-19 9.0594e-20 8.694e-21 7.8379e-22 6.638e-23 5.2811e-24 3.9471e-25 2.7713e-26 1.8279e-27 1.1326e-28 6.5923e-30 3.6047e-31 1.8516e-32 8.9351e-34 4.0504e-35 1.7249e-36 6.9004e-38 2.5933e-39 9.1553e-41 3.0364e-42 9.4602e-44 2.7688e-45 7.6129e-47 1.9664e-48 4.7712e-50 +6.3895e-50 2.6333e-48 1.0195e-46 3.708e-45 1.2669e-43 4.0663e-42 1.2261e-40 3.4728e-39 9.2408e-38 2.3099e-36 5.4242e-35 1.1966e-33 2.4797e-32 4.8273e-31 8.8282e-30 1.5167e-28 2.4478e-27 3.7112e-26 5.2858e-25 7.0723e-24 8.8894e-23 1.0496e-21 1.1643e-20 1.2132e-19 1.1876e-18 1.0921e-17 9.4343e-17 7.6562e-16 5.8368e-15 4.1801e-14 2.8123e-13 1.7774e-12 1.0553e-11 5.8861e-11 3.0841e-10 1.518e-09 7.0193e-09 3.0491e-08 1.2442e-07 4.7695e-07 1.7176e-06 5.8105e-06 1.8466e-05 5.5128e-05 0.00015461 0.00040735 0.0010082 0.0023441 0.00512 0.010506 0.02025 0.036668 0.062374 0.099674 0.14963 0.21101 0.27954 0.3479 0.40673 0.44671 0.46089 0.44671 0.40673 0.3479 0.27954 0.21101 0.14963 0.099674 0.062374 0.036668 0.02025 0.010506 0.00512 0.0023441 0.0010082 0.00040735 0.00015461 5.5128e-05 1.8466e-05 5.8105e-06 1.7176e-06 4.7695e-07 1.2442e-07 3.0491e-08 7.0193e-09 1.518e-09 3.0841e-10 5.8861e-11 1.0553e-11 1.7774e-12 2.8123e-13 4.1801e-14 5.8368e-15 7.6562e-16 9.4343e-17 1.0921e-17 1.1876e-18 1.2132e-19 1.1643e-20 1.0496e-21 8.8894e-23 7.0723e-24 5.2858e-25 3.7112e-26 2.4478e-27 1.5167e-28 8.8282e-30 4.8273e-31 2.4797e-32 1.1966e-33 5.4242e-35 2.3099e-36 9.2408e-38 3.4728e-39 1.2261e-40 4.0663e-42 1.2669e-43 3.708e-45 1.0195e-46 2.6333e-48 6.3895e-50 +8.1904e-50 3.3755e-48 1.3069e-46 4.7531e-45 1.624e-43 5.2124e-42 1.5716e-40 4.4517e-39 1.1845e-37 2.961e-36 6.9531e-35 1.5338e-33 3.1786e-32 6.1879e-31 1.1317e-29 1.9442e-28 3.1378e-27 4.7573e-26 6.7757e-25 9.0658e-24 1.1395e-22 1.3455e-21 1.4924e-20 1.5552e-19 1.5223e-18 1.3999e-17 1.2093e-16 9.8141e-16 7.4819e-15 5.3583e-14 3.605e-13 2.2784e-12 1.3528e-11 7.5451e-11 3.9534e-10 1.9459e-09 8.9978e-09 3.9085e-08 1.5949e-07 6.1139e-07 2.2017e-06 7.4482e-06 2.367e-05 7.0667e-05 0.00019819 0.00052216 0.0012924 0.0030048 0.0065631 0.013467 0.025958 0.047003 0.079955 0.12777 0.1918 0.27049 0.35833 0.44596 0.52137 0.57262 0.59079 0.57262 0.52137 0.44596 0.35833 0.27049 0.1918 0.12777 0.079955 0.047003 0.025958 0.013467 0.0065631 0.0030048 0.0012924 0.00052216 0.00019819 7.0667e-05 2.367e-05 7.4482e-06 2.2017e-06 6.1139e-07 1.5949e-07 3.9085e-08 8.9978e-09 1.9459e-09 3.9534e-10 7.5451e-11 1.3528e-11 2.2784e-12 3.605e-13 5.3583e-14 7.4819e-15 9.8141e-16 1.2093e-16 1.3999e-17 1.5223e-18 1.5552e-19 1.4924e-20 1.3455e-21 1.1395e-22 9.0658e-24 6.7757e-25 4.7573e-26 3.1378e-27 1.9442e-28 1.1317e-29 6.1879e-31 3.1786e-32 1.5338e-33 6.9531e-35 2.961e-36 1.1845e-37 4.4517e-39 1.5716e-40 5.2124e-42 1.624e-43 4.7531e-45 1.3069e-46 3.3755e-48 8.1904e-50 +1.0148e-49 4.1823e-48 1.6192e-46 5.8891e-45 2.0121e-43 6.4582e-42 1.9473e-40 5.5157e-39 1.4677e-37 3.6687e-36 8.615e-35 1.9004e-33 3.9383e-32 7.6669e-31 1.4021e-29 2.4089e-28 3.8877e-27 5.8943e-26 8.3952e-25 1.1233e-23 1.4119e-22 1.6671e-21 1.8492e-20 1.9269e-19 1.8862e-18 1.7345e-17 1.4984e-16 1.216e-15 9.2702e-15 6.6391e-14 4.4666e-13 2.823e-12 1.6761e-11 9.3485e-11 4.8983e-10 2.411e-09 1.1148e-08 4.8426e-08 1.9761e-07 7.5752e-07 2.7279e-06 9.2284e-06 2.9328e-05 8.7557e-05 0.00024556 0.00064696 0.0016012 0.003723 0.0081318 0.016685 0.032162 0.058238 0.099066 0.15831 0.23765 0.33514 0.44398 0.55254 0.64599 0.70948 0.732 0.70948 0.64599 0.55254 0.44398 0.33514 0.23765 0.15831 0.099066 0.058238 0.032162 0.016685 0.0081318 0.003723 0.0016012 0.00064696 0.00024556 8.7557e-05 2.9328e-05 9.2284e-06 2.7279e-06 7.5752e-07 1.9761e-07 4.8426e-08 1.1148e-08 2.411e-09 4.8983e-10 9.3485e-11 1.6761e-11 2.823e-12 4.4666e-13 6.6391e-14 9.2702e-15 1.216e-15 1.4984e-16 1.7345e-17 1.8862e-18 1.9269e-19 1.8492e-20 1.6671e-21 1.4119e-22 1.1233e-23 8.3952e-25 5.8943e-26 3.8877e-27 2.4089e-28 1.4021e-29 7.6669e-31 3.9383e-32 1.9004e-33 8.615e-35 3.6687e-36 1.4677e-37 5.5157e-39 1.9473e-40 6.4582e-42 2.0121e-43 5.8891e-45 1.6192e-46 4.1823e-48 1.0148e-49 +1.2234e-49 5.0422e-48 1.9521e-46 7.0999e-45 2.4258e-43 7.786e-42 2.3476e-40 6.6497e-39 1.7694e-37 4.423e-36 1.0386e-34 2.2912e-33 4.748e-32 9.2432e-31 1.6904e-29 2.9041e-28 4.687e-27 7.1062e-26 1.0121e-24 1.3542e-23 1.7021e-22 2.0098e-21 2.2293e-20 2.323e-19 2.274e-18 2.0911e-17 1.8064e-16 1.466e-15 1.1176e-14 8.004e-14 5.3849e-13 3.4034e-12 2.0207e-11 1.127e-10 5.9053e-10 2.9067e-09 1.344e-08 5.8382e-08 2.3824e-07 9.1326e-07 3.2888e-06 1.1126e-05 3.5358e-05 0.00010556 0.00029604 0.00077997 0.0019305 0.0044884 0.0098037 0.020116 0.038774 0.070211 0.11943 0.19085 0.2865 0.40404 0.53526 0.66614 0.7788 0.85535 0.8825 0.85535 0.7788 0.66614 0.53526 0.40404 0.2865 0.19085 0.11943 0.070211 0.038774 0.020116 0.0098037 0.0044884 0.0019305 0.00077997 0.00029604 0.00010556 3.5358e-05 1.1126e-05 3.2888e-06 9.1326e-07 2.3824e-07 5.8382e-08 1.344e-08 2.9067e-09 5.9053e-10 1.127e-10 2.0207e-11 3.4034e-12 5.3849e-13 8.004e-14 1.1176e-14 1.466e-15 1.8064e-16 2.0911e-17 2.274e-18 2.323e-19 2.2293e-20 2.0098e-21 1.7021e-22 1.3542e-23 1.0121e-24 7.1062e-26 4.687e-27 2.9041e-28 1.6904e-29 9.2432e-31 4.748e-32 2.2912e-33 1.0386e-34 4.423e-36 1.7694e-37 6.6497e-39 2.3476e-40 7.786e-42 2.4258e-43 7.0999e-45 1.9521e-46 5.0422e-48 1.2234e-49 +1.442e-49 5.9429e-48 2.3009e-46 8.3683e-45 2.8592e-43 9.1769e-42 2.767e-40 7.8376e-39 2.0855e-37 5.2131e-36 1.2242e-34 2.7005e-33 5.5962e-32 1.0895e-30 1.9924e-29 3.423e-28 5.5244e-27 8.3757e-26 1.1929e-24 1.5961e-23 2.0062e-22 2.3689e-21 2.6276e-20 2.738e-19 2.6802e-18 2.4647e-17 2.1292e-16 1.7279e-15 1.3173e-14 9.4339e-14 6.347e-13 4.0114e-12 2.3817e-11 1.3284e-10 6.9603e-10 3.426e-09 1.5842e-08 6.8813e-08 2.808e-07 1.0764e-06 3.8763e-06 1.3113e-05 4.1674e-05 0.00012442 0.00034893 0.00091932 0.0022753 0.0052903 0.011555 0.023709 0.045701 0.082754 0.14077 0.22495 0.33769 0.47622 0.63089 0.78515 0.91793 1.0082 1.0402 1.0082 0.91793 0.78515 0.63089 0.47622 0.33769 0.22495 0.14077 0.082754 0.045701 0.023709 0.011555 0.0052903 0.0022753 0.00091932 0.00034893 0.00012442 4.1674e-05 1.3113e-05 3.8763e-06 1.0764e-06 2.808e-07 6.8813e-08 1.5842e-08 3.426e-09 6.9603e-10 1.3284e-10 2.3817e-11 4.0114e-12 6.347e-13 9.4339e-14 1.3173e-14 1.7279e-15 2.1292e-16 2.4647e-17 2.6802e-18 2.738e-19 2.6276e-20 2.3689e-21 2.0062e-22 1.5961e-23 1.1929e-24 8.3757e-26 5.5244e-27 3.423e-28 1.9924e-29 1.0895e-30 5.5962e-32 2.7005e-33 1.2242e-34 5.2131e-36 2.0855e-37 7.8376e-39 2.767e-40 9.1769e-42 2.8592e-43 8.3683e-45 2.3009e-46 5.9429e-48 1.442e-49 +1.6675e-49 6.8722e-48 2.6606e-46 9.6767e-45 3.3062e-43 1.0612e-41 3.1997e-40 9.0631e-39 2.4116e-37 6.0282e-36 1.4156e-34 3.1227e-33 6.4712e-32 1.2598e-30 2.3039e-29 3.9581e-28 6.3881e-27 9.6853e-26 1.3795e-24 1.8457e-23 2.3199e-22 2.7392e-21 3.0384e-20 3.1661e-19 3.0993e-18 2.8501e-17 2.4621e-16 1.998e-15 1.5232e-14 1.0909e-13 7.3393e-13 4.6386e-12 2.7541e-11 1.5361e-10 8.0486e-10 3.9616e-09 1.8318e-08 7.9572e-08 3.247e-07 1.2447e-06 4.4824e-06 1.5164e-05 4.819e-05 0.00014387 0.00040349 0.0010631 0.0026311 0.0061175 0.013362 0.027417 0.052847 0.095693 0.16278 0.26012 0.39049 0.55068 0.72953 0.90791 1.0615 1.1658 1.2028 1.1658 1.0615 0.90791 0.72953 0.55068 0.39049 0.26012 0.16278 0.095693 0.052847 0.027417 0.013362 0.0061175 0.0026311 0.0010631 0.00040349 0.00014387 4.819e-05 1.5164e-05 4.4824e-06 1.2447e-06 3.247e-07 7.9572e-08 1.8318e-08 3.9616e-09 8.0486e-10 1.5361e-10 2.7541e-11 4.6386e-12 7.3393e-13 1.0909e-13 1.5232e-14 1.998e-15 2.4621e-16 2.8501e-17 3.0993e-18 3.1661e-19 3.0384e-20 2.7392e-21 2.3199e-22 1.8457e-23 1.3795e-24 9.6853e-26 6.3881e-27 3.9581e-28 2.3039e-29 1.2598e-30 6.4712e-32 3.1227e-33 1.4156e-34 6.0282e-36 2.4116e-37 9.0631e-39 3.1997e-40 1.0612e-41 3.3062e-43 9.6767e-45 2.6606e-46 6.8722e-48 1.6675e-49 +1.8968e-49 7.8171e-48 3.0265e-46 1.1007e-44 3.7608e-43 1.2071e-41 3.6396e-40 1.0309e-38 2.7432e-37 6.8571e-36 1.6102e-34 3.5521e-33 7.361e-32 1.433e-30 2.6207e-29 4.5024e-28 7.2665e-27 1.1017e-25 1.5691e-24 2.0995e-23 2.6389e-22 3.1159e-21 3.4562e-20 3.6015e-19 3.5255e-18 3.242e-17 2.8006e-16 2.2728e-15 1.7327e-14 1.2409e-13 8.3485e-13 5.2764e-12 3.1328e-11 1.7473e-10 9.1553e-10 4.5064e-09 2.0837e-08 9.0513e-08 3.6935e-07 1.4159e-06 5.0987e-06 1.7249e-05 5.4816e-05 0.00016365 0.00045897 0.0012092 0.0029929 0.0069586 0.015199 0.031186 0.060113 0.10885 0.18516 0.29589 0.44418 0.6264 0.82984 1.0328 1.2074 1.3261 1.3682 1.3261 1.2074 1.0328 0.82984 0.6264 0.44418 0.29589 0.18516 0.10885 0.060113 0.031186 0.015199 0.0069586 0.0029929 0.0012092 0.00045897 0.00016365 5.4816e-05 1.7249e-05 5.0987e-06 1.4159e-06 3.6935e-07 9.0513e-08 2.0837e-08 4.5064e-09 9.1553e-10 1.7473e-10 3.1328e-11 5.2764e-12 8.3485e-13 1.2409e-13 1.7327e-14 2.2728e-15 2.8006e-16 3.242e-17 3.5255e-18 3.6015e-19 3.4562e-20 3.1159e-21 2.6389e-22 2.0995e-23 1.5691e-24 1.1017e-25 7.2665e-27 4.5024e-28 2.6207e-29 1.433e-30 7.361e-32 3.5521e-33 1.6102e-34 6.8571e-36 2.7432e-37 1.0309e-38 3.6396e-40 1.2071e-41 3.7608e-43 1.1007e-44 3.0265e-46 7.8171e-48 1.8968e-49 +2.1268e-49 8.7651e-48 3.3935e-46 1.2342e-44 4.2169e-43 1.3535e-41 4.081e-40 1.156e-38 3.0759e-37 7.6887e-36 1.8055e-34 3.9829e-33 8.2537e-32 1.6068e-30 2.9385e-29 5.0484e-28 8.1478e-27 1.2353e-25 1.7594e-24 2.3541e-23 2.9589e-22 3.4938e-21 3.8754e-20 4.0382e-19 3.953e-18 3.6351e-17 3.1403e-16 2.5484e-15 1.9428e-14 1.3914e-13 9.361e-13 5.9163e-12 3.5127e-11 1.9592e-10 1.0266e-09 5.0529e-09 2.3364e-08 1.0149e-07 4.1414e-07 1.5876e-06 5.7171e-06 1.9341e-05 6.1464e-05 0.0001835 0.00051463 0.0013559 0.0033558 0.0078025 0.017042 0.034969 0.067404 0.12205 0.20762 0.33177 0.49805 0.70236 0.93048 1.158 1.3538 1.4869 1.5341 1.4869 1.3538 1.158 0.93048 0.70236 0.49805 0.33177 0.20762 0.12205 0.067404 0.034969 0.017042 0.0078025 0.0033558 0.0013559 0.00051463 0.0001835 6.1464e-05 1.9341e-05 5.7171e-06 1.5876e-06 4.1414e-07 1.0149e-07 2.3364e-08 5.0529e-09 1.0266e-09 1.9592e-10 3.5127e-11 5.9163e-12 9.361e-13 1.3914e-13 1.9428e-14 2.5484e-15 3.1403e-16 3.6351e-17 3.953e-18 4.0382e-19 3.8754e-20 3.4938e-21 2.9589e-22 2.3541e-23 1.7594e-24 1.2353e-25 8.1478e-27 5.0484e-28 2.9385e-29 1.6068e-30 8.2537e-32 3.9829e-33 1.8055e-34 7.6887e-36 3.0759e-37 1.156e-38 4.081e-40 1.3535e-41 4.2169e-43 1.2342e-44 3.3935e-46 8.7651e-48 2.1268e-49 +2.3546e-49 9.7038e-48 3.7569e-46 1.3664e-44 4.6685e-43 1.4984e-41 4.5181e-40 1.2797e-38 3.4053e-37 8.5121e-36 1.9989e-34 4.4094e-33 9.1376e-32 1.7789e-30 3.2532e-29 5.5891e-28 9.0203e-27 1.3676e-25 1.9478e-24 2.6062e-23 3.2758e-22 3.8679e-21 4.2904e-20 4.4707e-19 4.3763e-18 4.0244e-17 3.4766e-16 2.8213e-15 2.1509e-14 1.5404e-13 1.0363e-12 6.5499e-12 3.8889e-11 2.169e-10 1.1365e-09 5.594e-09 2.5866e-08 1.1236e-07 4.5849e-07 1.7576e-06 6.3293e-06 2.1412e-05 6.8046e-05 0.00020315 0.00056975 0.0015011 0.0037152 0.0086381 0.018867 0.038713 0.074622 0.13512 0.22985 0.3673 0.55139 0.77758 1.0301 1.282 1.4988 1.6461 1.6984 1.6461 1.4988 1.282 1.0301 0.77758 0.55139 0.3673 0.22985 0.13512 0.074622 0.038713 0.018867 0.0086381 0.0037152 0.0015011 0.00056975 0.00020315 6.8046e-05 2.1412e-05 6.3293e-06 1.7576e-06 4.5849e-07 1.1236e-07 2.5866e-08 5.594e-09 1.1365e-09 2.169e-10 3.8889e-11 6.5499e-12 1.0363e-12 1.5404e-13 2.1509e-14 2.8213e-15 3.4766e-16 4.0244e-17 4.3763e-18 4.4707e-19 4.2904e-20 3.8679e-21 3.2758e-22 2.6062e-23 1.9478e-24 1.3676e-25 9.0203e-27 5.5891e-28 3.2532e-29 1.7789e-30 9.1376e-32 4.4094e-33 1.9989e-34 8.5121e-36 3.4053e-37 1.2797e-38 4.5181e-40 1.4984e-41 4.6685e-43 1.3664e-44 3.7569e-46 9.7038e-48 2.3546e-49 +2.5771e-49 1.0621e-47 4.112e-46 1.4956e-44 5.1098e-43 1.6401e-41 4.9452e-40 1.4007e-38 3.7272e-37 9.3168e-36 2.1878e-34 4.8262e-33 1.0001e-31 1.947e-30 3.5608e-29 6.1174e-28 9.873e-27 1.4969e-25 2.132e-24 2.8526e-23 3.5854e-22 4.2336e-21 4.696e-20 4.8933e-19 4.79e-18 4.4048e-17 3.8052e-16 3.088e-15 2.3542e-14 1.686e-13 1.1343e-12 7.1691e-12 4.2565e-11 2.3741e-10 1.2439e-09 6.1228e-09 2.8312e-08 1.2298e-07 5.0184e-07 1.9237e-06 6.9276e-06 2.3436e-05 7.4479e-05 0.00022235 0.00062361 0.001643 0.0040664 0.0094547 0.020651 0.042373 0.081676 0.1479 0.25158 0.40202 0.60351 0.85109 1.1275 1.4032 1.6405 1.8017 1.8589 1.8017 1.6405 1.4032 1.1275 0.85109 0.60351 0.40202 0.25158 0.1479 0.081676 0.042373 0.020651 0.0094547 0.0040664 0.001643 0.00062361 0.00022235 7.4479e-05 2.3436e-05 6.9276e-06 1.9237e-06 5.0184e-07 1.2298e-07 2.8312e-08 6.1228e-09 1.2439e-09 2.3741e-10 4.2565e-11 7.1691e-12 1.1343e-12 1.686e-13 2.3542e-14 3.088e-15 3.8052e-16 4.4048e-17 4.79e-18 4.8933e-19 4.696e-20 4.2336e-21 3.5854e-22 2.8526e-23 2.132e-24 1.4969e-25 9.873e-27 6.1174e-28 3.5608e-29 1.947e-30 1.0001e-31 4.8262e-33 2.1878e-34 9.3168e-36 3.7272e-37 1.4007e-38 4.9452e-40 1.6401e-41 5.1098e-43 1.4956e-44 4.112e-46 1.0621e-47 2.5771e-49 +2.7918e-49 1.1506e-47 4.4545e-46 1.6201e-44 5.5354e-43 1.7767e-41 5.357e-40 1.5174e-38 4.0376e-37 1.0093e-35 2.37e-34 5.2282e-33 1.0834e-31 2.1092e-30 3.8573e-29 6.6269e-28 1.0695e-26 1.6216e-25 2.3095e-24 3.0901e-23 3.8841e-22 4.5862e-21 5.0871e-20 5.3009e-19 5.189e-18 4.7717e-17 4.1221e-16 3.3452e-15 2.5503e-14 1.8264e-13 1.2288e-12 7.7662e-12 4.611e-11 2.5718e-10 1.3475e-09 6.6328e-09 3.067e-08 1.3322e-07 5.4363e-07 2.084e-06 7.5046e-06 2.5388e-05 8.0682e-05 0.00024087 0.00067554 0.0017798 0.0044051 0.010242 0.022371 0.045902 0.088479 0.16021 0.27253 0.43551 0.65377 0.92197 1.2214 1.5201 1.7771 1.9518 2.0138 1.9518 1.7771 1.5201 1.2214 0.92197 0.65377 0.43551 0.27253 0.16021 0.088479 0.045902 0.022371 0.010242 0.0044051 0.0017798 0.00067554 0.00024087 8.0682e-05 2.5388e-05 7.5046e-06 2.084e-06 5.4363e-07 1.3322e-07 3.067e-08 6.6328e-09 1.3475e-09 2.5718e-10 4.611e-11 7.7662e-12 1.2288e-12 1.8264e-13 2.5503e-14 3.3452e-15 4.1221e-16 4.7717e-17 5.189e-18 5.3009e-19 5.0871e-20 4.5862e-21 3.8841e-22 3.0901e-23 2.3095e-24 1.6216e-25 1.0695e-26 6.6269e-28 3.8573e-29 2.1092e-30 1.0834e-31 5.2282e-33 2.37e-34 1.0093e-35 4.0376e-37 1.5174e-38 5.357e-40 1.7767e-41 5.5354e-43 1.6201e-44 4.4545e-46 1.1506e-47 2.7918e-49 +2.9959e-49 1.2347e-47 4.7802e-46 1.7386e-44 5.9401e-43 1.9066e-41 5.7487e-40 1.6283e-38 4.3328e-37 1.0831e-35 2.5433e-34 5.6105e-33 1.1627e-31 2.2634e-30 4.1394e-29 7.1114e-28 1.1477e-26 1.7401e-25 2.4784e-24 3.3161e-23 4.168e-22 4.9215e-21 5.4591e-20 5.6885e-19 5.5684e-18 5.1206e-17 4.4235e-16 3.5898e-15 2.7367e-14 1.96e-13 1.3186e-12 8.334e-12 4.9481e-11 2.7598e-10 1.4461e-09 7.1177e-09 3.2912e-08 1.4296e-07 5.8338e-07 2.2363e-06 8.0533e-06 2.7244e-05 8.6581e-05 0.00025848 0.00072494 0.00191 0.0047272 0.010991 0.024007 0.049258 0.094948 0.17193 0.29246 0.46735 0.70158 0.98938 1.3107 1.6312 1.9071 2.0945 2.161 2.0945 1.9071 1.6312 1.3107 0.98938 0.70158 0.46735 0.29246 0.17193 0.094948 0.049258 0.024007 0.010991 0.0047272 0.00191 0.00072494 0.00025848 8.6581e-05 2.7244e-05 8.0533e-06 2.2363e-06 5.8338e-07 1.4296e-07 3.2912e-08 7.1177e-09 1.4461e-09 2.7598e-10 4.9481e-11 8.334e-12 1.3186e-12 1.96e-13 2.7367e-14 3.5898e-15 4.4235e-16 5.1206e-17 5.5684e-18 5.6885e-19 5.4591e-20 4.9215e-21 4.168e-22 3.3161e-23 2.4784e-24 1.7401e-25 1.1477e-26 7.1114e-28 4.1394e-29 2.2634e-30 1.1627e-31 5.6105e-33 2.5433e-34 1.0831e-35 4.3328e-37 1.6283e-38 5.7487e-40 1.9066e-41 5.9401e-43 1.7386e-44 4.7802e-46 1.2347e-47 2.9959e-49 +3.1872e-49 1.3135e-47 5.0854e-46 1.8496e-44 6.3194e-43 2.0283e-41 6.1157e-40 1.7323e-38 4.6094e-37 1.1522e-35 2.7057e-34 5.9686e-33 1.2369e-31 2.4079e-30 4.4036e-29 7.5654e-28 1.221e-26 1.8512e-25 2.6366e-24 3.5278e-23 4.4341e-22 5.2357e-21 5.8076e-20 6.0516e-19 5.9239e-18 5.4475e-17 4.7059e-16 3.819e-15 2.9114e-14 2.0851e-13 1.4028e-12 8.866e-12 5.264e-11 2.936e-10 1.5384e-09 7.5721e-09 3.5013e-08 1.5209e-07 6.2062e-07 2.3791e-06 8.5674e-06 2.8983e-05 9.2109e-05 0.00027499 0.00077122 0.0020319 0.005029 0.011693 0.025539 0.052403 0.10101 0.1829 0.31113 0.49719 0.74636 1.0525 1.3944 1.7353 2.0288 2.2282 2.299 2.2282 2.0288 1.7353 1.3944 1.0525 0.74636 0.49719 0.31113 0.1829 0.10101 0.052403 0.025539 0.011693 0.005029 0.0020319 0.00077122 0.00027499 9.2109e-05 2.8983e-05 8.5674e-06 2.3791e-06 6.2062e-07 1.5209e-07 3.5013e-08 7.5721e-09 1.5384e-09 2.936e-10 5.264e-11 8.866e-12 1.4028e-12 2.0851e-13 2.9114e-14 3.819e-15 4.7059e-16 5.4475e-17 5.9239e-18 6.0516e-19 5.8076e-20 5.2357e-21 4.4341e-22 3.5278e-23 2.6366e-24 1.8512e-25 1.221e-26 7.5654e-28 4.4036e-29 2.4079e-30 1.2369e-31 5.9686e-33 2.7057e-34 1.1522e-35 4.6094e-37 1.7323e-38 6.1157e-40 2.0283e-41 6.3194e-43 1.8496e-44 5.0854e-46 1.3135e-47 3.1872e-49 +3.3634e-49 1.3862e-47 5.3667e-46 1.9519e-44 6.6689e-43 2.1405e-41 6.454e-40 1.8281e-38 4.8644e-37 1.2159e-35 2.8553e-34 6.2988e-33 1.3053e-31 2.5411e-30 4.6472e-29 7.9839e-28 1.2885e-26 1.9536e-25 2.7825e-24 3.7229e-23 4.6794e-22 5.5253e-21 6.1288e-20 6.3863e-19 6.2515e-18 5.7488e-17 4.9662e-16 4.0302e-15 3.0725e-14 2.2004e-13 1.4804e-12 9.3564e-12 5.5552e-11 3.0984e-10 1.6235e-09 7.991e-09 3.695e-08 1.605e-07 6.5495e-07 2.5107e-06 9.0413e-06 3.0586e-05 9.7203e-05 0.0002902 0.00081387 0.0021443 0.0053071 0.012339 0.026952 0.055301 0.1066 0.19302 0.32834 0.52469 0.78765 1.1108 1.4715 1.8313 2.141 2.3515 2.4261 2.3515 2.141 1.8313 1.4715 1.1108 0.78765 0.52469 0.32834 0.19302 0.1066 0.055301 0.026952 0.012339 0.0053071 0.0021443 0.00081387 0.0002902 9.7203e-05 3.0586e-05 9.0413e-06 2.5107e-06 6.5495e-07 1.605e-07 3.695e-08 7.991e-09 1.6235e-09 3.0984e-10 5.5552e-11 9.3564e-12 1.4804e-12 2.2004e-13 3.0725e-14 4.0302e-15 4.9662e-16 5.7488e-17 6.2515e-18 6.3863e-19 6.1288e-20 5.5253e-21 4.6794e-22 3.7229e-23 2.7825e-24 1.9536e-25 1.2885e-26 7.9839e-28 4.6472e-29 2.5411e-30 1.3053e-31 6.2988e-33 2.8553e-34 1.2159e-35 4.8644e-37 1.8281e-38 6.454e-40 2.1405e-41 6.6689e-43 1.9519e-44 5.3667e-46 1.3862e-47 3.3634e-49 +3.5229e-49 1.4519e-47 5.6212e-46 2.0444e-44 6.9851e-43 2.242e-41 6.76e-40 1.9148e-38 5.0951e-37 1.2736e-35 2.9907e-34 6.5974e-33 1.3672e-31 2.6616e-30 4.8676e-29 8.3625e-28 1.3496e-26 2.0462e-25 2.9144e-24 3.8994e-23 4.9013e-22 5.7873e-21 6.4194e-20 6.6892e-19 6.548e-18 6.0214e-17 5.2017e-16 4.2213e-15 3.2182e-14 2.3048e-13 1.5506e-12 9.8001e-12 5.8186e-11 3.2454e-10 1.7004e-09 8.3699e-09 3.8702e-08 1.6811e-07 6.8601e-07 2.6297e-06 9.4701e-06 3.2037e-05 0.00010181 0.00030396 0.00085247 0.002246 0.0055588 0.012925 0.02823 0.057924 0.11165 0.20217 0.34391 0.54957 0.825 1.1634 1.5413 1.9182 2.2426 2.463 2.5412 2.463 2.2426 1.9182 1.5413 1.1634 0.825 0.54957 0.34391 0.20217 0.11165 0.057924 0.02823 0.012925 0.0055588 0.002246 0.00085247 0.00030396 0.00010181 3.2037e-05 9.4701e-06 2.6297e-06 6.8601e-07 1.6811e-07 3.8702e-08 8.3699e-09 1.7004e-09 3.2454e-10 5.8186e-11 9.8001e-12 1.5506e-12 2.3048e-13 3.2182e-14 4.2213e-15 5.2017e-16 6.0214e-17 6.548e-18 6.6892e-19 6.4194e-20 5.7873e-21 4.9013e-22 3.8994e-23 2.9144e-24 2.0462e-25 1.3496e-26 8.3625e-28 4.8676e-29 2.6616e-30 1.3672e-31 6.5974e-33 2.9907e-34 1.2736e-35 5.0951e-37 1.9148e-38 6.76e-40 2.242e-41 6.9851e-43 2.0444e-44 5.6212e-46 1.4519e-47 3.5229e-49 +3.6641e-49 1.5101e-47 5.8464e-46 2.1264e-44 7.265e-43 2.3318e-41 7.0309e-40 1.9915e-38 5.2992e-37 1.3246e-35 3.1106e-34 6.8618e-33 1.422e-31 2.7683e-30 5.0626e-29 8.6976e-28 1.4037e-26 2.1282e-25 3.0312e-24 4.0557e-23 5.0977e-22 6.0192e-21 6.6767e-20 6.9572e-19 6.8104e-18 6.2627e-17 5.4101e-16 4.3905e-15 3.3471e-14 2.3971e-13 1.6127e-12 1.0193e-11 6.0518e-11 3.3754e-10 1.7686e-09 8.7053e-09 4.0253e-08 1.7485e-07 7.135e-07 2.7351e-06 9.8495e-06 3.3321e-05 0.00010589 0.00031614 0.00088663 0.002336 0.0057815 0.013442 0.029361 0.060245 0.11613 0.21028 0.35769 0.57159 0.85806 1.2101 1.6031 1.995 2.3324 2.5617 2.643 2.5617 2.3324 1.995 1.6031 1.2101 0.85806 0.57159 0.35769 0.21028 0.11613 0.060245 0.029361 0.013442 0.0057815 0.002336 0.00088663 0.00031614 0.00010589 3.3321e-05 9.8495e-06 2.7351e-06 7.135e-07 1.7485e-07 4.0253e-08 8.7053e-09 1.7686e-09 3.3754e-10 6.0518e-11 1.0193e-11 1.6127e-12 2.3971e-13 3.3471e-14 4.3905e-15 5.4101e-16 6.2627e-17 6.8104e-18 6.9572e-19 6.6767e-20 6.0192e-21 5.0977e-22 4.0557e-23 3.0312e-24 2.1282e-25 1.4037e-26 8.6976e-28 5.0626e-29 2.7683e-30 1.422e-31 6.8618e-33 3.1106e-34 1.3246e-35 5.2992e-37 1.9915e-38 7.0309e-40 2.3318e-41 7.265e-43 2.1264e-44 5.8464e-46 1.5101e-47 3.6641e-49 +3.7857e-49 1.5602e-47 6.0405e-46 2.1969e-44 7.5062e-43 2.4092e-41 7.2643e-40 2.0576e-38 5.4751e-37 1.3686e-35 3.2138e-34 7.0896e-33 1.4692e-31 2.8601e-30 5.2307e-29 8.9863e-28 1.4503e-26 2.1989e-25 3.1318e-24 4.1903e-23 5.2669e-22 6.219e-21 6.8983e-20 7.1882e-19 7.0364e-18 6.4706e-17 5.5897e-16 4.5362e-15 3.4582e-14 2.4767e-13 1.6663e-12 1.0531e-11 6.2526e-11 3.4874e-10 1.8273e-09 8.9942e-09 4.1589e-08 1.8065e-07 7.3718e-07 2.8259e-06 1.0176e-05 3.4427e-05 0.00010941 0.00032663 0.00091606 0.0024135 0.0059734 0.013889 0.030336 0.062245 0.11998 0.21726 0.36956 0.59056 0.88654 1.2502 1.6563 2.0613 2.4099 2.6467 2.7307 2.6467 2.4099 2.0613 1.6563 1.2502 0.88654 0.59056 0.36956 0.21726 0.11998 0.062245 0.030336 0.013889 0.0059734 0.0024135 0.00091606 0.00032663 0.00010941 3.4427e-05 1.0176e-05 2.8259e-06 7.3718e-07 1.8065e-07 4.1589e-08 8.9942e-09 1.8273e-09 3.4874e-10 6.2526e-11 1.0531e-11 1.6663e-12 2.4767e-13 3.4582e-14 4.5362e-15 5.5897e-16 6.4706e-17 7.0364e-18 7.1882e-19 6.8983e-20 6.219e-21 5.2669e-22 4.1903e-23 3.1318e-24 2.1989e-25 1.4503e-26 8.9863e-28 5.2307e-29 2.8601e-30 1.4692e-31 7.0896e-33 3.2138e-34 1.3686e-35 5.4751e-37 2.0576e-38 7.2643e-40 2.4092e-41 7.5062e-43 2.1969e-44 6.0405e-46 1.5602e-47 3.7857e-49 +3.8869e-49 1.6019e-47 6.2019e-46 2.2556e-44 7.7067e-43 2.4736e-41 7.4584e-40 2.1126e-38 5.6214e-37 1.4052e-35 3.2997e-34 7.279e-33 1.5084e-31 2.9366e-30 5.3704e-29 9.2264e-28 1.4891e-26 2.2576e-25 3.2155e-24 4.3023e-23 5.4076e-22 6.3851e-21 7.0826e-20 7.3802e-19 7.2244e-18 6.6435e-17 5.7391e-16 4.6574e-15 3.5506e-14 2.5429e-13 1.7108e-12 1.0813e-11 6.4197e-11 3.5806e-10 1.8761e-09 9.2346e-09 4.27e-08 1.8548e-07 7.5688e-07 2.9014e-06 1.0448e-05 3.5346e-05 0.00011233 0.00033536 0.00094053 0.002478 0.0061331 0.01426 0.031146 0.063908 0.12319 0.22306 0.37944 0.60634 0.91023 1.2836 1.7005 2.1163 2.4743 2.7174 2.8037 2.7174 2.4743 2.1163 1.7005 1.2836 0.91023 0.60634 0.37944 0.22306 0.12319 0.063908 0.031146 0.01426 0.0061331 0.002478 0.00094053 0.00033536 0.00011233 3.5346e-05 1.0448e-05 2.9014e-06 7.5688e-07 1.8548e-07 4.27e-08 9.2346e-09 1.8761e-09 3.5806e-10 6.4197e-11 1.0813e-11 1.7108e-12 2.5429e-13 3.5506e-14 4.6574e-15 5.7391e-16 6.6435e-17 7.2244e-18 7.3802e-19 7.0826e-20 6.3851e-21 5.4076e-22 4.3023e-23 3.2155e-24 2.2576e-25 1.4891e-26 9.2264e-28 5.3704e-29 2.9366e-30 1.5084e-31 7.279e-33 3.2997e-34 1.4052e-35 5.6214e-37 2.1126e-38 7.4584e-40 2.4736e-41 7.7067e-43 2.2556e-44 6.2019e-46 1.6019e-47 3.8869e-49 +3.967e-49 1.6349e-47 6.3297e-46 2.3021e-44 7.8655e-43 2.5246e-41 7.6121e-40 2.1561e-38 5.7372e-37 1.4341e-35 3.3677e-34 7.429e-33 1.5395e-31 2.9971e-30 5.4811e-29 9.4165e-28 1.5197e-26 2.3041e-25 3.2817e-24 4.3909e-23 5.519e-22 6.5167e-21 7.2285e-20 7.5323e-19 7.3733e-18 6.7803e-17 5.8573e-16 4.7534e-15 3.6238e-14 2.5953e-13 1.746e-12 1.1035e-11 6.552e-11 3.6544e-10 1.9148e-09 9.4248e-09 4.358e-08 1.893e-07 7.7247e-07 2.9612e-06 1.0664e-05 3.6075e-05 0.00011465 0.00034227 0.00095991 0.002529 0.0062594 0.014554 0.031788 0.065225 0.12572 0.22766 0.38726 0.61883 0.92898 1.3101 1.7356 2.1599 2.5252 2.7734 2.8615 2.7734 2.5252 2.1599 1.7356 1.3101 0.92898 0.61883 0.38726 0.22766 0.12572 0.065225 0.031788 0.014554 0.0062594 0.002529 0.00095991 0.00034227 0.00011465 3.6075e-05 1.0664e-05 2.9612e-06 7.7247e-07 1.893e-07 4.358e-08 9.4248e-09 1.9148e-09 3.6544e-10 6.552e-11 1.1035e-11 1.746e-12 2.5953e-13 3.6238e-14 4.7534e-15 5.8573e-16 6.7803e-17 7.3733e-18 7.5323e-19 7.2285e-20 6.5167e-21 5.519e-22 4.3909e-23 3.2817e-24 2.3041e-25 1.5197e-26 9.4165e-28 5.4811e-29 2.9971e-30 1.5395e-31 7.429e-33 3.3677e-34 1.4341e-35 5.7372e-37 2.1561e-38 7.6121e-40 2.5246e-41 7.8655e-43 2.3021e-44 6.3297e-46 1.6349e-47 3.967e-49 +4.0257e-49 1.6591e-47 6.4233e-46 2.3362e-44 7.9819e-43 2.5619e-41 7.7247e-40 2.188e-38 5.8222e-37 1.4554e-35 3.4175e-34 7.5389e-33 1.5623e-31 3.0414e-30 5.5622e-29 9.5559e-28 1.5422e-26 2.3382e-25 3.3303e-24 4.4559e-23 5.6007e-22 6.6131e-21 7.3355e-20 7.6438e-19 7.4824e-18 6.8807e-17 5.944e-16 4.8237e-15 3.6774e-14 2.6337e-13 1.7719e-12 1.1199e-11 6.6489e-11 3.7085e-10 1.9431e-09 9.5643e-09 4.4225e-08 1.921e-07 7.8391e-07 3.005e-06 1.0821e-05 3.6609e-05 0.00011634 0.00034733 0.00097412 0.0025665 0.0063521 0.014769 0.032258 0.06619 0.12758 0.23103 0.39299 0.62799 0.94273 1.3295 1.7612 2.1919 2.5626 2.8145 2.9038 2.8145 2.5626 2.1919 1.7612 1.3295 0.94273 0.62799 0.39299 0.23103 0.12758 0.06619 0.032258 0.014769 0.0063521 0.0025665 0.00097412 0.00034733 0.00011634 3.6609e-05 1.0821e-05 3.005e-06 7.8391e-07 1.921e-07 4.4225e-08 9.5643e-09 1.9431e-09 3.7085e-10 6.6489e-11 1.1199e-11 1.7719e-12 2.6337e-13 3.6774e-14 4.8237e-15 5.944e-16 6.8807e-17 7.4824e-18 7.6438e-19 7.3355e-20 6.6131e-21 5.6007e-22 4.4559e-23 3.3303e-24 2.3382e-25 1.5422e-26 9.5559e-28 5.5622e-29 3.0414e-30 1.5623e-31 7.5389e-33 3.4175e-34 1.4554e-35 5.8222e-37 2.188e-38 7.7247e-40 2.5619e-41 7.9819e-43 2.3362e-44 6.4233e-46 1.6591e-47 4.0257e-49 +4.063e-49 1.6745e-47 6.4829e-46 2.3578e-44 8.056e-43 2.5857e-41 7.7964e-40 2.2083e-38 5.8762e-37 1.4689e-35 3.4492e-34 7.6088e-33 1.5768e-31 3.0696e-30 5.6138e-29 9.6445e-28 1.5565e-26 2.3599e-25 3.3612e-24 4.4972e-23 5.6527e-22 6.6745e-21 7.4035e-20 7.7146e-19 7.5518e-18 6.9445e-17 5.9991e-16 4.8685e-15 3.7115e-14 2.6581e-13 1.7883e-12 1.1303e-11 6.7106e-11 3.7429e-10 1.9611e-09 9.653e-09 4.4635e-08 1.9389e-07 7.9118e-07 3.0329e-06 1.0922e-05 3.6948e-05 0.00011742 0.00035055 0.00098315 0.0025903 0.006411 0.014906 0.032558 0.066804 0.12877 0.23317 0.39663 0.63382 0.95147 1.3418 1.7776 2.2122 2.5864 2.8406 2.9307 2.8406 2.5864 2.2122 1.7776 1.3418 0.95147 0.63382 0.39663 0.23317 0.12877 0.066804 0.032558 0.014906 0.006411 0.0025903 0.00098315 0.00035055 0.00011742 3.6948e-05 1.0922e-05 3.0329e-06 7.9118e-07 1.9389e-07 4.4635e-08 9.653e-09 1.9611e-09 3.7429e-10 6.7106e-11 1.1303e-11 1.7883e-12 2.6581e-13 3.7115e-14 4.8685e-15 5.9991e-16 6.9445e-17 7.5518e-18 7.7146e-19 7.4035e-20 6.6745e-21 5.6527e-22 4.4972e-23 3.3612e-24 2.3599e-25 1.5565e-26 9.6445e-28 5.6138e-29 3.0696e-30 1.5768e-31 7.6088e-33 3.4492e-34 1.4689e-35 5.8762e-37 2.2083e-38 7.7964e-40 2.5857e-41 8.056e-43 2.3578e-44 6.4829e-46 1.6745e-47 4.063e-49 +4.0792e-49 1.6812e-47 6.5088e-46 2.3673e-44 8.0881e-43 2.596e-41 7.8275e-40 2.2171e-38 5.8996e-37 1.4747e-35 3.463e-34 7.6392e-33 1.5831e-31 3.0819e-30 5.6362e-29 9.683e-28 1.5628e-26 2.3694e-25 3.3746e-24 4.5152e-23 5.6752e-22 6.7011e-21 7.4331e-20 7.7455e-19 7.582e-18 6.9722e-17 6.0231e-16 4.8879e-15 3.7264e-14 2.6687e-13 1.7955e-12 1.1348e-11 6.7374e-11 3.7578e-10 1.969e-09 9.6916e-09 4.4813e-08 1.9466e-07 7.9433e-07 3.045e-06 1.0965e-05 3.7096e-05 0.00011789 0.00035195 0.00098708 0.0026006 0.0064366 0.014965 0.032688 0.06707 0.12928 0.2341 0.39822 0.63635 0.95527 1.3471 1.7847 2.2211 2.5967 2.8519 2.9424 2.8519 2.5967 2.2211 1.7847 1.3471 0.95527 0.63635 0.39822 0.2341 0.12928 0.06707 0.032688 0.014965 0.0064366 0.0026006 0.00098708 0.00035195 0.00011789 3.7096e-05 1.0965e-05 3.045e-06 7.9433e-07 1.9466e-07 4.4813e-08 9.6916e-09 1.969e-09 3.7578e-10 6.7374e-11 1.1348e-11 1.7955e-12 2.6687e-13 3.7264e-14 4.8879e-15 6.0231e-16 6.9722e-17 7.582e-18 7.7455e-19 7.4331e-20 6.7011e-21 5.6752e-22 4.5152e-23 3.3746e-24 2.3694e-25 1.5628e-26 9.683e-28 5.6362e-29 3.0819e-30 1.5831e-31 7.6392e-33 3.463e-34 1.4747e-35 5.8996e-37 2.2171e-38 7.8275e-40 2.596e-41 8.0881e-43 2.3673e-44 6.5088e-46 1.6812e-47 4.0792e-49 +4.0749e-49 1.6794e-47 6.5018e-46 2.3647e-44 8.0795e-43 2.5932e-41 7.8191e-40 2.2148e-38 5.8933e-37 1.4731e-35 3.4593e-34 7.6311e-33 1.5814e-31 3.0786e-30 5.6302e-29 9.6727e-28 1.5611e-26 2.3668e-25 3.371e-24 4.5104e-23 5.6692e-22 6.694e-21 7.4252e-20 7.7372e-19 7.5739e-18 6.9648e-17 6.0167e-16 4.8827e-15 3.7224e-14 2.6659e-13 1.7935e-12 1.1336e-11 6.7302e-11 3.7538e-10 1.9669e-09 9.6812e-09 4.4765e-08 1.9445e-07 7.9349e-07 3.0417e-06 1.0954e-05 3.7056e-05 0.00011776 0.00035158 0.00098603 0.0025978 0.0064297 0.014949 0.032653 0.066999 0.12914 0.23385 0.39779 0.63567 0.95425 1.3457 1.7828 2.2187 2.5939 2.8489 2.9393 2.8489 2.5939 2.2187 1.7828 1.3457 0.95425 0.63567 0.39779 0.23385 0.12914 0.066999 0.032653 0.014949 0.0064297 0.0025978 0.00098603 0.00035158 0.00011776 3.7056e-05 1.0954e-05 3.0417e-06 7.9349e-07 1.9445e-07 4.4765e-08 9.6812e-09 1.9669e-09 3.7538e-10 6.7302e-11 1.1336e-11 1.7935e-12 2.6659e-13 3.7224e-14 4.8827e-15 6.0167e-16 6.9648e-17 7.5739e-18 7.7372e-19 7.4252e-20 6.694e-21 5.6692e-22 4.5104e-23 3.371e-24 2.3668e-25 1.5611e-26 9.6727e-28 5.6302e-29 3.0786e-30 1.5814e-31 7.6311e-33 3.4593e-34 1.4731e-35 5.8933e-37 2.2148e-38 7.8191e-40 2.5932e-41 8.0795e-43 2.3647e-44 6.5018e-46 1.6794e-47 4.0749e-49 +4.0507e-49 1.6694e-47 6.4633e-46 2.3507e-44 8.0316e-43 2.5779e-41 7.7728e-40 2.2017e-38 5.8584e-37 1.4644e-35 3.4388e-34 7.5858e-33 1.572e-31 3.0603e-30 5.5968e-29 9.6153e-28 1.5518e-26 2.3528e-25 3.351e-24 4.4836e-23 5.6356e-22 6.6543e-21 7.3811e-20 7.6913e-19 7.529e-18 6.9235e-17 5.981e-16 4.8537e-15 3.7003e-14 2.6501e-13 1.7829e-12 1.1268e-11 6.6903e-11 3.7316e-10 1.9552e-09 9.6238e-09 4.45e-08 1.933e-07 7.8878e-07 3.0237e-06 1.0889e-05 3.6836e-05 0.00011707 0.00034949 0.00098018 0.0025824 0.0063916 0.014861 0.032459 0.066602 0.12838 0.23246 0.39543 0.6319 0.94859 1.3377 1.7722 2.2055 2.5785 2.832 2.9219 2.832 2.5785 2.2055 1.7722 1.3377 0.94859 0.6319 0.39543 0.23246 0.12838 0.066602 0.032459 0.014861 0.0063916 0.0025824 0.00098018 0.00034949 0.00011707 3.6836e-05 1.0889e-05 3.0237e-06 7.8878e-07 1.933e-07 4.45e-08 9.6238e-09 1.9552e-09 3.7316e-10 6.6903e-11 1.1268e-11 1.7829e-12 2.6501e-13 3.7003e-14 4.8537e-15 5.981e-16 6.9235e-17 7.529e-18 7.6913e-19 7.3811e-20 6.6543e-21 5.6356e-22 4.4836e-23 3.351e-24 2.3528e-25 1.5518e-26 9.6153e-28 5.5968e-29 3.0603e-30 1.572e-31 7.5858e-33 3.4388e-34 1.4644e-35 5.8584e-37 2.2017e-38 7.7728e-40 2.5779e-41 8.0316e-43 2.3507e-44 6.4633e-46 1.6694e-47 4.0507e-49 +4.0077e-49 1.6517e-47 6.3947e-46 2.3258e-44 7.9464e-43 2.5505e-41 7.6903e-40 2.1783e-38 5.7962e-37 1.4489e-35 3.4023e-34 7.5053e-33 1.5553e-31 3.0279e-30 5.5374e-29 9.5133e-28 1.5354e-26 2.3278e-25 3.3155e-24 4.436e-23 5.5757e-22 6.5837e-21 7.3028e-20 7.6097e-19 7.449e-18 6.85e-17 5.9175e-16 4.8022e-15 3.661e-14 2.6219e-13 1.764e-12 1.1149e-11 6.6193e-11 3.692e-10 1.9344e-09 9.5217e-09 4.4028e-08 1.9125e-07 7.8041e-07 2.9916e-06 1.0773e-05 3.6445e-05 0.00011582 0.00034578 0.00096978 0.002555 0.0063237 0.014703 0.032115 0.065895 0.12702 0.23 0.39124 0.62519 0.93853 1.3235 1.7534 2.1821 2.5512 2.8019 2.8909 2.8019 2.5512 2.1821 1.7534 1.3235 0.93853 0.62519 0.39124 0.23 0.12702 0.065895 0.032115 0.014703 0.0063237 0.002555 0.00096978 0.00034578 0.00011582 3.6445e-05 1.0773e-05 2.9916e-06 7.8041e-07 1.9125e-07 4.4028e-08 9.5217e-09 1.9344e-09 3.692e-10 6.6193e-11 1.1149e-11 1.764e-12 2.6219e-13 3.661e-14 4.8022e-15 5.9175e-16 6.85e-17 7.449e-18 7.6097e-19 7.3028e-20 6.5837e-21 5.5757e-22 4.436e-23 3.3155e-24 2.3278e-25 1.5354e-26 9.5133e-28 5.5374e-29 3.0279e-30 1.5553e-31 7.5053e-33 3.4023e-34 1.4489e-35 5.7962e-37 2.1783e-38 7.6903e-40 2.5505e-41 7.9464e-43 2.3258e-44 6.3947e-46 1.6517e-47 4.0077e-49 +3.9471e-49 1.6267e-47 6.2979e-46 2.2906e-44 7.8261e-43 2.5119e-41 7.5739e-40 2.1453e-38 5.7085e-37 1.4269e-35 3.3508e-34 7.3917e-33 1.5318e-31 2.982e-30 5.4536e-29 9.3693e-28 1.5121e-26 2.2926e-25 3.2653e-24 4.3689e-23 5.4913e-22 6.484e-21 7.1922e-20 7.4945e-19 7.3363e-18 6.7463e-17 5.8279e-16 4.7295e-15 3.6056e-14 2.5822e-13 1.7373e-12 1.098e-11 6.5191e-11 3.6361e-10 1.9052e-09 9.3775e-09 4.3361e-08 1.8835e-07 7.686e-07 2.9463e-06 1.061e-05 3.5894e-05 0.00011407 0.00034055 0.0009551 0.0025163 0.006228 0.014481 0.031628 0.064897 0.12509 0.22651 0.38531 0.61573 0.92432 1.3035 1.7269 2.1491 2.5126 2.7595 2.8471 2.7595 2.5126 2.1491 1.7269 1.3035 0.92432 0.61573 0.38531 0.22651 0.12509 0.064897 0.031628 0.014481 0.006228 0.0025163 0.0009551 0.00034055 0.00011407 3.5894e-05 1.061e-05 2.9463e-06 7.686e-07 1.8835e-07 4.3361e-08 9.3775e-09 1.9052e-09 3.6361e-10 6.5191e-11 1.098e-11 1.7373e-12 2.5822e-13 3.6056e-14 4.7295e-15 5.8279e-16 6.7463e-17 7.3363e-18 7.4945e-19 7.1922e-20 6.484e-21 5.4913e-22 4.3689e-23 3.2653e-24 2.2926e-25 1.5121e-26 9.3693e-28 5.4536e-29 2.982e-30 1.5318e-31 7.3917e-33 3.3508e-34 1.4269e-35 5.7085e-37 2.1453e-38 7.5739e-40 2.5119e-41 7.8261e-43 2.2906e-44 6.2979e-46 1.6267e-47 3.9471e-49 +3.87e-49 1.595e-47 6.175e-46 2.2459e-44 7.6734e-43 2.4629e-41 7.4261e-40 2.1034e-38 5.5971e-37 1.3991e-35 3.2854e-34 7.2475e-33 1.5019e-31 2.9238e-30 5.3471e-29 9.1864e-28 1.4826e-26 2.2478e-25 3.2016e-24 4.2836e-23 5.3842e-22 6.3575e-21 7.0519e-20 7.3482e-19 7.1931e-18 6.6147e-17 5.7142e-16 4.6372e-15 3.5353e-14 2.5319e-13 1.7034e-12 1.0766e-11 6.3919e-11 3.5651e-10 1.868e-09 9.1945e-09 4.2515e-08 1.8468e-07 7.536e-07 2.8888e-06 1.0403e-05 3.5193e-05 0.00011184 0.0003339 0.00093646 0.0024672 0.0061065 0.014198 0.031011 0.063631 0.12265 0.22209 0.37779 0.60371 0.90628 1.2781 1.6932 2.1072 2.4635 2.7057 2.7915 2.7057 2.4635 2.1072 1.6932 1.2781 0.90628 0.60371 0.37779 0.22209 0.12265 0.063631 0.031011 0.014198 0.0061065 0.0024672 0.00093646 0.0003339 0.00011184 3.5193e-05 1.0403e-05 2.8888e-06 7.536e-07 1.8468e-07 4.2515e-08 9.1945e-09 1.868e-09 3.5651e-10 6.3919e-11 1.0766e-11 1.7034e-12 2.5319e-13 3.5353e-14 4.6372e-15 5.7142e-16 6.6147e-17 7.1931e-18 7.3482e-19 7.0519e-20 6.3575e-21 5.3842e-22 4.2836e-23 3.2016e-24 2.2478e-25 1.4826e-26 9.1864e-28 5.3471e-29 2.9238e-30 1.5019e-31 7.2475e-33 3.2854e-34 1.3991e-35 5.5971e-37 2.1034e-38 7.4261e-40 2.4629e-41 7.6734e-43 2.2459e-44 6.175e-46 1.595e-47 3.87e-49 +3.7781e-49 1.5571e-47 6.0283e-46 2.1925e-44 7.4911e-43 2.4044e-41 7.2497e-40 2.0535e-38 5.4641e-37 1.3659e-35 3.2073e-34 7.0753e-33 1.4662e-31 2.8544e-30 5.2201e-29 8.9682e-28 1.4474e-26 2.1944e-25 3.1255e-24 4.1819e-23 5.2563e-22 6.2064e-21 6.8844e-20 7.1737e-19 7.0222e-18 6.4575e-17 5.5785e-16 4.5271e-15 3.4513e-14 2.4717e-13 1.6629e-12 1.051e-11 6.24e-11 3.4804e-10 1.8236e-09 8.9761e-09 4.1505e-08 1.8029e-07 7.357e-07 2.8202e-06 1.0156e-05 3.4357e-05 0.00010919 0.00032597 0.00091421 0.0024086 0.0059614 0.013861 0.030275 0.062119 0.11974 0.21682 0.36882 0.58937 0.88475 1.2477 1.6529 2.0571 2.405 2.6414 2.7252 2.6414 2.405 2.0571 1.6529 1.2477 0.88475 0.58937 0.36882 0.21682 0.11974 0.062119 0.030275 0.013861 0.0059614 0.0024086 0.00091421 0.00032597 0.00010919 3.4357e-05 1.0156e-05 2.8202e-06 7.357e-07 1.8029e-07 4.1505e-08 8.9761e-09 1.8236e-09 3.4804e-10 6.24e-11 1.051e-11 1.6629e-12 2.4717e-13 3.4513e-14 4.5271e-15 5.5785e-16 6.4575e-17 7.0222e-18 7.1737e-19 6.8844e-20 6.2064e-21 5.2563e-22 4.1819e-23 3.1255e-24 2.1944e-25 1.4474e-26 8.9682e-28 5.2201e-29 2.8544e-30 1.4662e-31 7.0753e-33 3.2073e-34 1.3659e-35 5.4641e-37 2.0535e-38 7.2497e-40 2.4044e-41 7.4911e-43 2.1925e-44 6.0283e-46 1.5571e-47 3.7781e-49 +3.6728e-49 1.5137e-47 5.8602e-46 2.1314e-44 7.2822e-43 2.3373e-41 7.0475e-40 1.9962e-38 5.3118e-37 1.3278e-35 3.1179e-34 6.878e-33 1.4253e-31 2.7748e-30 5.0746e-29 8.7182e-28 1.407e-26 2.1333e-25 3.0384e-24 4.0653e-23 5.1097e-22 6.0334e-21 6.6924e-20 6.9737e-19 6.8265e-18 6.2775e-17 5.4229e-16 4.4009e-15 3.3551e-14 2.4028e-13 1.6166e-12 1.0217e-11 6.0661e-11 3.3834e-10 1.7728e-09 8.7259e-09 4.0348e-08 1.7526e-07 7.1519e-07 2.7416e-06 9.8728e-06 3.3399e-05 0.00010614 0.00031688 0.00088872 0.0023415 0.0057952 0.013474 0.02943 0.060387 0.1164 0.21077 0.35854 0.57294 0.86008 1.2129 1.6069 1.9998 2.338 2.5677 2.6492 2.5677 2.338 1.9998 1.6069 1.2129 0.86008 0.57294 0.35854 0.21077 0.1164 0.060387 0.02943 0.013474 0.0057952 0.0023415 0.00088872 0.00031688 0.00010614 3.3399e-05 9.8728e-06 2.7416e-06 7.1519e-07 1.7526e-07 4.0348e-08 8.7259e-09 1.7728e-09 3.3834e-10 6.0661e-11 1.0217e-11 1.6166e-12 2.4028e-13 3.3551e-14 4.4009e-15 5.4229e-16 6.2775e-17 6.8265e-18 6.9737e-19 6.6924e-20 6.0334e-21 5.1097e-22 4.0653e-23 3.0384e-24 2.1333e-25 1.407e-26 8.7182e-28 5.0746e-29 2.7748e-30 1.4253e-31 6.878e-33 3.1179e-34 1.3278e-35 5.3118e-37 1.9962e-38 7.0475e-40 2.3373e-41 7.2822e-43 2.1314e-44 5.8602e-46 1.5137e-47 3.6728e-49 +3.5556e-49 1.4654e-47 5.6734e-46 2.0634e-44 7.05e-43 2.2628e-41 6.8228e-40 1.9326e-38 5.1424e-37 1.2854e-35 3.0185e-34 6.6587e-33 1.3799e-31 2.6863e-30 4.9128e-29 8.4402e-28 1.3622e-26 2.0652e-25 2.9415e-24 3.9356e-23 4.9468e-22 5.841e-21 6.479e-20 6.7513e-19 6.6088e-18 6.0773e-17 5.25e-16 4.2605e-15 3.2481e-14 2.3262e-13 1.565e-12 9.8911e-12 5.8726e-11 3.2755e-10 1.7162e-09 8.4476e-09 3.9061e-08 1.6967e-07 6.9238e-07 2.6542e-06 9.558e-06 3.2334e-05 0.00010276 0.00030678 0.00086038 0.0022668 0.0056104 0.013045 0.028492 0.058462 0.11269 0.20405 0.3471 0.55467 0.83266 1.1742 1.5556 1.936 2.2634 2.4859 2.5648 2.4859 2.2634 1.936 1.5556 1.1742 0.83266 0.55467 0.3471 0.20405 0.11269 0.058462 0.028492 0.013045 0.0056104 0.0022668 0.00086038 0.00030678 0.00010276 3.2334e-05 9.558e-06 2.6542e-06 6.9238e-07 1.6967e-07 3.9061e-08 8.4476e-09 1.7162e-09 3.2755e-10 5.8726e-11 9.8911e-12 1.565e-12 2.3262e-13 3.2481e-14 4.2605e-15 5.25e-16 6.0773e-17 6.6088e-18 6.7513e-19 6.479e-20 5.841e-21 4.9468e-22 3.9356e-23 2.9415e-24 2.0652e-25 1.3622e-26 8.4402e-28 4.9128e-29 2.6863e-30 1.3799e-31 6.6587e-33 3.0185e-34 1.2854e-35 5.1424e-37 1.9326e-38 6.8228e-40 2.2628e-41 7.05e-43 2.0634e-44 5.6734e-46 1.4654e-47 3.5556e-49 +3.4284e-49 1.4129e-47 5.4703e-46 1.9896e-44 6.7976e-43 2.1818e-41 6.5786e-40 1.8634e-38 4.9583e-37 1.2394e-35 2.9105e-34 6.4204e-33 1.3305e-31 2.5902e-30 4.7369e-29 8.138e-28 1.3134e-26 1.9913e-25 2.8362e-24 3.7948e-23 4.7697e-22 5.6319e-21 6.2471e-20 6.5096e-19 6.3722e-18 5.8598e-17 5.0621e-16 4.108e-15 3.1318e-14 2.2429e-13 1.509e-12 9.5371e-12 5.6624e-11 3.1582e-10 1.6548e-09 8.1452e-09 3.7663e-08 1.636e-07 6.6759e-07 2.5592e-06 9.2159e-06 3.1177e-05 9.908e-05 0.0002958 0.00082959 0.0021857 0.0054096 0.012578 0.027472 0.056369 0.10865 0.19675 0.33468 0.53482 0.80285 1.1322 1.4999 1.8667 2.1824 2.3969 2.473 2.3969 2.1824 1.8667 1.4999 1.1322 0.80285 0.53482 0.33468 0.19675 0.10865 0.056369 0.027472 0.012578 0.0054096 0.0021857 0.00082959 0.0002958 9.908e-05 3.1177e-05 9.2159e-06 2.5592e-06 6.6759e-07 1.636e-07 3.7663e-08 8.1452e-09 1.6548e-09 3.1582e-10 5.6624e-11 9.5371e-12 1.509e-12 2.2429e-13 3.1318e-14 4.108e-15 5.0621e-16 5.8598e-17 6.3722e-18 6.5096e-19 6.2471e-20 5.6319e-21 4.7697e-22 3.7948e-23 2.8362e-24 1.9913e-25 1.3134e-26 8.138e-28 4.7369e-29 2.5902e-30 1.3305e-31 6.4204e-33 2.9105e-34 1.2394e-35 4.9583e-37 1.8634e-38 6.5786e-40 2.1818e-41 6.7976e-43 1.9896e-44 5.4703e-46 1.4129e-47 3.4284e-49 +3.2926e-49 1.357e-47 5.2536e-46 1.9108e-44 6.5284e-43 2.0954e-41 6.318e-40 1.7896e-38 4.7619e-37 1.1903e-35 2.7952e-34 6.1661e-33 1.2778e-31 2.4876e-30 4.5493e-29 7.8157e-28 1.2614e-26 1.9124e-25 2.7238e-24 3.6445e-23 4.5808e-22 5.4089e-21 5.9997e-20 6.2518e-19 6.1198e-18 5.6277e-17 4.8616e-16 3.9453e-15 3.0078e-14 2.1541e-13 1.4492e-12 9.1593e-12 5.4381e-11 3.0332e-10 1.5893e-09 7.8226e-09 3.6171e-08 1.5712e-07 6.4115e-07 2.4578e-06 8.8508e-06 2.9942e-05 9.5156e-05 0.00028408 0.00079673 0.0020991 0.0051953 0.012079 0.026384 0.054136 0.10435 0.18895 0.32142 0.51363 0.77105 1.0874 1.4405 1.7928 2.0959 2.3019 2.375 2.3019 2.0959 1.7928 1.4405 1.0874 0.77105 0.51363 0.32142 0.18895 0.10435 0.054136 0.026384 0.012079 0.0051953 0.0020991 0.00079673 0.00028408 9.5156e-05 2.9942e-05 8.8508e-06 2.4578e-06 6.4115e-07 1.5712e-07 3.6171e-08 7.8226e-09 1.5893e-09 3.0332e-10 5.4381e-11 9.1593e-12 1.4492e-12 2.1541e-13 3.0078e-14 3.9453e-15 4.8616e-16 5.6277e-17 6.1198e-18 6.2518e-19 5.9997e-20 5.4089e-21 4.5808e-22 3.6445e-23 2.7238e-24 1.9124e-25 1.2614e-26 7.8157e-28 4.5493e-29 2.4876e-30 1.2778e-31 6.1661e-33 2.7952e-34 1.1903e-35 4.7619e-37 1.7896e-38 6.318e-40 2.0954e-41 6.5284e-43 1.9108e-44 5.2536e-46 1.357e-47 3.2926e-49 +3.1499e-49 1.2982e-47 5.026e-46 1.828e-44 6.2455e-43 2.0046e-41 6.0442e-40 1.712e-38 4.5556e-37 1.1388e-35 2.6741e-34 5.8989e-33 1.2224e-31 2.3798e-30 4.3522e-29 7.477e-28 1.2067e-26 1.8296e-25 2.6058e-24 3.4865e-23 4.3823e-22 5.1745e-21 5.7397e-20 5.9809e-19 5.8546e-18 5.3838e-17 4.6509e-16 3.7744e-15 2.8774e-14 2.0607e-13 1.3864e-12 8.7624e-12 5.2025e-11 2.9017e-10 1.5204e-09 7.4836e-09 3.4604e-08 1.5031e-07 6.1337e-07 2.3513e-06 8.4673e-06 2.8645e-05 9.1032e-05 0.00027177 0.0007622 0.0020081 0.0049702 0.011556 0.025241 0.051791 0.099829 0.18077 0.30749 0.49138 0.73764 1.0402 1.3781 1.7151 2.0051 2.2022 2.2721 2.2022 2.0051 1.7151 1.3781 1.0402 0.73764 0.49138 0.30749 0.18077 0.099829 0.051791 0.025241 0.011556 0.0049702 0.0020081 0.0007622 0.00027177 9.1032e-05 2.8645e-05 8.4673e-06 2.3513e-06 6.1337e-07 1.5031e-07 3.4604e-08 7.4836e-09 1.5204e-09 2.9017e-10 5.2025e-11 8.7624e-12 1.3864e-12 2.0607e-13 2.8774e-14 3.7744e-15 4.6509e-16 5.3838e-17 5.8546e-18 5.9809e-19 5.7397e-20 5.1745e-21 4.3823e-22 3.4865e-23 2.6058e-24 1.8296e-25 1.2067e-26 7.477e-28 4.3522e-29 2.3798e-30 1.2224e-31 5.8989e-33 2.6741e-34 1.1388e-35 4.5556e-37 1.712e-38 6.0442e-40 2.0046e-41 6.2455e-43 1.828e-44 5.026e-46 1.2982e-47 3.1499e-49 +3.0019e-49 1.2372e-47 4.7899e-46 1.7421e-44 5.9521e-43 1.9104e-41 5.7603e-40 1.6316e-38 4.3416e-37 1.0853e-35 2.5484e-34 5.6218e-33 1.165e-31 2.268e-30 4.1477e-29 7.1258e-28 1.15e-26 1.7436e-25 2.4834e-24 3.3228e-23 4.1764e-22 4.9314e-21 5.4701e-20 5.6999e-19 5.5796e-18 5.1309e-17 4.4324e-16 3.5971e-15 2.7423e-14 1.9639e-13 1.3213e-12 8.3508e-12 4.9581e-11 2.7654e-10 1.449e-09 7.1321e-09 3.2978e-08 1.4325e-07 5.8456e-07 2.2408e-06 8.0696e-06 2.7299e-05 8.6756e-05 0.00025901 0.0007264 0.0019138 0.0047367 0.011013 0.024055 0.049358 0.095139 0.17228 0.29305 0.46829 0.70299 0.99138 1.3134 1.6345 1.9109 2.0987 2.1654 2.0987 1.9109 1.6345 1.3134 0.99138 0.70299 0.46829 0.29305 0.17228 0.095139 0.049358 0.024055 0.011013 0.0047367 0.0019138 0.0007264 0.00025901 8.6756e-05 2.7299e-05 8.0696e-06 2.2408e-06 5.8456e-07 1.4325e-07 3.2978e-08 7.1321e-09 1.449e-09 2.7654e-10 4.9581e-11 8.3508e-12 1.3213e-12 1.9639e-13 2.7423e-14 3.5971e-15 4.4324e-16 5.1309e-17 5.5796e-18 5.6999e-19 5.4701e-20 4.9314e-21 4.1764e-22 3.3228e-23 2.4834e-24 1.7436e-25 1.15e-26 7.1258e-28 4.1477e-29 2.268e-30 1.165e-31 5.6218e-33 2.5484e-34 1.0853e-35 4.3416e-37 1.6316e-38 5.7603e-40 1.9104e-41 5.9521e-43 1.7421e-44 4.7899e-46 1.2372e-47 3.0019e-49 +2.8502e-49 1.1747e-47 4.5478e-46 1.654e-44 5.6513e-43 1.8139e-41 5.4692e-40 1.5492e-38 4.1221e-37 1.0304e-35 2.4196e-34 5.3376e-33 1.1061e-31 2.1534e-30 3.9381e-29 6.7656e-28 1.0919e-26 1.6555e-25 2.3579e-24 3.1548e-23 3.9654e-22 4.6822e-21 5.1936e-20 5.4118e-19 5.2976e-18 4.8716e-17 4.2084e-16 3.4152e-15 2.6037e-14 1.8647e-13 1.2545e-12 7.9287e-12 4.7075e-11 2.6256e-10 1.3757e-09 6.7716e-09 3.1312e-08 1.3601e-07 5.5501e-07 2.1276e-06 7.6617e-06 2.5919e-05 8.2371e-05 0.00024591 0.00068968 0.0018171 0.0044973 0.010457 0.022839 0.046863 0.090331 0.16357 0.27824 0.44462 0.66746 0.94127 1.247 1.5519 1.8143 1.9927 2.0559 1.9927 1.8143 1.5519 1.247 0.94127 0.66746 0.44462 0.27824 0.16357 0.090331 0.046863 0.022839 0.010457 0.0044973 0.0018171 0.00068968 0.00024591 8.2371e-05 2.5919e-05 7.6617e-06 2.1276e-06 5.5501e-07 1.3601e-07 3.1312e-08 6.7716e-09 1.3757e-09 2.6256e-10 4.7075e-11 7.9287e-12 1.2545e-12 1.8647e-13 2.6037e-14 3.4152e-15 4.2084e-16 4.8716e-17 5.2976e-18 5.4118e-19 5.1936e-20 4.6822e-21 3.9654e-22 3.1548e-23 2.3579e-24 1.6555e-25 1.0919e-26 6.7656e-28 3.9381e-29 2.1534e-30 1.1061e-31 5.3376e-33 2.4196e-34 1.0304e-35 4.1221e-37 1.5492e-38 5.4692e-40 1.8139e-41 5.6513e-43 1.654e-44 4.5478e-46 1.1747e-47 2.8502e-49 +2.6962e-49 1.1112e-47 4.302e-46 1.5647e-44 5.3459e-43 1.7158e-41 5.1736e-40 1.4654e-38 3.8994e-37 9.7472e-36 2.2889e-34 5.0492e-33 1.0463e-31 2.037e-30 3.7253e-29 6.4e-28 1.0329e-26 1.566e-25 2.2305e-24 2.9843e-23 3.7511e-22 4.4291e-21 4.9129e-20 5.1194e-19 5.0113e-18 4.6083e-17 3.981e-16 3.2307e-15 2.463e-14 1.7639e-13 1.1867e-12 7.5003e-12 4.4531e-11 2.4838e-10 1.3014e-09 6.4057e-09 2.962e-08 1.2866e-07 5.2502e-07 2.0126e-06 7.2477e-06 2.4519e-05 7.792e-05 0.00023263 0.00065241 0.0017189 0.0042543 0.0098915 0.021605 0.044331 0.085449 0.15473 0.2632 0.4206 0.63139 0.8904 1.1796 1.468 1.7163 1.885 1.9448 1.885 1.7163 1.468 1.1796 0.8904 0.63139 0.4206 0.2632 0.15473 0.085449 0.044331 0.021605 0.0098915 0.0042543 0.0017189 0.00065241 0.00023263 7.792e-05 2.4519e-05 7.2477e-06 2.0126e-06 5.2502e-07 1.2866e-07 2.962e-08 6.4057e-09 1.3014e-09 2.4838e-10 4.4531e-11 7.5003e-12 1.1867e-12 1.7639e-13 2.463e-14 3.2307e-15 3.981e-16 4.6083e-17 5.0113e-18 5.1194e-19 4.9129e-20 4.4291e-21 3.7511e-22 2.9843e-23 2.2305e-24 1.566e-25 1.0329e-26 6.4e-28 3.7253e-29 2.037e-30 1.0463e-31 5.0492e-33 2.2889e-34 9.7472e-36 3.8994e-37 1.4654e-38 5.1736e-40 1.7158e-41 5.3459e-43 1.5647e-44 4.302e-46 1.1112e-47 2.6962e-49 +2.5412e-49 1.0473e-47 4.0548e-46 1.4747e-44 5.0387e-43 1.6172e-41 4.8763e-40 1.3812e-38 3.6753e-37 9.187e-36 2.1573e-34 4.759e-33 9.8621e-32 1.9199e-30 3.5112e-29 6.0322e-28 9.7355e-27 1.476e-25 2.1023e-24 2.8128e-23 3.5355e-22 4.1746e-21 4.6306e-20 4.8252e-19 4.7233e-18 4.3435e-17 3.7522e-16 3.045e-15 2.3214e-14 1.6625e-13 1.1185e-12 7.0692e-12 4.1972e-11 2.341e-10 1.2266e-09 6.0375e-09 2.7917e-08 1.2127e-07 4.9485e-07 1.8969e-06 6.8311e-06 2.3109e-05 7.3442e-05 0.00021926 0.00061492 0.0016201 0.0040098 0.009323 0.020363 0.041783 0.080538 0.14584 0.24808 0.39642 0.5951 0.83923 1.1118 1.3837 1.6177 1.7767 1.833 1.7767 1.6177 1.3837 1.1118 0.83923 0.5951 0.39642 0.24808 0.14584 0.080538 0.041783 0.020363 0.009323 0.0040098 0.0016201 0.00061492 0.00021926 7.3442e-05 2.3109e-05 6.8311e-06 1.8969e-06 4.9485e-07 1.2127e-07 2.7917e-08 6.0375e-09 1.2266e-09 2.341e-10 4.1972e-11 7.0692e-12 1.1185e-12 1.6625e-13 2.3214e-14 3.045e-15 3.7522e-16 4.3435e-17 4.7233e-18 4.8252e-19 4.6306e-20 4.1746e-21 3.5355e-22 2.8128e-23 2.1023e-24 1.476e-25 9.7355e-27 6.0322e-28 3.5112e-29 1.9199e-30 9.8621e-32 4.759e-33 2.1573e-34 9.187e-36 3.6753e-37 1.3812e-38 4.8763e-40 1.6172e-41 5.0387e-43 1.4747e-44 4.0548e-46 1.0473e-47 2.5412e-49 +2.3866e-49 9.8359e-48 3.8081e-46 1.385e-44 4.7321e-43 1.5188e-41 4.5796e-40 1.2972e-38 3.4517e-37 8.6281e-36 2.0261e-34 4.4695e-33 9.2621e-32 1.8031e-30 3.2975e-29 5.6652e-28 9.1432e-27 1.3862e-25 1.9744e-24 2.6417e-23 3.3204e-22 3.9206e-21 4.3488e-20 4.5316e-19 4.4359e-18 4.0792e-17 3.5239e-16 2.8598e-15 2.1802e-14 1.5614e-13 1.0505e-12 6.6391e-12 3.9418e-11 2.1986e-10 1.152e-09 5.6702e-09 2.6219e-08 1.1389e-07 4.6474e-07 1.7815e-06 6.4155e-06 2.1703e-05 6.8973e-05 0.00020592 0.00057751 0.0015215 0.0037658 0.0087558 0.019124 0.039241 0.075638 0.13696 0.23298 0.37231 0.5589 0.78817 1.0442 1.2995 1.5192 1.6686 1.7215 1.6686 1.5192 1.2995 1.0442 0.78817 0.5589 0.37231 0.23298 0.13696 0.075638 0.039241 0.019124 0.0087558 0.0037658 0.0015215 0.00057751 0.00020592 6.8973e-05 2.1703e-05 6.4155e-06 1.7815e-06 4.6474e-07 1.1389e-07 2.6219e-08 5.6702e-09 1.152e-09 2.1986e-10 3.9418e-11 6.6391e-12 1.0505e-12 1.5614e-13 2.1802e-14 2.8598e-15 3.5239e-16 4.0792e-17 4.4359e-18 4.5316e-19 4.3488e-20 3.9206e-21 3.3204e-22 2.6417e-23 1.9744e-24 1.3862e-25 9.1432e-27 5.6652e-28 3.2975e-29 1.8031e-30 9.2621e-32 4.4695e-33 2.0261e-34 8.6281e-36 3.4517e-37 1.2972e-38 4.5796e-40 1.5188e-41 4.7321e-43 1.385e-44 3.8081e-46 9.8359e-48 2.3866e-49 +2.2335e-49 9.2049e-48 3.5638e-46 1.2962e-44 4.4285e-43 1.4214e-41 4.2858e-40 1.214e-38 3.2302e-37 8.0746e-36 1.8961e-34 4.1827e-33 8.6679e-32 1.6874e-30 3.086e-29 5.3018e-28 8.5566e-27 1.2973e-25 1.8477e-24 2.4722e-23 3.1074e-22 3.6691e-21 4.0699e-20 4.2409e-19 4.1514e-18 3.8175e-17 3.2978e-16 2.6763e-15 2.0403e-14 1.4612e-13 9.8307e-13 6.2132e-12 3.6889e-11 2.0575e-10 1.0781e-09 5.3064e-09 2.4537e-08 1.0658e-07 4.3492e-07 1.6672e-06 6.0039e-06 2.0311e-05 6.4548e-05 0.00019271 0.00054046 0.0014239 0.0035242 0.0081941 0.017897 0.036723 0.070786 0.12818 0.21804 0.34842 0.52304 0.73761 0.97717 1.2161 1.4218 1.5615 1.6111 1.5615 1.4218 1.2161 0.97717 0.73761 0.52304 0.34842 0.21804 0.12818 0.070786 0.036723 0.017897 0.0081941 0.0035242 0.0014239 0.00054046 0.00019271 6.4548e-05 2.0311e-05 6.0039e-06 1.6672e-06 4.3492e-07 1.0658e-07 2.4537e-08 5.3064e-09 1.0781e-09 2.0575e-10 3.6889e-11 6.2132e-12 9.8307e-13 1.4612e-13 2.0403e-14 2.6763e-15 3.2978e-16 3.8175e-17 4.1514e-18 4.2409e-19 4.0699e-20 3.6691e-21 3.1074e-22 2.4722e-23 1.8477e-24 1.2973e-25 8.5566e-27 5.3018e-28 3.086e-29 1.6874e-30 8.6679e-32 4.1827e-33 1.8961e-34 8.0746e-36 3.2302e-37 1.214e-38 4.2858e-40 1.4214e-41 4.4285e-43 1.2962e-44 3.5638e-46 9.2049e-48 2.2335e-49 +2.0829e-49 8.5844e-48 3.3235e-46 1.2088e-44 4.13e-43 1.3256e-41 3.9969e-40 1.1321e-38 3.0125e-37 7.5302e-36 1.7683e-34 3.9008e-33 8.0836e-32 1.5737e-30 2.878e-29 4.9443e-28 7.9798e-27 1.2098e-25 1.7232e-24 2.3056e-23 2.8979e-22 3.4217e-21 3.7955e-20 3.955e-19 3.8715e-18 3.5602e-17 3.0755e-16 2.4959e-15 1.9028e-14 1.3627e-13 9.168e-13 5.7944e-12 3.4403e-11 1.9188e-10 1.0054e-09 4.9487e-09 2.2883e-08 9.9398e-08 4.056e-07 1.5548e-06 5.5992e-06 1.8942e-05 6.0197e-05 0.00017972 0.00050402 0.0013279 0.0032866 0.0076417 0.016691 0.034248 0.066014 0.11954 0.20334 0.32493 0.48778 0.68788 0.9113 1.1341 1.3259 1.4562 1.5025 1.4562 1.3259 1.1341 0.9113 0.68788 0.48778 0.32493 0.20334 0.11954 0.066014 0.034248 0.016691 0.0076417 0.0032866 0.0013279 0.00050402 0.00017972 6.0197e-05 1.8942e-05 5.5992e-06 1.5548e-06 4.056e-07 9.9398e-08 2.2883e-08 4.9487e-09 1.0054e-09 1.9188e-10 3.4403e-11 5.7944e-12 9.168e-13 1.3627e-13 1.9028e-14 2.4959e-15 3.0755e-16 3.5602e-17 3.8715e-18 3.955e-19 3.7955e-20 3.4217e-21 2.8979e-22 2.3056e-23 1.7232e-24 1.2098e-25 7.9798e-27 4.9443e-28 2.878e-29 1.5737e-30 8.0836e-32 3.9008e-33 1.7683e-34 7.5302e-36 3.0125e-37 1.1321e-38 3.9969e-40 1.3256e-41 4.13e-43 1.2088e-44 3.3235e-46 8.5844e-48 2.0829e-49 +1.9358e-49 7.9782e-48 3.0888e-46 1.1234e-44 3.8383e-43 1.232e-41 3.7146e-40 1.0522e-38 2.7997e-37 6.9984e-36 1.6434e-34 3.6253e-33 7.5127e-32 1.4625e-30 2.6747e-29 4.5952e-28 7.4162e-27 1.1244e-25 1.6015e-24 2.1427e-23 2.6932e-22 3.1801e-21 3.5275e-20 3.6757e-19 3.5981e-18 3.3088e-17 2.8583e-16 2.3196e-15 1.7684e-14 1.2665e-13 8.5206e-13 5.3852e-12 3.1973e-11 1.7833e-10 9.3439e-10 4.5992e-09 2.1267e-08 9.2378e-08 3.7696e-07 1.445e-06 5.2038e-06 1.7604e-05 5.5946e-05 0.00016702 0.00046843 0.0012341 0.0030545 0.007102 0.015512 0.031829 0.061352 0.11109 0.18898 0.30199 0.45333 0.6393 0.84694 1.054 1.2323 1.3534 1.3964 1.3534 1.2323 1.054 0.84694 0.6393 0.45333 0.30199 0.18898 0.11109 0.061352 0.031829 0.015512 0.007102 0.0030545 0.0012341 0.00046843 0.00016702 5.5946e-05 1.7604e-05 5.2038e-06 1.445e-06 3.7696e-07 9.2378e-08 2.1267e-08 4.5992e-09 9.3439e-10 1.7833e-10 3.1973e-11 5.3852e-12 8.5206e-13 1.2665e-13 1.7684e-14 2.3196e-15 2.8583e-16 3.3088e-17 3.5981e-18 3.6757e-19 3.5275e-20 3.1801e-21 2.6932e-22 2.1427e-23 1.6015e-24 1.1244e-25 7.4162e-27 4.5952e-28 2.6747e-29 1.4625e-30 7.5127e-32 3.6253e-33 1.6434e-34 6.9984e-36 2.7997e-37 1.0522e-38 3.7146e-40 1.232e-41 3.8383e-43 1.1234e-44 3.0888e-46 7.9782e-48 1.9358e-49 +1.793e-49 7.3895e-48 2.8609e-46 1.0405e-44 3.5551e-43 1.1411e-41 3.4406e-40 9.7454e-39 2.5932e-37 6.4821e-36 1.5222e-34 3.3578e-33 6.9584e-32 1.3546e-30 2.4774e-29 4.2561e-28 6.8691e-27 1.0414e-25 1.4833e-24 1.9846e-23 2.4945e-22 2.9455e-21 3.2672e-20 3.4045e-19 3.3326e-18 3.0646e-17 2.6474e-16 2.1485e-15 1.6379e-14 1.173e-13 7.8919e-13 4.9878e-12 2.9614e-11 1.6517e-10 8.6545e-10 4.2599e-09 1.9698e-08 8.5563e-08 3.4915e-07 1.3384e-06 4.8198e-06 1.6305e-05 5.1818e-05 0.0001547 0.00043387 0.0011431 0.0028292 0.006578 0.014368 0.029481 0.056826 0.1029 0.17504 0.27971 0.41989 0.59214 0.78445 0.97627 1.1414 1.2536 1.2933 1.2536 1.1414 0.97627 0.78445 0.59214 0.41989 0.27971 0.17504 0.1029 0.056826 0.029481 0.014368 0.006578 0.0028292 0.0011431 0.00043387 0.0001547 5.1818e-05 1.6305e-05 4.8198e-06 1.3384e-06 3.4915e-07 8.5563e-08 1.9698e-08 4.2599e-09 8.6545e-10 1.6517e-10 2.9614e-11 4.9878e-12 7.8919e-13 1.173e-13 1.6379e-14 2.1485e-15 2.6474e-16 3.0646e-17 3.3326e-18 3.4045e-19 3.2672e-20 2.9455e-21 2.4945e-22 1.9846e-23 1.4833e-24 1.0414e-25 6.8691e-27 4.2561e-28 2.4774e-29 1.3546e-30 6.9584e-32 3.3578e-33 1.5222e-34 6.4821e-36 2.5932e-37 9.7454e-39 3.4406e-40 1.1411e-41 3.5551e-43 1.0405e-44 2.8609e-46 7.3895e-48 1.793e-49 +1.6551e-49 6.8213e-48 2.6409e-46 9.6052e-45 3.2818e-43 1.0533e-41 3.176e-40 8.9961e-39 2.3938e-37 5.9837e-36 1.4051e-34 3.0996e-33 6.4234e-32 1.2505e-30 2.2869e-29 3.9289e-28 6.3409e-27 9.6136e-26 1.3692e-24 1.832e-23 2.3027e-22 2.719e-21 3.016e-20 3.1427e-19 3.0764e-18 2.829e-17 2.4439e-16 1.9833e-15 1.512e-14 1.0828e-13 7.2851e-13 4.6043e-12 2.7337e-11 1.5247e-10 7.989e-10 3.9323e-09 1.8183e-08 7.8983e-08 3.223e-07 1.2355e-06 4.4492e-06 1.5052e-05 4.7834e-05 0.00014281 0.00040051 0.0010552 0.0026116 0.0060722 0.013263 0.027214 0.052456 0.094986 0.16158 0.2582 0.3876 0.5466 0.72413 0.9012 1.0536 1.1572 1.1939 1.1572 1.0536 0.9012 0.72413 0.5466 0.3876 0.2582 0.16158 0.094986 0.052456 0.027214 0.013263 0.0060722 0.0026116 0.0010552 0.00040051 0.00014281 4.7834e-05 1.5052e-05 4.4492e-06 1.2355e-06 3.223e-07 7.8983e-08 1.8183e-08 3.9323e-09 7.989e-10 1.5247e-10 2.7337e-11 4.6043e-12 7.2851e-13 1.0828e-13 1.512e-14 1.9833e-15 2.4439e-16 2.829e-17 3.0764e-18 3.1427e-19 3.016e-20 2.719e-21 2.3027e-22 1.832e-23 1.3692e-24 9.6136e-26 6.3409e-27 3.9289e-28 2.2869e-29 1.2505e-30 6.4234e-32 3.0996e-33 1.4051e-34 5.9837e-36 2.3938e-37 8.9961e-39 3.176e-40 1.0533e-41 3.2818e-43 9.6052e-45 2.6409e-46 6.8213e-48 1.6551e-49 +1.5228e-49 6.2759e-48 2.4298e-46 8.8371e-45 3.0193e-43 9.691e-42 2.922e-40 8.2767e-39 2.2023e-37 5.5052e-36 1.2927e-34 2.8518e-33 5.9097e-32 1.1505e-30 2.104e-29 3.6147e-28 5.8338e-27 8.8449e-26 1.2598e-24 1.6855e-23 2.1186e-22 2.5016e-21 2.7748e-20 2.8914e-19 2.8304e-18 2.6028e-17 2.2484e-16 1.8247e-15 1.3911e-14 9.9624e-14 6.7025e-13 4.2361e-12 2.5151e-11 1.4028e-10 7.3502e-10 3.6179e-09 1.6729e-08 7.2667e-08 2.9653e-07 1.1367e-06 4.0934e-06 1.3848e-05 4.4009e-05 0.00013139 0.00036848 0.00097082 0.0024028 0.0055867 0.012202 0.025038 0.048261 0.08739 0.14866 0.23755 0.35661 0.50289 0.66623 0.82913 0.96936 1.0646 1.0984 1.0646 0.96936 0.82913 0.66623 0.50289 0.35661 0.23755 0.14866 0.08739 0.048261 0.025038 0.012202 0.0055867 0.0024028 0.00097082 0.00036848 0.00013139 4.4009e-05 1.3848e-05 4.0934e-06 1.1367e-06 2.9653e-07 7.2667e-08 1.6729e-08 3.6179e-09 7.3502e-10 1.4028e-10 2.5151e-11 4.2361e-12 6.7025e-13 9.9624e-14 1.3911e-14 1.8247e-15 2.2484e-16 2.6028e-17 2.8304e-18 2.8914e-19 2.7748e-20 2.5016e-21 2.1186e-22 1.6855e-23 1.2598e-24 8.8449e-26 5.8338e-27 3.6147e-28 2.104e-29 1.1505e-30 5.9097e-32 2.8518e-33 1.2927e-34 5.5052e-36 2.2023e-37 8.2767e-39 2.922e-40 9.691e-42 3.0193e-43 8.8371e-45 2.4298e-46 6.2759e-48 1.5228e-49 +1.3964e-49 5.755e-48 2.2281e-46 8.1036e-45 2.7687e-43 8.8867e-42 2.6795e-40 7.5898e-39 2.0196e-37 5.0483e-36 1.1855e-34 2.6151e-33 5.4192e-32 1.055e-30 1.9294e-29 3.3147e-28 5.3496e-27 8.1108e-26 1.1552e-24 1.5456e-23 1.9427e-22 2.2939e-21 2.5445e-20 2.6514e-19 2.5955e-18 2.3867e-17 2.0618e-16 1.6732e-15 1.2756e-14 9.1355e-14 6.1462e-13 3.8845e-12 2.3064e-11 1.2864e-10 6.7401e-10 3.3176e-09 1.5341e-08 6.6636e-08 2.7192e-07 1.0424e-06 3.7537e-06 1.2699e-05 4.0356e-05 0.00012048 0.0003379 0.00089024 0.0022034 0.005123 0.01119 0.02296 0.044256 0.080137 0.13632 0.21783 0.32701 0.46116 0.61093 0.76032 0.8889 0.97627 1.0073 0.97627 0.8889 0.76032 0.61093 0.46116 0.32701 0.21783 0.13632 0.080137 0.044256 0.02296 0.01119 0.005123 0.0022034 0.00089024 0.0003379 0.00012048 4.0356e-05 1.2699e-05 3.7537e-06 1.0424e-06 2.7192e-07 6.6636e-08 1.5341e-08 3.3176e-09 6.7401e-10 1.2864e-10 2.3064e-11 3.8845e-12 6.1462e-13 9.1355e-14 1.2756e-14 1.6732e-15 2.0618e-16 2.3867e-17 2.5955e-18 2.6514e-19 2.5445e-20 2.2939e-21 1.9427e-22 1.5456e-23 1.1552e-24 8.1108e-26 5.3496e-27 3.3147e-28 1.9294e-29 1.055e-30 5.4192e-32 2.6151e-33 1.1855e-34 5.0483e-36 2.0196e-37 7.5898e-39 2.6795e-40 8.8867e-42 2.7687e-43 8.1036e-45 2.2281e-46 5.755e-48 1.3964e-49 +1.2763e-49 5.2601e-48 2.0365e-46 7.4068e-45 2.5307e-43 8.1225e-42 2.4491e-40 6.9371e-39 1.8459e-37 4.6142e-36 1.0835e-34 2.3902e-33 4.9532e-32 9.6427e-31 1.7635e-29 3.0297e-28 4.8896e-27 7.4133e-26 1.0559e-24 1.4127e-23 1.7757e-22 2.0967e-21 2.3257e-20 2.4234e-19 2.3723e-18 2.1815e-17 1.8845e-16 1.5294e-15 1.1659e-14 8.35e-14 5.6177e-13 3.5505e-12 2.108e-11 1.1758e-10 6.1606e-10 3.0323e-09 1.4021e-08 6.0906e-08 2.4853e-07 9.5273e-07 3.4309e-06 1.1607e-05 3.6886e-05 0.00011012 0.00030884 0.00081369 0.0020139 0.0046825 0.010227 0.020985 0.04045 0.073246 0.1246 0.1991 0.29889 0.4215 0.5584 0.69494 0.81246 0.89232 0.92064 0.89232 0.81246 0.69494 0.5584 0.4215 0.29889 0.1991 0.1246 0.073246 0.04045 0.020985 0.010227 0.0046825 0.0020139 0.00081369 0.00030884 0.00011012 3.6886e-05 1.1607e-05 3.4309e-06 9.5273e-07 2.4853e-07 6.0906e-08 1.4021e-08 3.0323e-09 6.1606e-10 1.1758e-10 2.108e-11 3.5505e-12 5.6177e-13 8.35e-14 1.1659e-14 1.5294e-15 1.8845e-16 2.1815e-17 2.3723e-18 2.4234e-19 2.3257e-20 2.0967e-21 1.7757e-22 1.4127e-23 1.0559e-24 7.4133e-26 4.8896e-27 3.0297e-28 1.7635e-29 9.6427e-31 4.9532e-32 2.3902e-33 1.0835e-34 4.6142e-36 1.8459e-37 6.9371e-39 2.4491e-40 8.1225e-42 2.5307e-43 7.4068e-45 2.0365e-46 5.2601e-48 1.2763e-49 +1.1628e-49 4.7922e-48 1.8554e-46 6.748e-45 2.3056e-43 7.4001e-42 2.2313e-40 6.3201e-39 1.6817e-37 4.2038e-36 9.8714e-35 2.1776e-33 4.5127e-32 8.7851e-31 1.6066e-29 2.7602e-28 4.4547e-27 6.7539e-26 9.6195e-25 1.2871e-23 1.6177e-22 1.9102e-21 2.1188e-20 2.2079e-19 2.1613e-18 1.9875e-17 1.7169e-16 1.3933e-15 1.0622e-14 7.6073e-14 5.118e-13 3.2347e-12 1.9205e-11 1.0712e-10 5.6126e-10 2.7626e-09 1.2774e-08 5.5489e-08 2.2643e-07 8.6799e-07 3.1257e-06 1.0574e-05 3.3605e-05 0.00010033 0.00028137 0.00074131 0.0018348 0.004266 0.0093177 0.019119 0.036852 0.066731 0.11351 0.18139 0.2723 0.38401 0.50873 0.63313 0.7402 0.81295 0.83876 0.81295 0.7402 0.63313 0.50873 0.38401 0.2723 0.18139 0.11351 0.066731 0.036852 0.019119 0.0093177 0.004266 0.0018348 0.00074131 0.00028137 0.00010033 3.3605e-05 1.0574e-05 3.1257e-06 8.6799e-07 2.2643e-07 5.5489e-08 1.2774e-08 2.7626e-09 5.6126e-10 1.0712e-10 1.9205e-11 3.2347e-12 5.118e-13 7.6073e-14 1.0622e-14 1.3933e-15 1.7169e-16 1.9875e-17 2.1613e-18 2.2079e-19 2.1188e-20 1.9102e-21 1.6177e-22 1.2871e-23 9.6195e-25 6.7539e-26 4.4547e-27 2.7602e-28 1.6066e-29 8.7851e-31 4.5127e-32 2.1776e-33 9.8714e-35 4.2038e-36 1.6817e-37 6.3201e-39 2.2313e-40 7.4001e-42 2.3056e-43 6.748e-45 1.8554e-46 4.7922e-48 1.1628e-49 +1.056e-49 4.352e-48 1.6849e-46 6.1281e-45 2.0938e-43 6.7202e-42 2.0263e-40 5.7395e-39 1.5272e-37 3.8176e-36 8.9645e-35 1.9775e-33 4.0981e-32 7.978e-31 1.459e-29 2.5066e-28 4.0455e-27 6.1335e-26 8.7358e-25 1.1688e-23 1.4691e-22 1.7347e-21 1.9242e-20 2.005e-19 1.9627e-18 1.8049e-17 1.5592e-16 1.2653e-15 9.6463e-15 6.9084e-14 4.6478e-13 2.9375e-12 1.7441e-11 9.7278e-11 5.097e-10 2.5088e-09 1.1601e-08 5.0391e-08 2.0563e-07 7.8825e-07 2.8386e-06 9.6028e-06 3.0518e-05 9.1109e-05 0.00025552 0.00067321 0.0016662 0.0038741 0.0084617 0.017362 0.033467 0.060601 0.10308 0.16473 0.24729 0.34873 0.46199 0.57496 0.6722 0.73827 0.7617 0.73827 0.6722 0.57496 0.46199 0.34873 0.24729 0.16473 0.10308 0.060601 0.033467 0.017362 0.0084617 0.0038741 0.0016662 0.00067321 0.00025552 9.1109e-05 3.0518e-05 9.6028e-06 2.8386e-06 7.8825e-07 2.0563e-07 5.0391e-08 1.1601e-08 2.5088e-09 5.097e-10 9.7278e-11 1.7441e-11 2.9375e-12 4.6478e-13 6.9084e-14 9.6463e-15 1.2653e-15 1.5592e-16 1.8049e-17 1.9627e-18 2.005e-19 1.9242e-20 1.7347e-21 1.4691e-22 1.1688e-23 8.7358e-25 6.1335e-26 4.0455e-27 2.5066e-28 1.459e-29 7.978e-31 4.0981e-32 1.9775e-33 8.9645e-35 3.8176e-36 1.5272e-37 5.7395e-39 2.0263e-40 6.7202e-42 2.0938e-43 6.1281e-45 1.6849e-46 4.352e-48 1.056e-49 +9.5592e-50 3.9396e-48 1.5253e-46 5.5474e-45 1.8954e-43 6.0834e-42 1.8343e-40 5.1956e-39 1.3825e-37 3.4558e-36 8.1151e-35 1.7902e-33 3.7098e-32 7.222e-31 1.3208e-29 2.2691e-28 3.6621e-27 5.5523e-26 7.908e-25 1.0581e-23 1.3299e-22 1.5703e-21 1.7419e-20 1.815e-19 1.7767e-18 1.6339e-17 1.4114e-16 1.1454e-15 8.7322e-15 6.2538e-14 4.2074e-13 2.6592e-12 1.5788e-11 8.806e-11 4.614e-10 2.2711e-09 1.0501e-08 4.5616e-08 1.8614e-07 7.1356e-07 2.5696e-06 8.6929e-06 2.7626e-05 8.2476e-05 0.00023131 0.00060942 0.0015083 0.003507 0.0076599 0.015717 0.030296 0.054858 0.093317 0.14912 0.22386 0.31569 0.41822 0.52048 0.6085 0.66831 0.68952 0.66831 0.6085 0.52048 0.41822 0.31569 0.22386 0.14912 0.093317 0.054858 0.030296 0.015717 0.0076599 0.003507 0.0015083 0.00060942 0.00023131 8.2476e-05 2.7626e-05 8.6929e-06 2.5696e-06 7.1356e-07 1.8614e-07 4.5616e-08 1.0501e-08 2.2711e-09 4.614e-10 8.806e-11 1.5788e-11 2.6592e-12 4.2074e-13 6.2538e-14 8.7322e-15 1.1454e-15 1.4114e-16 1.6339e-17 1.7767e-18 1.815e-19 1.7419e-20 1.5703e-21 1.3299e-22 1.0581e-23 7.908e-25 5.5523e-26 3.6621e-27 2.2691e-28 1.3208e-29 7.222e-31 3.7098e-32 1.7902e-33 8.1151e-35 3.4558e-36 1.3825e-37 5.1956e-39 1.8343e-40 6.0834e-42 1.8954e-43 5.5474e-45 1.5253e-46 3.9396e-48 9.5592e-50 +8.6261e-50 3.555e-48 1.3764e-46 5.0059e-45 1.7103e-43 5.4896e-42 1.6552e-40 4.6884e-39 1.2476e-37 3.1185e-36 7.3229e-35 1.6154e-33 3.3476e-32 6.517e-31 1.1918e-29 2.0476e-28 3.3047e-27 5.0103e-26 7.1361e-25 9.5479e-24 1.2001e-22 1.417e-21 1.5718e-20 1.6379e-19 1.6033e-18 1.4744e-17 1.2737e-16 1.0336e-15 7.8799e-15 5.6433e-14 3.7967e-13 2.3996e-12 1.4247e-11 7.9464e-11 4.1636e-10 2.0494e-09 9.4763e-09 4.1163e-08 1.6797e-07 6.439e-07 2.3188e-06 7.8444e-06 2.4929e-05 7.4425e-05 0.00020873 0.00054993 0.0013611 0.0031646 0.0069122 0.014183 0.027338 0.049503 0.084208 0.13456 0.202 0.28487 0.37739 0.46967 0.5491 0.60307 0.62222 0.60307 0.5491 0.46967 0.37739 0.28487 0.202 0.13456 0.084208 0.049503 0.027338 0.014183 0.0069122 0.0031646 0.0013611 0.00054993 0.00020873 7.4425e-05 2.4929e-05 7.8444e-06 2.3188e-06 6.439e-07 1.6797e-07 4.1163e-08 9.4763e-09 2.0494e-09 4.1636e-10 7.9464e-11 1.4247e-11 2.3996e-12 3.7967e-13 5.6433e-14 7.8799e-15 1.0336e-15 1.2737e-16 1.4744e-17 1.6033e-18 1.6379e-19 1.5718e-20 1.417e-21 1.2001e-22 9.5479e-24 7.1361e-25 5.0103e-26 3.3047e-27 2.0476e-28 1.1918e-29 6.517e-31 3.3476e-32 1.6154e-33 7.3229e-35 3.1185e-36 1.2476e-37 4.6884e-39 1.6552e-40 5.4896e-42 1.7103e-43 5.0059e-45 1.3764e-46 3.555e-48 8.6261e-50 +7.7596e-50 3.198e-48 1.2381e-46 4.5031e-45 1.5386e-43 4.9382e-42 1.489e-40 4.2175e-39 1.1222e-37 2.8053e-36 6.5874e-35 1.4532e-33 3.0114e-32 5.8625e-31 1.0721e-29 1.8419e-28 2.9727e-27 4.5071e-26 6.4193e-25 8.5889e-24 1.0796e-22 1.2747e-21 1.4139e-20 1.4734e-19 1.4423e-18 1.3263e-17 1.1457e-16 9.2979e-16 7.0884e-15 5.0765e-14 3.4154e-13 2.1586e-12 1.2816e-11 7.1483e-11 3.7454e-10 1.8436e-09 8.5245e-09 3.7029e-08 1.511e-07 5.7923e-07 2.0859e-06 7.0565e-06 2.2425e-05 6.695e-05 0.00018777 0.0004947 0.0012244 0.0028468 0.0062179 0.012758 0.024592 0.044531 0.07575 0.12105 0.18171 0.25626 0.33949 0.4225 0.49395 0.5425 0.55972 0.5425 0.49395 0.4225 0.33949 0.25626 0.18171 0.12105 0.07575 0.044531 0.024592 0.012758 0.0062179 0.0028468 0.0012244 0.0004947 0.00018777 6.695e-05 2.2425e-05 7.0565e-06 2.0859e-06 5.7923e-07 1.511e-07 3.7029e-08 8.5245e-09 1.8436e-09 3.7454e-10 7.1483e-11 1.2816e-11 2.1586e-12 3.4154e-13 5.0765e-14 7.0884e-15 9.2979e-16 1.1457e-16 1.3263e-17 1.4423e-18 1.4734e-19 1.4139e-20 1.2747e-21 1.0796e-22 8.5889e-24 6.4193e-25 4.5071e-26 2.9727e-27 1.8419e-28 1.0721e-29 5.8625e-31 3.0114e-32 1.4532e-33 6.5874e-35 2.8053e-36 1.1222e-37 4.2175e-39 1.489e-40 4.9382e-42 1.5386e-43 4.5031e-45 1.2381e-46 3.198e-48 7.7596e-50 +6.9585e-50 2.8678e-48 1.1103e-46 4.0382e-45 1.3797e-43 4.4284e-42 1.3353e-40 3.7821e-39 1.0064e-37 2.5156e-36 5.9073e-35 1.3031e-33 2.7005e-32 5.2572e-31 9.6145e-30 1.6518e-28 2.6658e-27 4.0418e-26 5.7566e-25 7.7022e-24 9.6811e-23 1.1431e-21 1.268e-20 1.3213e-19 1.2934e-18 1.1894e-17 1.0274e-16 8.338e-16 6.3566e-15 4.5524e-14 3.0628e-13 1.9357e-12 1.1493e-11 6.4103e-11 3.3587e-10 1.6532e-09 7.6445e-09 3.3206e-08 1.355e-07 5.1943e-07 1.8705e-06 6.328e-06 2.011e-05 6.0038e-05 0.00016838 0.00044362 0.001098 0.0025529 0.005576 0.011441 0.022053 0.039934 0.06793 0.10855 0.16295 0.2298 0.30444 0.37888 0.44296 0.48649 0.50194 0.48649 0.44296 0.37888 0.30444 0.2298 0.16295 0.10855 0.06793 0.039934 0.022053 0.011441 0.005576 0.0025529 0.001098 0.00044362 0.00016838 6.0038e-05 2.011e-05 6.328e-06 1.8705e-06 5.1943e-07 1.355e-07 3.3206e-08 7.6445e-09 1.6532e-09 3.3587e-10 6.4103e-11 1.1493e-11 1.9357e-12 3.0628e-13 4.5524e-14 6.3566e-15 8.338e-16 1.0274e-16 1.1894e-17 1.2934e-18 1.3213e-19 1.268e-20 1.1431e-21 9.6811e-23 7.7022e-24 5.7566e-25 4.0418e-26 2.6658e-27 1.6518e-28 9.6145e-30 5.2572e-31 2.7005e-32 1.3031e-33 5.9073e-35 2.5156e-36 1.0064e-37 3.7821e-39 1.3353e-40 4.4284e-42 1.3797e-43 4.0382e-45 1.1103e-46 2.8678e-48 6.9585e-50 +6.2209e-50 2.5638e-48 9.926e-47 3.6101e-45 1.2334e-43 3.9589e-42 1.1937e-40 3.3812e-39 8.997e-38 2.249e-36 5.2811e-35 1.165e-33 2.4142e-32 4.6999e-31 8.5952e-30 1.4767e-28 2.3832e-27 3.6133e-26 5.1463e-25 6.8857e-24 8.6548e-23 1.0219e-21 1.1336e-20 1.1812e-19 1.1563e-18 1.0633e-17 9.1853e-17 7.4541e-16 5.6827e-15 4.0698e-14 2.7381e-13 1.7305e-12 1.0275e-11 5.7307e-11 3.0027e-10 1.478e-09 6.8341e-09 2.9686e-08 1.2114e-07 4.6436e-07 1.6722e-06 5.6571e-06 1.7978e-05 5.3673e-05 0.00015053 0.00039659 0.00098158 0.0022822 0.0049849 0.010228 0.019716 0.0357 0.060728 0.097044 0.14568 0.20544 0.27217 0.33872 0.396 0.43492 0.44872 0.43492 0.396 0.33872 0.27217 0.20544 0.14568 0.097044 0.060728 0.0357 0.019716 0.010228 0.0049849 0.0022822 0.00098158 0.00039659 0.00015053 5.3673e-05 1.7978e-05 5.6571e-06 1.6722e-06 4.6436e-07 1.2114e-07 2.9686e-08 6.8341e-09 1.478e-09 3.0027e-10 5.7307e-11 1.0275e-11 1.7305e-12 2.7381e-13 4.0698e-14 5.6827e-15 7.4541e-16 9.1853e-17 1.0633e-17 1.1563e-18 1.1812e-19 1.1336e-20 1.0219e-21 8.6548e-23 6.8857e-24 5.1463e-25 3.6133e-26 2.3832e-27 1.4767e-28 8.5952e-30 4.6999e-31 2.4142e-32 1.165e-33 5.2811e-35 2.249e-36 8.997e-38 3.3812e-39 1.1937e-40 3.9589e-42 1.2334e-43 3.6101e-45 9.926e-47 2.5638e-48 6.2209e-50 +5.5443e-50 2.285e-48 8.8465e-47 3.2175e-45 1.0993e-43 3.5284e-42 1.0639e-40 3.0135e-39 8.0185e-38 2.0044e-36 4.7067e-35 1.0383e-33 2.1517e-32 4.1888e-31 7.6605e-30 1.3161e-28 2.124e-27 3.2203e-26 4.5866e-25 6.1368e-24 7.7135e-23 9.1079e-22 1.0103e-20 1.0527e-19 1.0305e-18 9.4764e-18 8.1863e-17 6.6434e-16 5.0647e-15 3.6272e-14 2.4403e-13 1.5423e-12 9.1572e-12 5.1075e-11 2.6761e-10 1.3172e-09 6.0908e-09 2.6457e-08 1.0796e-07 4.1386e-07 1.4904e-06 5.0419e-06 1.6023e-05 4.7836e-05 0.00013416 0.00035346 0.00087483 0.002034 0.0044428 0.0091159 0.017571 0.031818 0.054124 0.08649 0.12984 0.1831 0.24257 0.30188 0.35293 0.38762 0.39992 0.38762 0.35293 0.30188 0.24257 0.1831 0.12984 0.08649 0.054124 0.031818 0.017571 0.0091159 0.0044428 0.002034 0.00087483 0.00035346 0.00013416 4.7836e-05 1.6023e-05 5.0419e-06 1.4904e-06 4.1386e-07 1.0796e-07 2.6457e-08 6.0908e-09 1.3172e-09 2.6761e-10 5.1075e-11 9.1572e-12 1.5423e-12 2.4403e-13 3.6272e-14 5.0647e-15 6.6434e-16 8.1863e-17 9.4764e-18 1.0305e-18 1.0527e-19 1.0103e-20 9.1079e-22 7.7135e-23 6.1368e-24 4.5866e-25 3.2203e-26 2.124e-27 1.3161e-28 7.6605e-30 4.1888e-31 2.1517e-32 1.0383e-33 4.7067e-35 2.0044e-36 8.0185e-38 3.0135e-39 1.0639e-40 3.5284e-42 1.0993e-43 3.2175e-45 8.8465e-47 2.285e-48 5.5443e-50 +4.9263e-50 2.0303e-48 7.8603e-47 2.8588e-45 9.7676e-44 3.1351e-42 9.4529e-41 2.6775e-39 7.1247e-38 1.7809e-36 4.1821e-35 9.2255e-34 1.9118e-32 3.7218e-31 6.8065e-30 1.1694e-28 1.8873e-27 2.8613e-26 4.0753e-25 5.4527e-24 6.8537e-23 8.0926e-22 8.9765e-21 9.3538e-20 9.1563e-19 8.42e-18 7.2738e-17 5.9029e-16 4.5001e-15 3.2229e-14 2.1683e-13 1.3704e-12 8.1364e-12 4.5381e-11 2.3778e-10 1.1704e-09 5.4119e-09 2.3508e-08 9.5928e-08 3.6773e-07 1.3242e-06 4.4798e-06 1.4237e-05 4.2504e-05 0.0001192 0.00031406 0.00077731 0.0018073 0.0039475 0.0080997 0.015613 0.028271 0.04809 0.076848 0.11536 0.16269 0.21553 0.26823 0.31359 0.34441 0.35534 0.34441 0.31359 0.26823 0.21553 0.16269 0.11536 0.076848 0.04809 0.028271 0.015613 0.0080997 0.0039475 0.0018073 0.00077731 0.00031406 0.0001192 4.2504e-05 1.4237e-05 4.4798e-06 1.3242e-06 3.6773e-07 9.5928e-08 2.3508e-08 5.4119e-09 1.1704e-09 2.3778e-10 4.5381e-11 8.1364e-12 1.3704e-12 2.1683e-13 3.2229e-14 4.5001e-15 5.9029e-16 7.2738e-17 8.42e-18 9.1563e-19 9.3538e-20 8.9765e-21 8.0926e-22 6.8537e-23 5.4527e-24 4.0753e-25 2.8613e-26 1.8873e-27 1.1694e-28 6.8065e-30 3.7218e-31 1.9118e-32 9.2255e-34 4.1821e-35 1.7809e-36 7.1247e-38 2.6775e-39 9.4529e-41 3.1351e-42 9.7676e-44 2.8588e-45 7.8603e-47 2.0303e-48 4.9263e-50 +4.3638e-50 1.7985e-48 6.9629e-47 2.5324e-45 8.6525e-44 2.7771e-42 8.3736e-41 2.3718e-39 6.3112e-38 1.5776e-36 3.7046e-35 8.1722e-34 1.6935e-32 3.2969e-31 6.0294e-30 1.0359e-28 1.6718e-27 2.5347e-26 3.6101e-25 4.8302e-24 6.0712e-23 7.1687e-22 7.9517e-21 8.2859e-20 8.111e-19 7.4587e-18 6.4433e-17 5.2289e-16 3.9863e-15 2.8549e-14 1.9207e-13 1.2139e-12 7.2075e-12 4.02e-11 2.1063e-10 1.0368e-09 4.794e-09 2.0824e-08 8.4976e-08 3.2574e-07 1.1731e-06 3.9684e-06 1.2612e-05 3.7651e-05 0.00010559 0.00027821 0.00068856 0.001601 0.0034968 0.007175 0.01383 0.025043 0.0426 0.068075 0.10219 0.14411 0.19092 0.2376 0.27779 0.30509 0.31477 0.30509 0.27779 0.2376 0.19092 0.14411 0.10219 0.068075 0.0426 0.025043 0.01383 0.007175 0.0034968 0.001601 0.00068856 0.00027821 0.00010559 3.7651e-05 1.2612e-05 3.9684e-06 1.1731e-06 3.2574e-07 8.4976e-08 2.0824e-08 4.794e-09 1.0368e-09 2.1063e-10 4.02e-11 7.2075e-12 1.2139e-12 1.9207e-13 2.8549e-14 3.9863e-15 5.2289e-16 6.4433e-17 7.4587e-18 8.111e-19 8.2859e-20 7.9517e-21 7.1687e-22 6.0712e-23 4.8302e-24 3.6101e-25 2.5347e-26 1.6718e-27 1.0359e-28 6.0294e-30 3.2969e-31 1.6935e-32 8.1722e-34 3.7046e-35 1.5776e-36 6.3112e-38 2.3718e-39 8.3736e-41 2.7771e-42 8.6525e-44 2.5324e-45 6.9629e-47 1.7985e-48 4.3638e-50 +3.854e-50 1.5883e-48 6.1494e-47 2.2365e-45 7.6415e-44 2.4527e-42 7.3953e-41 2.0947e-39 5.5738e-38 1.3933e-36 3.2718e-35 7.2174e-34 1.4957e-32 2.9117e-31 5.3249e-30 9.1483e-29 1.4765e-27 2.2385e-26 3.1883e-25 4.2659e-24 5.3618e-23 6.3311e-22 7.0226e-21 7.3177e-20 7.1633e-19 6.5872e-18 5.6905e-17 4.618e-16 3.5206e-15 2.5213e-14 1.6963e-13 1.0721e-12 6.3654e-12 3.5503e-11 1.8602e-10 9.1564e-10 4.2339e-09 1.8391e-08 7.5047e-08 2.8768e-07 1.036e-06 3.5047e-06 1.1138e-05 3.3252e-05 9.3257e-05 0.0002457 0.00060811 0.0014139 0.0030882 0.0063367 0.012214 0.022117 0.037623 0.060121 0.090252 0.12728 0.16861 0.20984 0.24533 0.26944 0.278 0.26944 0.24533 0.20984 0.16861 0.12728 0.090252 0.060121 0.037623 0.022117 0.012214 0.0063367 0.0030882 0.0014139 0.00060811 0.0002457 9.3257e-05 3.3252e-05 1.1138e-05 3.5047e-06 1.036e-06 2.8768e-07 7.5047e-08 1.8391e-08 4.2339e-09 9.1564e-10 1.8602e-10 3.5503e-11 6.3654e-12 1.0721e-12 1.6963e-13 2.5213e-14 3.5206e-15 4.618e-16 5.6905e-17 6.5872e-18 7.1633e-19 7.3177e-20 7.0226e-21 6.3311e-22 5.3618e-23 4.2659e-24 3.1883e-25 2.2385e-26 1.4765e-27 9.1483e-29 5.3249e-30 2.9117e-31 1.4957e-32 7.2174e-34 3.2718e-35 1.3933e-36 5.5738e-38 2.0947e-39 7.3953e-41 2.4527e-42 7.6415e-44 2.2365e-45 6.1494e-47 1.5883e-48 3.854e-50 +3.3935e-50 1.3985e-48 5.4146e-47 1.9693e-45 6.7284e-44 2.1596e-42 6.5116e-41 1.8444e-39 4.9078e-38 1.2268e-36 2.8808e-35 6.355e-34 1.317e-32 2.5638e-31 4.6887e-30 8.0552e-29 1.3e-27 1.971e-26 2.8073e-25 3.7561e-24 4.7212e-23 5.5746e-22 6.1835e-21 6.4433e-20 6.3073e-19 5.8001e-18 5.0105e-17 4.0662e-16 3.0999e-15 2.2201e-14 1.4936e-13 9.44e-13 5.6048e-12 3.1261e-11 1.638e-10 8.0623e-10 3.728e-09 1.6194e-08 6.608e-08 2.5331e-07 9.122e-07 3.0859e-06 9.8071e-06 2.9279e-05 8.2114e-05 0.00021634 0.00053545 0.001245 0.0027192 0.0055795 0.010755 0.019474 0.033127 0.052937 0.079468 0.11207 0.14847 0.18477 0.21602 0.23725 0.24478 0.23725 0.21602 0.18477 0.14847 0.11207 0.079468 0.052937 0.033127 0.019474 0.010755 0.0055795 0.0027192 0.001245 0.00053545 0.00021634 8.2114e-05 2.9279e-05 9.8071e-06 3.0859e-06 9.122e-07 2.5331e-07 6.608e-08 1.6194e-08 3.728e-09 8.0623e-10 1.638e-10 3.1261e-11 5.6048e-12 9.44e-13 1.4936e-13 2.2201e-14 3.0999e-15 4.0662e-16 5.0105e-17 5.8001e-18 6.3073e-19 6.4433e-20 6.1835e-21 5.5746e-22 4.7212e-23 3.7561e-24 2.8073e-25 1.971e-26 1.3e-27 8.0552e-29 4.6887e-30 2.5638e-31 1.317e-32 6.355e-34 2.8808e-35 1.2268e-36 4.9078e-38 1.8444e-39 6.5116e-41 2.1596e-42 6.7284e-44 1.9693e-45 5.4146e-47 1.3985e-48 3.3935e-50 +2.9791e-50 1.2278e-48 4.7534e-47 1.7288e-45 5.9068e-44 1.8959e-42 5.7164e-41 1.6192e-39 4.3085e-38 1.077e-36 2.529e-35 5.5789e-34 1.1561e-32 2.2507e-31 4.1161e-30 7.0715e-29 1.1413e-27 1.7303e-26 2.4645e-25 3.2974e-24 4.1446e-23 4.8938e-22 5.4284e-21 5.6565e-20 5.5371e-19 5.0918e-18 4.3987e-17 3.5696e-16 2.7214e-15 1.949e-14 1.3112e-13 8.2872e-13 4.9203e-12 2.7443e-11 1.4379e-10 7.0777e-10 3.2727e-09 1.4216e-08 5.801e-08 2.2238e-07 8.0081e-07 2.7091e-06 8.6095e-06 2.5703e-05 7.2086e-05 0.00018992 0.00047006 0.0010929 0.0023872 0.0048982 0.0094415 0.017096 0.029082 0.046472 0.069763 0.098382 0.13034 0.1622 0.18964 0.20828 0.21489 0.20828 0.18964 0.1622 0.13034 0.098382 0.069763 0.046472 0.029082 0.017096 0.0094415 0.0048982 0.0023872 0.0010929 0.00047006 0.00018992 7.2086e-05 2.5703e-05 8.6095e-06 2.7091e-06 8.0081e-07 2.2238e-07 5.801e-08 1.4216e-08 3.2727e-09 7.0777e-10 1.4379e-10 2.7443e-11 4.9203e-12 8.2872e-13 1.3112e-13 1.949e-14 2.7214e-15 3.5696e-16 4.3987e-17 5.0918e-18 5.5371e-19 5.6565e-20 5.4284e-21 4.8938e-22 4.1446e-23 3.2974e-24 2.4645e-25 1.7303e-26 1.1413e-27 7.0715e-29 4.1161e-30 2.2507e-31 1.1561e-32 5.5789e-34 2.529e-35 1.077e-36 4.3085e-38 1.6192e-39 5.7164e-41 1.8959e-42 5.9068e-44 1.7288e-45 4.7534e-47 1.2278e-48 2.9791e-50 +2.6075e-50 1.0746e-48 4.1605e-47 1.5132e-45 5.1701e-44 1.6594e-42 5.0035e-41 1.4172e-39 3.7711e-38 9.4266e-37 2.2136e-35 4.8831e-34 1.0119e-32 1.97e-31 3.6027e-30 6.1895e-29 9.9894e-28 1.5145e-26 2.1571e-25 2.8862e-24 3.6277e-23 4.2835e-22 4.7513e-21 4.951e-20 4.8465e-19 4.4568e-18 3.85e-17 3.1244e-16 2.3819e-15 1.7059e-14 1.1477e-13 7.2536e-13 4.3067e-12 2.4021e-11 1.2586e-10 6.195e-10 2.8645e-09 1.2443e-08 5.0775e-08 1.9464e-07 7.0093e-07 2.3712e-06 7.5357e-06 2.2497e-05 6.3096e-05 0.00016623 0.00041143 0.00095661 0.0020894 0.0042872 0.0082639 0.014964 0.025455 0.040676 0.061062 0.086112 0.11408 0.14197 0.16598 0.1823 0.18809 0.1823 0.16598 0.14197 0.11408 0.086112 0.061062 0.040676 0.025455 0.014964 0.0082639 0.0042872 0.0020894 0.00095661 0.00041143 0.00016623 6.3096e-05 2.2497e-05 7.5357e-06 2.3712e-06 7.0093e-07 1.9464e-07 5.0775e-08 1.2443e-08 2.8645e-09 6.195e-10 1.2586e-10 2.4021e-11 4.3067e-12 7.2536e-13 1.1477e-13 1.7059e-14 2.3819e-15 3.1244e-16 3.85e-17 4.4568e-18 4.8465e-19 4.951e-20 4.7513e-21 4.2835e-22 3.6277e-23 2.8862e-24 2.1571e-25 1.5145e-26 9.9894e-28 6.1895e-29 3.6027e-30 1.97e-31 1.0119e-32 4.8831e-34 2.2136e-35 9.4266e-37 3.7711e-38 1.4172e-39 5.0035e-41 1.6594e-42 5.1701e-44 1.5132e-45 4.1605e-47 1.0746e-48 2.6075e-50 +2.2755e-50 9.3782e-49 3.6308e-47 1.3205e-45 4.5119e-44 1.4482e-42 4.3665e-41 1.2368e-39 3.291e-38 8.2265e-37 1.9318e-35 4.2614e-34 8.831e-33 1.7192e-31 3.1441e-30 5.4015e-29 8.7176e-28 1.3217e-26 1.8825e-25 2.5187e-24 3.1659e-23 3.7381e-22 4.1464e-21 4.3207e-20 4.2295e-19 3.8894e-18 3.3599e-17 2.7267e-16 2.0787e-15 1.4887e-14 1.0016e-13 6.3301e-13 3.7584e-12 2.0963e-11 1.0984e-10 5.4063e-10 2.4999e-09 1.0859e-08 4.4311e-08 1.6986e-07 6.1169e-07 2.0693e-06 6.5763e-06 1.9633e-05 5.5063e-05 0.00014507 0.00035906 0.00083483 0.0018234 0.0037414 0.0072118 0.013059 0.022214 0.035498 0.053288 0.075149 0.099556 0.1239 0.14485 0.15909 0.16414 0.15909 0.14485 0.1239 0.099556 0.075149 0.053288 0.035498 0.022214 0.013059 0.0072118 0.0037414 0.0018234 0.00083483 0.00035906 0.00014507 5.5063e-05 1.9633e-05 6.5763e-06 2.0693e-06 6.1169e-07 1.6986e-07 4.4311e-08 1.0859e-08 2.4999e-09 5.4063e-10 1.0984e-10 2.0963e-11 3.7584e-12 6.3301e-13 1.0016e-13 1.4887e-14 2.0787e-15 2.7267e-16 3.3599e-17 3.8894e-18 4.2295e-19 4.3207e-20 4.1464e-21 3.7381e-22 3.1659e-23 2.5187e-24 1.8825e-25 1.3217e-26 8.7176e-28 5.4015e-29 3.1441e-30 1.7192e-31 8.831e-33 4.2614e-34 1.9318e-35 8.2265e-37 3.291e-38 1.2368e-39 4.3665e-41 1.4482e-42 4.5119e-44 1.3205e-45 3.6308e-47 9.3782e-49 2.2755e-50 +1.98e-50 8.1602e-49 3.1593e-47 1.149e-45 3.9259e-44 1.2601e-42 3.7994e-41 1.0762e-39 2.8636e-38 7.1581e-37 1.6809e-35 3.708e-34 7.6841e-33 1.4959e-31 2.7357e-30 4.7e-29 7.5854e-28 1.1501e-26 1.638e-25 2.1916e-24 2.7547e-23 3.2526e-22 3.6079e-21 3.7595e-20 3.6802e-19 3.3842e-18 2.9235e-17 2.3725e-16 1.8087e-15 1.2954e-14 8.7149e-14 5.508e-13 3.2702e-12 1.824e-11 9.5571e-11 4.7042e-10 2.1752e-09 9.4485e-09 3.8556e-08 1.478e-07 5.3225e-07 1.8006e-06 5.7222e-06 1.7083e-05 4.7912e-05 0.00012623 0.00031242 0.0007264 0.0015866 0.0032555 0.0062752 0.011363 0.019329 0.030887 0.046368 0.065389 0.086626 0.10781 0.12604 0.13843 0.14282 0.13843 0.12604 0.10781 0.086626 0.065389 0.046368 0.030887 0.019329 0.011363 0.0062752 0.0032555 0.0015866 0.0007264 0.00031242 0.00012623 4.7912e-05 1.7083e-05 5.7222e-06 1.8006e-06 5.3225e-07 1.478e-07 3.8556e-08 9.4485e-09 2.1752e-09 4.7042e-10 9.5571e-11 1.824e-11 3.2702e-12 5.508e-13 8.7149e-14 1.2954e-14 1.8087e-15 2.3725e-16 2.9235e-17 3.3842e-18 3.6802e-19 3.7595e-20 3.6079e-21 3.2526e-22 2.7547e-23 2.1916e-24 1.638e-25 1.1501e-26 7.5854e-28 4.7e-29 2.7357e-30 1.4959e-31 7.6841e-33 3.708e-34 1.6809e-35 7.1581e-37 2.8636e-38 1.0762e-39 3.7994e-41 1.2601e-42 3.9259e-44 1.149e-45 3.1593e-47 8.1602e-49 1.98e-50 +1.7178e-50 7.0796e-49 2.7409e-47 9.9688e-46 3.406e-44 1.0932e-42 3.2962e-41 9.3366e-40 2.4844e-38 6.2102e-37 1.4583e-35 3.217e-34 6.6665e-33 1.2978e-31 2.3735e-30 4.0776e-29 6.5809e-28 9.9776e-27 1.4211e-25 1.9014e-24 2.3899e-23 2.8219e-22 3.1301e-21 3.2617e-20 3.1928e-19 2.9361e-18 2.5364e-17 2.0583e-16 1.5692e-15 1.1238e-14 7.5609e-14 4.7786e-13 2.8372e-12 1.5825e-11 8.2915e-11 4.0812e-10 1.8871e-09 8.1973e-09 3.345e-08 1.2823e-07 4.6177e-07 1.5621e-06 4.9645e-06 1.4821e-05 4.1567e-05 0.00010951 0.00027105 0.00063021 0.0013765 0.0028244 0.0054442 0.0098581 0.016769 0.026797 0.040227 0.05673 0.075155 0.093531 0.10935 0.1201 0.12391 0.1201 0.10935 0.093531 0.075155 0.05673 0.040227 0.026797 0.016769 0.0098581 0.0054442 0.0028244 0.0013765 0.00063021 0.00027105 0.00010951 4.1567e-05 1.4821e-05 4.9645e-06 1.5621e-06 4.6177e-07 1.2823e-07 3.345e-08 8.1973e-09 1.8871e-09 4.0812e-10 8.2915e-11 1.5825e-11 2.8372e-12 4.7786e-13 7.5609e-14 1.1238e-14 1.5692e-15 2.0583e-16 2.5364e-17 2.9361e-18 3.1928e-19 3.2617e-20 3.1301e-21 2.8219e-22 2.3899e-23 1.9014e-24 1.4211e-25 9.9776e-27 6.5809e-28 4.0776e-29 2.3735e-30 1.2978e-31 6.6665e-33 3.217e-34 1.4583e-35 6.2102e-37 2.4844e-38 9.3366e-40 3.2962e-41 1.0932e-42 3.406e-44 9.9688e-46 2.7409e-47 7.0796e-49 1.7178e-50 +1.486e-50 6.1241e-49 2.371e-47 8.6234e-46 2.9463e-44 9.4568e-43 2.8514e-41 8.0766e-40 2.1491e-38 5.3721e-37 1.2615e-35 2.7828e-34 5.7669e-33 1.1227e-31 2.0531e-30 3.5273e-29 5.6928e-28 8.6311e-27 1.2293e-25 1.6448e-24 2.0674e-23 2.4411e-22 2.7077e-21 2.8215e-20 2.762e-19 2.5398e-18 2.1941e-17 1.7806e-16 1.3574e-15 9.7216e-15 6.5405e-14 4.1337e-13 2.4543e-12 1.3689e-11 7.1725e-11 3.5304e-10 1.6325e-09 7.0911e-09 2.8936e-08 1.1092e-07 3.9945e-07 1.3513e-06 4.2945e-06 1.2821e-05 3.5957e-05 9.4735e-05 0.00023447 0.00054516 0.0011907 0.0024432 0.0047095 0.0085278 0.014506 0.023181 0.034799 0.049074 0.065012 0.080909 0.094592 0.10389 0.10719 0.10389 0.094592 0.080909 0.065012 0.049074 0.034799 0.023181 0.014506 0.0085278 0.0047095 0.0024432 0.0011907 0.00054516 0.00023447 9.4735e-05 3.5957e-05 1.2821e-05 4.2945e-06 1.3513e-06 3.9945e-07 1.1092e-07 2.8936e-08 7.0911e-09 1.6325e-09 3.5304e-10 7.1725e-11 1.3689e-11 2.4543e-12 4.1337e-13 6.5405e-14 9.7216e-15 1.3574e-15 1.7806e-16 2.1941e-17 2.5398e-18 2.762e-19 2.8215e-20 2.7077e-21 2.4411e-22 2.0674e-23 1.6448e-24 1.2293e-25 8.6311e-27 5.6928e-28 3.5273e-29 2.0531e-30 1.1227e-31 5.7669e-33 2.7828e-34 1.2615e-35 5.3721e-37 2.1491e-38 8.0766e-40 2.8514e-41 9.4568e-43 2.9463e-44 8.6234e-46 2.371e-47 6.1241e-49 1.486e-50 +1.2817e-50 5.2823e-49 2.0451e-47 7.438e-46 2.5413e-44 8.1568e-43 2.4594e-41 6.9664e-40 1.8537e-38 4.6336e-37 1.0881e-35 2.4003e-34 4.9741e-33 9.6834e-32 1.7709e-30 3.0424e-29 4.9102e-28 7.4446e-27 1.0603e-25 1.4187e-24 1.7832e-23 2.1055e-22 2.3355e-21 2.4336e-20 2.3823e-19 2.1907e-18 1.8925e-17 1.5358e-16 1.1708e-15 8.3852e-15 5.6414e-14 3.5655e-13 2.1169e-12 1.1807e-11 6.1865e-11 3.0451e-10 1.408e-09 6.1163e-09 2.4958e-08 9.5675e-08 3.4454e-07 1.1656e-06 3.7041e-06 1.1059e-05 3.1014e-05 8.1712e-05 0.00020224 0.00047022 0.0010271 0.0021074 0.0040621 0.0073555 0.012512 0.019994 0.030015 0.042328 0.056075 0.069787 0.081589 0.089608 0.092452 0.089608 0.081589 0.069787 0.056075 0.042328 0.030015 0.019994 0.012512 0.0073555 0.0040621 0.0021074 0.0010271 0.00047022 0.00020224 8.1712e-05 3.1014e-05 1.1059e-05 3.7041e-06 1.1656e-06 3.4454e-07 9.5675e-08 2.4958e-08 6.1163e-09 1.408e-09 3.0451e-10 6.1865e-11 1.1807e-11 2.1169e-12 3.5655e-13 5.6414e-14 8.3852e-15 1.1708e-15 1.5358e-16 1.8925e-17 2.1907e-18 2.3823e-19 2.4336e-20 2.3355e-21 2.1055e-22 1.7832e-23 1.4187e-24 1.0603e-25 7.4446e-27 4.9102e-28 3.0424e-29 1.7709e-30 9.6834e-32 4.9741e-33 2.4003e-34 1.0881e-35 4.6336e-37 1.8537e-38 6.9664e-40 2.4594e-41 8.1568e-43 2.5413e-44 7.438e-46 2.0451e-47 5.2823e-49 1.2817e-50 +1.1023e-50 4.543e-49 1.7589e-47 6.397e-46 2.1856e-44 7.0151e-43 2.1152e-41 5.9913e-40 1.5942e-38 3.9851e-37 9.3579e-36 2.0643e-34 4.2779e-33 8.3281e-32 1.523e-30 2.6166e-29 4.223e-28 6.4026e-27 9.1191e-26 1.2201e-24 1.5336e-23 1.8108e-22 2.0086e-21 2.093e-20 2.0489e-19 1.8841e-18 1.6276e-17 1.3208e-16 1.007e-15 7.2116e-15 4.8518e-14 3.0664e-13 1.8206e-12 1.0155e-11 5.3207e-11 2.6189e-10 1.211e-09 5.2602e-09 2.1465e-08 8.2284e-08 2.9632e-07 1.0024e-06 3.1857e-06 9.5107e-06 2.6674e-05 7.0275e-05 0.00017393 0.00040441 0.00088331 0.0018124 0.0034935 0.006326 0.010761 0.017196 0.025814 0.036404 0.048227 0.060019 0.07017 0.077066 0.079513 0.077066 0.07017 0.060019 0.048227 0.036404 0.025814 0.017196 0.010761 0.006326 0.0034935 0.0018124 0.00088331 0.00040441 0.00017393 7.0275e-05 2.6674e-05 9.5107e-06 3.1857e-06 1.0024e-06 2.9632e-07 8.2284e-08 2.1465e-08 5.2602e-09 1.211e-09 2.6189e-10 5.3207e-11 1.0155e-11 1.8206e-12 3.0664e-13 4.8518e-14 7.2116e-15 1.007e-15 1.3208e-16 1.6276e-17 1.8841e-18 2.0489e-19 2.093e-20 2.0086e-21 1.8108e-22 1.5336e-23 1.2201e-24 9.1191e-26 6.4026e-27 4.223e-28 2.6166e-29 1.523e-30 8.3281e-32 4.2779e-33 2.0643e-34 9.3579e-36 3.9851e-37 1.5942e-38 5.9913e-40 2.1152e-41 7.0151e-43 2.1856e-44 6.397e-46 1.7589e-47 4.543e-49 1.1023e-50 +9.4531e-51 3.8959e-49 1.5083e-47 5.4858e-46 1.8743e-44 6.0159e-43 1.8139e-41 5.1379e-40 1.3672e-38 3.4175e-37 8.025e-36 1.7703e-34 3.6686e-33 7.1418e-32 1.3061e-30 2.2439e-29 3.6215e-28 5.4906e-27 7.8202e-26 1.0463e-24 1.3152e-23 1.5529e-22 1.7225e-21 1.7949e-20 1.757e-19 1.6157e-18 1.3958e-17 1.1327e-16 8.6353e-16 6.1844e-15 4.1607e-14 2.6297e-13 1.5613e-12 8.7082e-12 4.5628e-11 2.2459e-10 1.0385e-09 4.511e-09 1.8408e-08 7.0564e-08 2.5411e-07 8.5964e-07 2.7319e-06 8.156e-06 2.2874e-05 6.0265e-05 0.00014916 0.0003468 0.00075749 0.0015543 0.0029959 0.0054249 0.0092281 0.014746 0.022137 0.031218 0.041358 0.05147 0.060175 0.066089 0.068187 0.066089 0.060175 0.05147 0.041358 0.031218 0.022137 0.014746 0.0092281 0.0054249 0.0029959 0.0015543 0.00075749 0.0003468 0.00014916 6.0265e-05 2.2874e-05 8.156e-06 2.7319e-06 8.5964e-07 2.5411e-07 7.0564e-08 1.8408e-08 4.511e-09 1.0385e-09 2.2459e-10 4.5628e-11 8.7082e-12 1.5613e-12 2.6297e-13 4.1607e-14 6.1844e-15 8.6353e-16 1.1327e-16 1.3958e-17 1.6157e-18 1.757e-19 1.7949e-20 1.7225e-21 1.5529e-22 1.3152e-23 1.0463e-24 7.8202e-26 5.4906e-27 3.6215e-28 2.2439e-29 1.3061e-30 7.1418e-32 3.6686e-33 1.7703e-34 8.025e-36 3.4175e-37 1.3672e-38 5.1379e-40 1.8139e-41 6.0159e-43 1.8743e-44 5.4858e-46 1.5083e-47 3.8959e-49 9.4531e-51 +8.0833e-51 3.3314e-49 1.2898e-47 4.6909e-46 1.6027e-44 5.1442e-43 1.5511e-41 4.3934e-40 1.1691e-38 2.9223e-37 6.8622e-36 1.5138e-34 3.137e-33 6.107e-32 1.1169e-30 1.9188e-29 3.0967e-28 4.695e-27 6.687e-26 8.9472e-25 1.1246e-23 1.3279e-22 1.4729e-21 1.5348e-20 1.5024e-19 1.3816e-18 1.1935e-17 9.6858e-17 7.384e-16 5.2882e-15 3.5578e-14 2.2486e-13 1.3351e-12 7.4464e-12 3.9016e-11 1.9205e-10 8.8801e-10 3.8573e-09 1.574e-08 6.0339e-08 2.1729e-07 7.3508e-07 2.3361e-06 6.9742e-06 1.956e-05 5.1533e-05 0.00012755 0.00029655 0.00064773 0.0013291 0.0025618 0.0046388 0.0078909 0.01261 0.018929 0.026695 0.035365 0.044012 0.051455 0.056513 0.058307 0.056513 0.051455 0.044012 0.035365 0.026695 0.018929 0.01261 0.0078909 0.0046388 0.0025618 0.0013291 0.00064773 0.00029655 0.00012755 5.1533e-05 1.956e-05 6.9742e-06 2.3361e-06 7.3508e-07 2.1729e-07 6.0339e-08 1.574e-08 3.8573e-09 8.8801e-10 1.9205e-10 3.9016e-11 7.4464e-12 1.3351e-12 2.2486e-13 3.5578e-14 5.2882e-15 7.384e-16 9.6858e-17 1.1935e-17 1.3816e-18 1.5024e-19 1.5348e-20 1.4729e-21 1.3279e-22 1.1246e-23 8.9472e-25 6.687e-26 4.695e-27 3.0967e-28 1.9188e-29 1.1169e-30 6.107e-32 3.137e-33 1.5138e-34 6.8622e-36 2.9223e-37 1.1691e-38 4.3934e-40 1.5511e-41 5.1442e-43 1.6027e-44 4.6909e-46 1.2898e-47 3.3314e-49 8.0833e-51 +6.8922e-51 2.8405e-49 1.0997e-47 3.9997e-46 1.3666e-44 4.3862e-43 1.3225e-41 3.7461e-40 9.9679e-39 2.4917e-37 5.851e-36 1.2907e-34 2.6748e-33 5.2071e-32 9.5228e-31 1.636e-29 2.6404e-28 4.0032e-27 5.7017e-26 7.6288e-25 9.5888e-24 1.1322e-22 1.2559e-21 1.3087e-20 1.281e-19 1.178e-18 1.0177e-17 8.2586e-17 6.296e-16 4.509e-15 3.0336e-14 1.9173e-13 1.1383e-12 6.3492e-12 3.3267e-11 1.6375e-10 7.5716e-10 3.289e-09 1.3421e-08 5.1448e-08 1.8527e-07 6.2677e-07 1.9919e-06 5.9466e-06 1.6678e-05 4.394e-05 0.00010875 0.00025286 0.00055229 0.0011332 0.0021843 0.0039553 0.0067282 0.010752 0.01614 0.022761 0.030154 0.037527 0.043874 0.048186 0.049715 0.048186 0.043874 0.037527 0.030154 0.022761 0.01614 0.010752 0.0067282 0.0039553 0.0021843 0.0011332 0.00055229 0.00025286 0.00010875 4.394e-05 1.6678e-05 5.9466e-06 1.9919e-06 6.2677e-07 1.8527e-07 5.1448e-08 1.3421e-08 3.289e-09 7.5716e-10 1.6375e-10 3.3267e-11 6.3492e-12 1.1383e-12 1.9173e-13 3.0336e-14 4.509e-15 6.296e-16 8.2586e-17 1.0177e-17 1.178e-18 1.281e-19 1.3087e-20 1.2559e-21 1.1322e-22 9.5888e-24 7.6288e-25 5.7017e-26 4.0032e-27 2.6404e-28 1.636e-29 9.5228e-31 5.2071e-32 2.6748e-33 1.2907e-34 5.851e-36 2.4917e-37 9.9679e-39 3.7461e-40 1.3225e-41 4.3862e-43 1.3666e-44 3.9997e-46 1.0997e-47 2.8405e-49 6.8922e-51 +5.8599e-51 2.415e-49 9.35e-48 3.4006e-46 1.1619e-44 3.7292e-43 1.1244e-41 3.185e-40 8.475e-39 2.1185e-37 4.9747e-36 1.0974e-34 2.2741e-33 4.4272e-32 8.0965e-31 1.391e-29 2.2449e-28 3.4036e-27 4.8477e-26 6.4862e-25 8.1526e-24 9.6263e-23 1.0678e-21 1.1127e-20 1.0892e-19 1.0016e-18 8.6523e-18 7.0216e-17 5.353e-16 3.8337e-15 2.5792e-14 1.6301e-13 9.6785e-13 5.3982e-12 2.8285e-11 1.3922e-10 6.4375e-10 2.7963e-09 1.1411e-08 4.3742e-08 1.5752e-07 5.3289e-07 1.6935e-06 5.0559e-06 1.418e-05 3.7358e-05 9.2463e-05 0.00021498 0.00046957 0.00096349 0.0018572 0.0033629 0.0057205 0.0091413 0.013723 0.019352 0.025637 0.031906 0.037302 0.040968 0.042269 0.040968 0.037302 0.031906 0.025637 0.019352 0.013723 0.0091413 0.0057205 0.0033629 0.0018572 0.00096349 0.00046957 0.00021498 9.2463e-05 3.7358e-05 1.418e-05 5.0559e-06 1.6935e-06 5.3289e-07 1.5752e-07 4.3742e-08 1.1411e-08 2.7963e-09 6.4375e-10 1.3922e-10 2.8285e-11 5.3982e-12 9.6785e-13 1.6301e-13 2.5792e-14 3.8337e-15 5.353e-16 7.0216e-17 8.6523e-18 1.0016e-18 1.0892e-19 1.1127e-20 1.0678e-21 9.6263e-23 8.1526e-24 6.4862e-25 4.8477e-26 3.4036e-27 2.2449e-28 1.391e-29 8.0965e-31 4.4272e-32 2.2741e-33 1.0974e-34 4.9747e-36 2.1185e-37 8.475e-39 3.185e-40 1.1244e-41 3.7292e-43 1.1619e-44 3.4006e-46 9.35e-48 2.415e-49 5.8599e-51 +4.9681e-51 2.0475e-49 7.927e-48 2.8831e-46 9.8505e-45 3.1617e-43 9.533e-42 2.7003e-40 7.1851e-39 1.796e-37 4.2175e-36 9.3038e-35 1.928e-33 3.7534e-32 6.8643e-31 1.1793e-29 1.9033e-28 2.8856e-27 4.1099e-26 5.499e-25 6.9118e-24 8.1613e-23 9.0527e-22 9.4331e-21 9.234e-20 8.4914e-19 7.3355e-18 5.953e-17 4.5383e-16 3.2502e-15 2.1867e-14 1.382e-13 8.2054e-13 4.5766e-12 2.398e-11 1.1803e-10 5.4578e-10 2.3708e-09 9.6741e-09 3.7085e-08 1.3355e-07 4.5179e-07 1.4358e-06 4.2864e-06 1.2022e-05 3.1673e-05 7.839e-05 0.00018226 0.0003981 0.00081685 0.0015745 0.0028511 0.0048498 0.00775 0.011634 0.016407 0.021735 0.02705 0.031625 0.034733 0.035836 0.034733 0.031625 0.02705 0.021735 0.016407 0.011634 0.00775 0.0048498 0.0028511 0.0015745 0.00081685 0.0003981 0.00018226 7.839e-05 3.1673e-05 1.2022e-05 4.2864e-06 1.4358e-06 4.5179e-07 1.3355e-07 3.7085e-08 9.6741e-09 2.3708e-09 5.4578e-10 1.1803e-10 2.398e-11 4.5766e-12 8.2054e-13 1.382e-13 2.1867e-14 3.2502e-15 4.5383e-16 5.953e-17 7.3355e-18 8.4914e-19 9.234e-20 9.4331e-21 9.0527e-22 8.1613e-23 6.9118e-24 5.499e-25 4.1099e-26 2.8856e-27 1.9033e-28 1.1793e-29 6.8643e-31 3.7534e-32 1.928e-33 9.3038e-35 4.2175e-36 1.796e-37 7.1851e-39 2.7003e-40 9.533e-42 3.1617e-43 9.8505e-45 2.8831e-46 7.927e-48 2.0475e-49 4.9681e-51 +4.2e-51 1.7309e-49 6.7015e-48 2.4374e-46 8.3276e-45 2.6729e-43 8.0593e-42 2.2828e-40 6.0743e-39 1.5184e-37 3.5655e-36 7.8654e-35 1.63e-33 3.1731e-32 5.8031e-31 9.9697e-30 1.609e-28 2.4395e-27 3.4745e-26 4.6489e-25 5.8433e-24 6.8995e-23 7.6532e-22 7.9748e-21 7.8064e-20 7.1787e-19 6.2014e-18 5.0326e-17 3.8367e-16 2.7477e-15 1.8486e-14 1.1684e-13 6.9369e-13 3.8691e-12 2.0273e-11 9.9785e-11 4.614e-10 2.0042e-09 8.1785e-09 3.1352e-08 1.129e-07 3.8194e-07 1.2138e-06 3.6237e-06 1.0163e-05 2.6776e-05 6.6271e-05 0.00015409 0.00033655 0.00069056 0.0013311 0.0024103 0.0041001 0.0065519 0.0098355 0.01387 0.018375 0.022868 0.026736 0.029364 0.030296 0.029364 0.026736 0.022868 0.018375 0.01387 0.0098355 0.0065519 0.0041001 0.0024103 0.0013311 0.00069056 0.00033655 0.00015409 6.6271e-05 2.6776e-05 1.0163e-05 3.6237e-06 1.2138e-06 3.8194e-07 1.129e-07 3.1352e-08 8.1785e-09 2.0042e-09 4.614e-10 9.9785e-11 2.0273e-11 3.8691e-12 6.9369e-13 1.1684e-13 1.8486e-14 2.7477e-15 3.8367e-16 5.0326e-17 6.2014e-18 7.1787e-19 7.8064e-20 7.9748e-21 7.6532e-22 6.8995e-23 5.8433e-24 4.6489e-25 3.4745e-26 2.4395e-27 1.609e-28 9.9697e-30 5.8031e-31 3.1731e-32 1.63e-33 7.8654e-35 3.5655e-36 1.5184e-37 6.0743e-39 2.2828e-40 8.0593e-42 2.6729e-43 8.3276e-45 2.4374e-46 6.7015e-48 1.7309e-49 4.2e-51 +3.5407e-51 1.4592e-49 5.6495e-48 2.0547e-46 7.0203e-45 2.2533e-43 6.7941e-42 1.9244e-40 5.1207e-39 1.28e-37 3.0058e-36 6.6307e-35 1.3741e-33 2.675e-32 4.8921e-31 8.4046e-30 1.3564e-28 2.0565e-27 2.9291e-26 3.9191e-25 4.926e-24 5.8164e-23 6.4517e-22 6.7229e-21 6.5809e-20 6.0517e-19 5.2279e-18 4.2426e-17 3.2344e-16 2.3164e-15 1.5584e-14 9.8495e-14 5.8479e-13 3.2617e-12 1.709e-11 8.412e-11 3.8897e-10 1.6896e-09 6.8946e-09 2.643e-08 9.5177e-08 3.2198e-07 1.0233e-06 3.0549e-06 8.5676e-06 2.2573e-05 5.5868e-05 0.0001299 0.00028372 0.00058215 0.0011221 0.0020319 0.0034564 0.0055233 0.0082915 0.011693 0.015491 0.019278 0.022539 0.024754 0.02554 0.024754 0.022539 0.019278 0.015491 0.011693 0.0082915 0.0055233 0.0034564 0.0020319 0.0011221 0.00058215 0.00028372 0.0001299 5.5868e-05 2.2573e-05 8.5676e-06 3.0549e-06 1.0233e-06 3.2198e-07 9.5177e-08 2.643e-08 6.8946e-09 1.6896e-09 3.8897e-10 8.412e-11 1.709e-11 3.2617e-12 5.8479e-13 9.8495e-14 1.5584e-14 2.3164e-15 3.2344e-16 4.2426e-17 5.2279e-18 6.0517e-19 6.5809e-20 6.7229e-21 6.4517e-22 5.8164e-23 4.926e-24 3.9191e-25 2.9291e-26 2.0565e-27 1.3564e-28 8.4046e-30 4.8921e-31 2.675e-32 1.3741e-33 6.6307e-35 3.0058e-36 1.28e-37 5.1207e-39 1.9244e-40 6.7941e-42 2.2533e-43 7.0203e-45 2.0547e-46 5.6495e-48 1.4592e-49 3.5407e-51 +2.9764e-51 1.2267e-49 4.7492e-48 1.7273e-46 5.9015e-45 1.8942e-43 5.7114e-42 1.6178e-40 4.3047e-39 1.076e-37 2.5268e-36 5.574e-35 1.1551e-33 2.2487e-32 4.1125e-31 7.0652e-30 1.1403e-28 1.7288e-27 2.4623e-26 3.2945e-25 4.141e-24 4.8895e-23 5.4236e-22 5.6515e-21 5.5322e-20 5.0873e-19 4.3948e-18 3.5665e-17 2.7189e-16 1.9472e-15 1.3101e-14 8.2798e-14 4.916e-13 2.7419e-12 1.4367e-11 7.0715e-11 3.2698e-10 1.4203e-09 5.7959e-09 2.2218e-08 8.001e-08 2.7067e-07 8.6019e-07 2.568e-06 7.2023e-06 1.8975e-05 4.6965e-05 0.0001092 0.00023851 0.00048938 0.00094331 0.0017081 0.0029056 0.0046431 0.0069702 0.0098295 0.013022 0.016206 0.018947 0.020809 0.02147 0.020809 0.018947 0.016206 0.013022 0.0098295 0.0069702 0.0046431 0.0029056 0.0017081 0.00094331 0.00048938 0.00023851 0.0001092 4.6965e-05 1.8975e-05 7.2023e-06 2.568e-06 8.6019e-07 2.7067e-07 8.001e-08 2.2218e-08 5.7959e-09 1.4203e-09 3.2698e-10 7.0715e-11 1.4367e-11 2.7419e-12 4.916e-13 8.2798e-14 1.3101e-14 1.9472e-15 2.7189e-16 3.5665e-17 4.3948e-18 5.0873e-19 5.5322e-20 5.6515e-21 5.4236e-22 4.8895e-23 4.141e-24 3.2945e-25 2.4623e-26 1.7288e-27 1.1403e-28 7.0652e-30 4.1125e-31 2.2487e-32 1.1551e-33 5.574e-35 2.5268e-36 1.076e-37 4.3047e-39 1.6178e-40 5.7114e-42 1.8942e-43 5.9015e-45 1.7273e-46 4.7492e-48 1.2267e-49 2.9764e-51 +2.4951e-51 1.0283e-49 3.9811e-48 1.4479e-46 4.9471e-45 1.5879e-43 4.7877e-42 1.3561e-40 3.6085e-39 9.0202e-38 2.1181e-36 4.6726e-35 9.683e-34 1.885e-32 3.4474e-31 5.9226e-30 9.5586e-29 1.4492e-27 2.0641e-26 2.7617e-25 3.4713e-24 4.0988e-23 4.5465e-22 4.7375e-21 4.6375e-20 4.2646e-19 3.684e-18 2.9897e-17 2.2792e-16 1.6323e-15 1.0982e-14 6.9408e-14 4.121e-13 2.2985e-12 1.2043e-11 5.9279e-11 2.741e-10 1.1906e-09 4.8586e-09 1.8625e-08 6.707e-08 2.269e-07 7.2108e-07 2.1527e-06 6.0375e-06 1.5907e-05 3.9369e-05 9.1537e-05 0.00019993 0.00041024 0.00079076 0.0014319 0.0024357 0.0038922 0.0058429 0.0082399 0.010916 0.013585 0.015883 0.017444 0.017998 0.017444 0.015883 0.013585 0.010916 0.0082399 0.0058429 0.0038922 0.0024357 0.0014319 0.00079076 0.00041024 0.00019993 9.1537e-05 3.9369e-05 1.5907e-05 6.0375e-06 2.1527e-06 7.2108e-07 2.269e-07 6.707e-08 1.8625e-08 4.8586e-09 1.1906e-09 2.741e-10 5.9279e-11 1.2043e-11 2.2985e-12 4.121e-13 6.9408e-14 1.0982e-14 1.6323e-15 2.2792e-16 2.9897e-17 3.684e-18 4.2646e-19 4.6375e-20 4.7375e-21 4.5465e-22 4.0988e-23 3.4713e-24 2.7617e-25 2.0641e-26 1.4492e-27 9.5586e-29 5.9226e-30 3.4474e-31 1.885e-32 9.683e-34 4.6726e-35 2.1181e-36 9.0202e-38 3.6085e-39 1.3561e-40 4.7877e-42 1.5879e-43 4.9471e-45 1.4479e-46 3.9811e-48 1.0283e-49 2.4951e-51 +2.0857e-51 8.5958e-50 3.3279e-48 1.2104e-46 4.1355e-45 1.3273e-43 4.0022e-42 1.1336e-40 3.0165e-39 7.5402e-38 1.7706e-36 3.9059e-35 8.0943e-34 1.5758e-32 2.8818e-31 4.9509e-30 7.9904e-29 1.2114e-27 1.7254e-26 2.3086e-25 2.9017e-24 3.4263e-23 3.8005e-22 3.9602e-21 3.8766e-20 3.5649e-19 3.0796e-18 2.4992e-17 1.9053e-16 1.3645e-15 9.1802e-15 5.802e-14 3.4448e-13 1.9214e-12 1.0067e-11 4.9553e-11 2.2913e-10 9.953e-10 4.0614e-09 1.5569e-08 5.6066e-08 1.8967e-07 6.0277e-07 1.7995e-06 5.0469e-06 1.3297e-05 3.291e-05 7.6518e-05 0.00016713 0.00034293 0.00066102 0.0011969 0.0020361 0.0032536 0.0048843 0.006888 0.0091251 0.011356 0.013277 0.014582 0.015045 0.014582 0.013277 0.011356 0.0091251 0.006888 0.0048843 0.0032536 0.0020361 0.0011969 0.00066102 0.00034293 0.00016713 7.6518e-05 3.291e-05 1.3297e-05 5.0469e-06 1.7995e-06 6.0277e-07 1.8967e-07 5.6066e-08 1.5569e-08 4.0614e-09 9.953e-10 2.2913e-10 4.9553e-11 1.0067e-11 1.9214e-12 3.4448e-13 5.802e-14 9.1802e-15 1.3645e-15 1.9053e-16 2.4992e-17 3.0796e-18 3.5649e-19 3.8766e-20 3.9602e-21 3.8005e-22 3.4263e-23 2.9017e-24 2.3086e-25 1.7254e-26 1.2114e-27 7.9904e-29 4.9509e-30 2.8818e-31 1.5758e-32 8.0943e-34 3.9059e-35 1.7706e-36 7.5402e-38 3.0165e-39 1.1336e-40 4.0022e-42 1.3273e-43 4.1355e-45 1.2104e-46 3.3279e-48 8.5958e-50 2.0857e-51 +1.7386e-51 7.1654e-50 2.7742e-48 1.009e-46 3.4473e-45 1.1065e-43 3.3362e-42 9.4499e-41 2.5145e-39 6.2855e-38 1.476e-36 3.256e-35 6.7474e-34 1.3136e-32 2.4022e-31 4.1271e-30 6.6607e-29 1.0099e-27 1.4383e-26 1.9244e-25 2.4189e-24 2.8561e-23 3.1681e-22 3.3012e-21 3.2316e-20 2.9717e-19 2.5671e-18 2.0833e-17 1.5882e-16 1.1374e-15 7.6525e-15 4.8366e-14 2.8716e-13 1.6016e-12 8.392e-12 4.1307e-11 1.91e-10 8.2967e-10 3.3856e-09 1.2978e-08 4.6737e-08 1.5811e-07 5.0247e-07 1.5001e-06 4.2071e-06 1.1084e-05 2.7434e-05 6.3785e-05 0.00013932 0.00028587 0.00055102 0.00099777 0.0016973 0.0027122 0.0040715 0.0057418 0.0076066 0.0094666 0.011068 0.012155 0.012541 0.012155 0.011068 0.0094666 0.0076066 0.0057418 0.0040715 0.0027122 0.0016973 0.00099777 0.00055102 0.00028587 0.00013932 6.3785e-05 2.7434e-05 1.1084e-05 4.2071e-06 1.5001e-06 5.0247e-07 1.5811e-07 4.6737e-08 1.2978e-08 3.3856e-09 8.2967e-10 1.91e-10 4.1307e-11 8.392e-12 1.6016e-12 2.8716e-13 4.8366e-14 7.6525e-15 1.1374e-15 1.5882e-16 2.0833e-17 2.5671e-18 2.9717e-19 3.2316e-20 3.3012e-21 3.1681e-22 2.8561e-23 2.4189e-24 1.9244e-25 1.4383e-26 1.0099e-27 6.6607e-29 4.1271e-30 2.4022e-31 1.3136e-32 6.7474e-34 3.256e-35 1.476e-36 6.2855e-38 2.5145e-39 9.4499e-41 3.3362e-42 1.1065e-43 3.4473e-45 1.009e-46 2.7742e-48 7.1654e-50 1.7386e-51 +1.4453e-51 5.9564e-50 2.3061e-48 8.3873e-47 2.8656e-45 9.1977e-44 2.7733e-42 7.8554e-41 2.0902e-39 5.225e-38 1.2269e-36 2.7066e-35 5.6089e-34 1.0919e-32 1.9969e-31 3.4307e-30 5.5369e-29 8.3947e-28 1.1956e-26 1.5997e-25 2.0107e-24 2.3742e-23 2.6336e-22 2.7442e-21 2.6863e-20 2.4703e-19 2.134e-18 1.7318e-17 1.3203e-16 9.4553e-16 6.3613e-15 4.0205e-14 2.3871e-13 1.3314e-12 6.9761e-12 3.4337e-11 1.5877e-10 6.8968e-10 2.8143e-09 1.0788e-08 3.8851e-08 1.3143e-07 4.1769e-07 1.247e-06 3.4972e-06 9.214e-06 2.2805e-05 5.3023e-05 0.00011581 0.00023763 0.00045805 0.00082942 0.0014109 0.0022546 0.0033845 0.004773 0.0063232 0.0078693 0.0092001 0.010104 0.010425 0.010104 0.0092001 0.0078693 0.0063232 0.004773 0.0033845 0.0022546 0.0014109 0.00082942 0.00045805 0.00023763 0.00011581 5.3023e-05 2.2805e-05 9.214e-06 3.4972e-06 1.247e-06 4.1769e-07 1.3143e-07 3.8851e-08 1.0788e-08 2.8143e-09 6.8968e-10 1.5877e-10 3.4337e-11 6.9761e-12 1.3314e-12 2.3871e-13 4.0205e-14 6.3613e-15 9.4553e-16 1.3203e-16 1.7318e-17 2.134e-18 2.4703e-19 2.6863e-20 2.7442e-21 2.6336e-22 2.3742e-23 2.0107e-24 1.5997e-25 1.1956e-26 8.3947e-28 5.5369e-29 3.4307e-30 1.9969e-31 1.0919e-32 5.6089e-34 2.7066e-35 1.2269e-36 5.225e-38 2.0902e-39 7.8554e-41 2.7733e-42 9.1977e-44 2.8656e-45 8.3873e-47 2.3061e-48 5.9564e-50 1.4453e-51 +1.1981e-51 4.9376e-50 1.9117e-48 6.9527e-47 2.3755e-45 7.6246e-44 2.299e-42 6.5118e-41 1.7327e-39 4.3313e-38 1.0171e-36 2.2437e-35 4.6496e-34 9.0516e-33 1.6554e-31 2.8439e-30 4.5899e-29 6.9589e-28 9.9113e-27 1.3261e-25 1.6668e-24 1.9681e-23 2.1831e-22 2.2749e-21 2.2268e-20 2.0478e-19 1.769e-18 1.4356e-17 1.0944e-16 7.8381e-16 5.2733e-15 3.3328e-14 1.9788e-13 1.1037e-12 5.7829e-12 2.8464e-11 1.3162e-10 5.7172e-10 2.333e-09 8.9432e-09 3.2206e-08 1.0895e-07 3.4625e-07 1.0337e-06 2.8991e-06 7.6381e-06 1.8904e-05 4.3954e-05 9.6004e-05 0.00019699 0.0003797 0.00068756 0.0011696 0.001869 0.0028057 0.0039566 0.0052417 0.0065233 0.0076266 0.0083761 0.008642 0.0083761 0.0076266 0.0065233 0.0052417 0.0039566 0.0028057 0.001869 0.0011696 0.00068756 0.0003797 0.00019699 9.6004e-05 4.3954e-05 1.8904e-05 7.6381e-06 2.8991e-06 1.0337e-06 3.4625e-07 1.0895e-07 3.2206e-08 8.9432e-09 2.333e-09 5.7172e-10 1.3162e-10 2.8464e-11 5.7829e-12 1.1037e-12 1.9788e-13 3.3328e-14 5.2733e-15 7.8381e-16 1.0944e-16 1.4356e-17 1.769e-18 2.0478e-19 2.2268e-20 2.2749e-21 2.1831e-22 1.9681e-23 1.6668e-24 1.3261e-25 9.9113e-27 6.9589e-28 4.5899e-29 2.8439e-30 1.6554e-31 9.0516e-33 4.6496e-34 2.2437e-35 1.0171e-36 4.3313e-38 1.7327e-39 6.5118e-41 2.299e-42 7.6246e-44 2.3755e-45 6.9527e-47 1.9117e-48 4.9376e-50 1.1981e-51 +9.9041e-52 4.0818e-50 1.5803e-48 5.7476e-47 1.9637e-45 6.303e-44 1.9005e-42 5.3831e-41 1.4324e-39 3.5805e-38 8.4079e-37 1.8548e-35 3.8436e-34 7.4826e-33 1.3684e-31 2.351e-30 3.7943e-29 5.7526e-28 8.1933e-27 1.0963e-25 1.3779e-24 1.627e-23 1.8047e-22 1.8805e-21 1.8408e-20 1.6928e-19 1.4624e-18 1.1868e-17 9.0473e-17 6.4795e-16 4.3593e-15 2.7551e-14 1.6358e-13 9.1237e-13 4.7805e-12 2.353e-11 1.088e-10 4.7262e-10 1.9286e-09 7.393e-09 2.6623e-08 9.0066e-08 2.8623e-07 8.5452e-07 2.3966e-06 6.3141e-06 1.5628e-05 3.6335e-05 7.9363e-05 0.00016284 0.00031389 0.00056838 0.00096684 0.001545 0.0023193 0.0032708 0.0043331 0.0053926 0.0063046 0.0069242 0.007144 0.0069242 0.0063046 0.0053926 0.0043331 0.0032708 0.0023193 0.001545 0.00096684 0.00056838 0.00031389 0.00016284 7.9363e-05 3.6335e-05 1.5628e-05 6.3141e-06 2.3966e-06 8.5452e-07 2.8623e-07 9.0066e-08 2.6623e-08 7.393e-09 1.9286e-09 4.7262e-10 1.088e-10 2.353e-11 4.7805e-12 9.1237e-13 1.6358e-13 2.7551e-14 4.3593e-15 6.4795e-16 9.0473e-17 1.1868e-17 1.4624e-18 1.6928e-19 1.8408e-20 1.8805e-21 1.8047e-22 1.627e-23 1.3779e-24 1.0963e-25 8.1933e-27 5.7526e-28 3.7943e-29 2.351e-30 1.3684e-31 7.4826e-33 3.8436e-34 1.8548e-35 8.4079e-37 3.5805e-38 1.4324e-39 5.3831e-41 1.9005e-42 6.303e-44 1.9637e-45 5.7476e-47 1.5803e-48 4.0818e-50 9.9041e-52 +8.1647e-52 3.3649e-50 1.3028e-48 4.7381e-47 1.6189e-45 5.196e-44 1.5667e-42 4.4377e-41 1.1808e-39 2.9517e-38 6.9313e-37 1.529e-35 3.1686e-34 6.1685e-33 1.1281e-31 1.9381e-30 3.1279e-29 4.7423e-28 6.7544e-27 9.0373e-26 1.1359e-24 1.3413e-23 1.4878e-22 1.5503e-21 1.5176e-20 1.3955e-19 1.2055e-18 9.7833e-18 7.4584e-17 5.3415e-16 3.5937e-15 2.2713e-14 1.3485e-13 7.5214e-13 3.9409e-12 1.9398e-11 8.9695e-11 3.8962e-10 1.5899e-09 6.0947e-09 2.1948e-08 7.4248e-08 2.3596e-07 7.0445e-07 1.9757e-06 5.2052e-06 1.2883e-05 2.9954e-05 6.5425e-05 0.00013424 0.00025876 0.00046856 0.00079704 0.0012737 0.001912 0.0026964 0.0035721 0.0044455 0.0051974 0.0057082 0.0058894 0.0057082 0.0051974 0.0044455 0.0035721 0.0026964 0.001912 0.0012737 0.00079704 0.00046856 0.00025876 0.00013424 6.5425e-05 2.9954e-05 1.2883e-05 5.2052e-06 1.9757e-06 7.0445e-07 2.3596e-07 7.4248e-08 2.1948e-08 6.0947e-09 1.5899e-09 3.8962e-10 8.9695e-11 1.9398e-11 3.9409e-12 7.5214e-13 1.3485e-13 2.2713e-14 3.5937e-15 5.3415e-16 7.4584e-17 9.7833e-18 1.2055e-18 1.3955e-19 1.5176e-20 1.5503e-21 1.4878e-22 1.3413e-23 1.1359e-24 9.0373e-26 6.7544e-27 4.7423e-28 3.1279e-29 1.9381e-30 1.1281e-31 6.1685e-33 3.1686e-34 1.529e-35 6.9313e-37 2.9517e-38 1.1808e-39 4.4377e-41 1.5667e-42 5.196e-44 1.6189e-45 4.7381e-47 1.3028e-48 3.3649e-50 8.1647e-52 +6.7122e-52 2.7663e-50 1.071e-48 3.8952e-47 1.3309e-45 4.2716e-44 1.288e-42 3.6482e-41 9.7076e-40 2.4266e-38 5.6982e-37 1.257e-35 2.6049e-34 5.0711e-33 9.2741e-32 1.5933e-30 2.5715e-29 3.8987e-28 5.5528e-27 7.4296e-26 9.3384e-25 1.1026e-23 1.2231e-22 1.2745e-21 1.2476e-20 1.1473e-19 9.9108e-19 8.0429e-18 6.1316e-17 4.3913e-16 2.9544e-15 1.8672e-14 1.1086e-13 6.1833e-13 3.2398e-12 1.5947e-11 7.3738e-11 3.2031e-10 1.307e-09 5.0104e-09 1.8043e-08 6.1039e-08 1.9398e-07 5.7913e-07 1.6242e-06 4.2792e-06 1.0591e-05 2.4625e-05 5.3786e-05 0.00011036 0.00021273 0.0003852 0.00065525 0.0010471 0.0015719 0.0022167 0.0029366 0.0036547 0.0042728 0.0046927 0.0048417 0.0046927 0.0042728 0.0036547 0.0029366 0.0022167 0.0015719 0.0010471 0.00065525 0.0003852 0.00021273 0.00011036 5.3786e-05 2.4625e-05 1.0591e-05 4.2792e-06 1.6242e-06 5.7913e-07 1.9398e-07 6.1039e-08 1.8043e-08 5.0104e-09 1.307e-09 3.2031e-10 7.3738e-11 1.5947e-11 3.2398e-12 6.1833e-13 1.1086e-13 1.8672e-14 2.9544e-15 4.3913e-16 6.1316e-17 8.0429e-18 9.9108e-19 1.1473e-19 1.2476e-20 1.2745e-21 1.2231e-22 1.1026e-23 9.3384e-25 7.4296e-26 5.5528e-27 3.8987e-28 2.5715e-29 1.5933e-30 9.2741e-32 5.0711e-33 2.6049e-34 1.257e-35 5.6982e-37 2.4266e-38 9.7076e-40 3.6482e-41 1.288e-42 4.2716e-44 1.3309e-45 3.8952e-47 1.071e-48 2.7663e-50 6.7122e-52 +5.5029e-52 2.2679e-50 8.7804e-49 3.1935e-47 1.0911e-45 3.502e-44 1.0559e-42 2.991e-41 7.9586e-40 1.9894e-38 4.6716e-37 1.0305e-35 2.1356e-34 4.1575e-33 7.6032e-32 1.3062e-30 2.1082e-29 3.1963e-28 4.5524e-27 6.091e-26 7.6559e-25 9.0399e-24 1.0027e-22 1.0449e-21 1.0228e-20 9.4056e-20 8.1252e-19 6.5938e-18 5.0269e-17 3.6001e-16 2.4221e-15 1.5308e-14 9.0888e-14 5.0693e-13 2.6561e-12 1.3074e-11 6.0453e-11 2.626e-10 1.0716e-09 4.1077e-09 1.4792e-08 5.0042e-08 1.5903e-07 4.7479e-07 1.3316e-06 3.5082e-06 8.683e-06 2.0188e-05 4.4096e-05 9.0479e-05 0.0001744 0.0003158 0.0005372 0.00085844 0.0012887 0.0018173 0.0024075 0.0029962 0.003503 0.0038472 0.0039694 0.0038472 0.003503 0.0029962 0.0024075 0.0018173 0.0012887 0.00085844 0.0005372 0.0003158 0.0001744 9.0479e-05 4.4096e-05 2.0188e-05 8.683e-06 3.5082e-06 1.3316e-06 4.7479e-07 1.5903e-07 5.0042e-08 1.4792e-08 4.1077e-09 1.0716e-09 2.626e-10 6.0453e-11 1.3074e-11 2.6561e-12 5.0693e-13 9.0888e-14 1.5308e-14 2.4221e-15 3.6001e-16 5.0269e-17 6.5938e-18 8.1252e-19 9.4056e-20 1.0228e-20 1.0449e-21 1.0027e-22 9.0399e-24 7.6559e-25 6.091e-26 4.5524e-27 3.1963e-28 2.1082e-29 1.3062e-30 7.6032e-32 4.1575e-33 2.1356e-34 1.0305e-35 4.6716e-37 1.9894e-38 7.9586e-40 2.991e-41 1.0559e-42 3.502e-44 1.0911e-45 3.1935e-47 8.7804e-49 2.2679e-50 5.5029e-52 +4.4991e-52 1.8542e-50 7.1787e-49 2.6109e-47 8.9206e-46 2.8632e-44 8.6331e-43 2.4453e-41 6.5068e-40 1.6265e-38 3.8194e-37 8.4255e-36 1.746e-34 3.3991e-33 6.2163e-32 1.068e-30 1.7236e-29 2.6132e-28 3.7219e-27 4.9799e-26 6.2594e-25 7.3908e-24 8.1981e-23 8.5426e-22 8.3623e-21 7.6898e-20 6.643e-19 5.391e-18 4.1099e-17 2.9434e-16 1.9803e-15 1.2516e-14 7.4309e-14 4.1446e-13 2.1716e-12 1.0689e-11 4.9426e-11 2.147e-10 8.7609e-10 3.3584e-09 1.2094e-08 4.0914e-08 1.3002e-07 3.8818e-07 1.0887e-06 2.8683e-06 7.099e-06 1.6506e-05 3.6052e-05 7.3974e-05 0.00014259 0.00025819 0.0004392 0.00070184 0.0010536 0.0014858 0.0019684 0.0024497 0.002864 0.0031454 0.0032453 0.0031454 0.002864 0.0024497 0.0019684 0.0014858 0.0010536 0.00070184 0.0004392 0.00025819 0.00014259 7.3974e-05 3.6052e-05 1.6506e-05 7.099e-06 2.8683e-06 1.0887e-06 3.8818e-07 1.3002e-07 4.0914e-08 1.2094e-08 3.3584e-09 8.7609e-10 2.147e-10 4.9426e-11 1.0689e-11 2.1716e-12 4.1446e-13 7.4309e-14 1.2516e-14 1.9803e-15 2.9434e-16 4.1099e-17 5.391e-18 6.643e-19 7.6898e-20 8.3623e-21 8.5426e-22 8.1981e-23 7.3908e-24 6.2594e-25 4.9799e-26 3.7219e-27 2.6132e-28 1.7236e-29 1.068e-30 6.2163e-32 3.3991e-33 1.746e-34 8.4255e-36 3.8194e-37 1.6265e-38 6.5068e-40 2.4453e-41 8.6331e-43 2.8632e-44 8.9206e-46 2.6109e-47 7.1787e-49 1.8542e-50 4.4991e-52 +3.6683e-52 1.5118e-50 5.8531e-49 2.1288e-47 7.2733e-46 2.3345e-44 7.0389e-43 1.9938e-41 5.3053e-40 1.3262e-38 3.1141e-37 6.8696e-36 1.4236e-34 2.7714e-33 5.0684e-32 8.7075e-31 1.4053e-29 2.1307e-28 3.0347e-27 4.0603e-26 5.1035e-25 6.026e-24 6.6843e-23 6.9652e-22 6.8181e-21 6.2698e-20 5.4163e-19 4.3955e-18 3.351e-17 2.3999e-16 1.6146e-15 1.0204e-14 6.0587e-14 3.3793e-13 1.7706e-12 8.7152e-12 4.0299e-11 1.7505e-10 7.1431e-10 2.7382e-09 9.8608e-09 3.3359e-08 1.0601e-07 3.165e-07 8.8764e-07 2.3386e-06 5.7881e-06 1.3458e-05 2.9395e-05 6.0314e-05 0.00011626 0.00021052 0.0003581 0.00057224 0.00085903 0.0012114 0.0016049 0.0019973 0.0023351 0.0025646 0.002646 0.0025646 0.0023351 0.0019973 0.0016049 0.0012114 0.00085903 0.00057224 0.0003581 0.00021052 0.00011626 6.0314e-05 2.9395e-05 1.3458e-05 5.7881e-06 2.3386e-06 8.8764e-07 3.165e-07 1.0601e-07 3.3359e-08 9.8608e-09 2.7382e-09 7.1431e-10 1.7505e-10 4.0299e-11 8.7152e-12 1.7706e-12 3.3793e-13 6.0587e-14 1.0204e-14 1.6146e-15 2.3999e-16 3.351e-17 4.3955e-18 5.4163e-19 6.2698e-20 6.8181e-21 6.9652e-22 6.6843e-23 6.026e-24 5.1035e-25 4.0603e-26 3.0347e-27 2.1307e-28 1.4053e-29 8.7075e-31 5.0684e-32 2.7714e-33 1.4236e-34 6.8696e-36 3.1141e-37 1.3262e-38 5.3053e-40 1.9938e-41 7.0389e-43 2.3345e-44 7.2733e-46 2.1288e-47 5.8531e-49 1.5118e-50 3.6683e-52 +2.9827e-52 1.2293e-50 4.7592e-49 1.7309e-47 5.914e-46 1.8982e-44 5.7234e-43 1.6212e-41 4.3138e-40 1.0783e-38 2.5321e-37 5.5858e-36 1.1575e-34 2.2535e-33 4.1211e-32 7.0801e-31 1.1427e-29 1.7325e-28 2.4675e-27 3.3015e-26 4.1497e-25 4.8998e-24 5.435e-23 5.6634e-22 5.5439e-21 5.0981e-20 4.404e-19 3.574e-18 2.7247e-17 1.9513e-16 1.3128e-15 8.2973e-15 4.9263e-14 2.7477e-13 1.4397e-12 7.0864e-12 3.2767e-11 1.4233e-10 5.8081e-10 2.2265e-09 8.0179e-09 2.7124e-08 8.62e-08 2.5735e-07 7.2175e-07 1.9015e-06 4.7064e-06 1.0943e-05 2.3901e-05 4.9042e-05 9.453e-05 0.00017117 0.00029117 0.00046529 0.00069849 0.00098503 0.0013049 0.001624 0.0018987 0.0020853 0.0021515 0.0020853 0.0018987 0.001624 0.0013049 0.00098503 0.00069849 0.00046529 0.00029117 0.00017117 9.453e-05 4.9042e-05 2.3901e-05 1.0943e-05 4.7064e-06 1.9015e-06 7.2175e-07 2.5735e-07 8.62e-08 2.7124e-08 8.0179e-09 2.2265e-09 5.8081e-10 1.4233e-10 3.2767e-11 7.0864e-12 1.4397e-12 2.7477e-13 4.9263e-14 8.2973e-15 1.3128e-15 1.9513e-16 2.7247e-17 3.574e-18 4.404e-19 5.0981e-20 5.5439e-21 5.6634e-22 5.435e-23 4.8998e-24 4.1497e-25 3.3015e-26 2.4675e-27 1.7325e-28 1.1427e-29 7.0801e-31 4.1211e-32 2.2535e-33 1.1575e-34 5.5858e-36 2.5321e-37 1.0783e-38 4.3138e-40 1.6212e-41 5.7234e-43 1.8982e-44 5.914e-46 1.7309e-47 4.7592e-49 1.2293e-50 2.9827e-52 +2.4186e-52 9.9679e-51 3.8592e-49 1.4036e-47 4.7956e-46 1.5392e-44 4.641e-43 1.3146e-41 3.498e-40 8.7438e-39 2.0533e-37 4.5294e-36 9.3864e-35 1.8273e-33 3.3418e-32 5.7412e-31 9.2658e-30 1.4048e-28 2.0009e-27 2.6771e-26 3.3649e-25 3.9732e-24 4.4072e-23 4.5924e-22 4.4954e-21 4.1339e-20 3.5712e-19 2.8981e-18 2.2094e-17 1.5823e-16 1.0646e-15 6.7282e-15 3.9947e-14 2.2281e-13 1.1674e-12 5.7463e-12 2.657e-11 1.1542e-10 4.7097e-10 1.8054e-09 6.5016e-09 2.1995e-08 6.9899e-08 2.0868e-07 5.8525e-07 1.5419e-06 3.8163e-06 8.8732e-06 1.9381e-05 3.9767e-05 7.6653e-05 0.0001388 0.00023611 0.0003773 0.00056639 0.00079874 0.0010582 0.0013169 0.0015396 0.0016909 0.0017446 0.0016909 0.0015396 0.0013169 0.0010582 0.00079874 0.00056639 0.0003773 0.00023611 0.0001388 7.6653e-05 3.9767e-05 1.9381e-05 8.8732e-06 3.8163e-06 1.5419e-06 5.8525e-07 2.0868e-07 6.9899e-08 2.1995e-08 6.5016e-09 1.8054e-09 4.7097e-10 1.1542e-10 2.657e-11 5.7463e-12 1.1674e-12 2.2281e-13 3.9947e-14 6.7282e-15 1.0646e-15 1.5823e-16 2.2094e-17 2.8981e-18 3.5712e-19 4.1339e-20 4.4954e-21 4.5924e-22 4.4072e-23 3.9732e-24 3.3649e-25 2.6771e-26 2.0009e-27 1.4048e-28 9.2658e-30 5.7412e-31 3.3418e-32 1.8273e-33 9.3864e-35 4.5294e-36 2.0533e-37 8.7438e-39 3.498e-40 1.3146e-41 4.641e-43 1.5392e-44 4.7956e-46 1.4036e-47 3.8592e-49 9.9679e-51 2.4186e-52 +1.9559e-52 8.0608e-51 3.1208e-49 1.135e-47 3.8781e-46 1.2447e-44 3.7531e-43 1.0631e-41 2.8287e-40 7.0709e-39 1.6604e-37 3.6628e-36 7.5905e-35 1.4777e-33 2.7024e-32 4.6428e-31 7.493e-30 1.136e-28 1.618e-27 2.1649e-26 2.7211e-25 3.213e-24 3.564e-23 3.7137e-22 3.6354e-21 3.343e-20 2.8879e-19 2.3436e-18 1.7867e-17 1.2796e-16 8.6088e-16 5.4409e-15 3.2304e-14 1.8018e-13 9.4407e-13 4.6469e-12 2.1487e-11 9.3335e-11 3.8086e-10 1.46e-09 5.2577e-09 1.7786e-08 5.6525e-08 1.6875e-07 4.7328e-07 1.2469e-06 3.0862e-06 7.1756e-06 1.5673e-05 3.2159e-05 6.1987e-05 0.00011224 0.00019093 0.00030511 0.00045803 0.00064592 0.00085571 0.0010649 0.001245 0.0013674 0.0014108 0.0013674 0.001245 0.0010649 0.00085571 0.00064592 0.00045803 0.00030511 0.00019093 0.00011224 6.1987e-05 3.2159e-05 1.5673e-05 7.1756e-06 3.0862e-06 1.2469e-06 4.7328e-07 1.6875e-07 5.6525e-08 1.7786e-08 5.2577e-09 1.46e-09 3.8086e-10 9.3335e-11 2.1487e-11 4.6469e-12 9.4407e-13 1.8018e-13 3.2304e-14 5.4409e-15 8.6088e-16 1.2796e-16 1.7867e-17 2.3436e-18 2.8879e-19 3.343e-20 3.6354e-21 3.7137e-22 3.564e-23 3.213e-24 2.7211e-25 2.1649e-26 1.618e-27 1.136e-28 7.493e-30 4.6428e-31 2.7024e-32 1.4777e-33 7.5905e-35 3.6628e-36 1.6604e-37 7.0709e-39 2.8287e-40 1.0631e-41 3.7531e-43 1.2447e-44 3.8781e-46 1.135e-47 3.1208e-49 8.0608e-51 1.9559e-52 +1.5774e-52 6.5008e-51 2.5168e-49 9.1538e-48 3.1275e-46 1.0038e-44 3.0268e-43 8.5733e-42 2.2813e-40 5.7025e-39 1.3391e-37 2.954e-36 6.1215e-35 1.1917e-33 2.1794e-32 3.7443e-31 6.0429e-30 9.1619e-29 1.3049e-27 1.7459e-26 2.1945e-25 2.5912e-24 2.8742e-23 2.995e-22 2.9318e-21 2.696e-20 2.329e-19 1.8901e-18 1.4409e-17 1.0319e-16 6.9427e-16 4.3879e-15 2.6052e-14 1.4531e-13 7.6136e-13 3.7476e-12 1.7329e-11 7.5272e-11 3.0716e-10 1.1774e-09 4.2402e-09 1.4344e-08 4.5586e-08 1.3609e-07 3.8169e-07 1.0056e-06 2.4889e-06 5.7869e-06 1.264e-05 2.5935e-05 4.9991e-05 9.0522e-05 0.00015398 0.00024606 0.00036939 0.00052092 0.00069011 0.00085885 0.0010041 0.0011028 0.0011378 0.0011028 0.0010041 0.00085885 0.00069011 0.00052092 0.00036939 0.00024606 0.00015398 9.0522e-05 4.9991e-05 2.5935e-05 1.264e-05 5.7869e-06 2.4889e-06 1.0056e-06 3.8169e-07 1.3609e-07 4.5586e-08 1.4344e-08 4.2402e-09 1.1774e-09 3.0716e-10 7.5272e-11 1.7329e-11 3.7476e-12 7.6136e-13 1.4531e-13 2.6052e-14 4.3879e-15 6.9427e-16 1.0319e-16 1.4409e-17 1.8901e-18 2.329e-19 2.696e-20 2.9318e-21 2.995e-22 2.8742e-23 2.5912e-24 2.1945e-25 1.7459e-26 1.3049e-27 9.1619e-29 6.0429e-30 3.7443e-31 2.1794e-32 1.1917e-33 6.1215e-35 2.954e-36 1.3391e-37 5.7025e-39 2.2813e-40 8.5733e-42 3.0268e-43 1.0038e-44 3.1275e-46 9.1538e-48 2.5168e-49 6.5008e-51 1.5774e-52 +1.2686e-52 5.2285e-51 2.0242e-49 7.3622e-48 2.5154e-46 8.0736e-45 2.4344e-43 6.8954e-42 1.8348e-40 4.5864e-39 1.077e-37 2.3758e-36 4.9234e-35 9.5847e-34 1.7529e-32 3.0114e-31 4.8602e-30 7.3687e-29 1.0495e-27 1.4042e-26 1.765e-25 2.0841e-24 2.3117e-23 2.4088e-22 2.358e-21 2.1684e-20 1.8732e-19 1.5201e-18 1.1589e-17 8.2997e-17 5.5839e-16 3.5291e-15 2.0953e-14 1.1687e-13 6.1235e-13 3.0141e-12 1.3937e-11 6.054e-11 2.4704e-10 9.47e-10 3.4103e-09 1.1537e-08 3.6664e-08 1.0946e-07 3.0698e-07 8.0879e-07 2.0018e-06 4.6543e-06 1.0166e-05 2.0859e-05 4.0207e-05 7.2805e-05 0.00012385 0.0001979 0.00029709 0.00041896 0.00055504 0.00069076 0.00080758 0.00088695 0.0009151 0.00088695 0.00080758 0.00069076 0.00055504 0.00041896 0.00029709 0.0001979 0.00012385 7.2805e-05 4.0207e-05 2.0859e-05 1.0166e-05 4.6543e-06 2.0018e-06 8.0879e-07 3.0698e-07 1.0946e-07 3.6664e-08 1.1537e-08 3.4103e-09 9.47e-10 2.4704e-10 6.054e-11 1.3937e-11 3.0141e-12 6.1235e-13 1.1687e-13 2.0953e-14 3.5291e-15 5.5839e-16 8.2997e-17 1.1589e-17 1.5201e-18 1.8732e-19 2.1684e-20 2.358e-21 2.4088e-22 2.3117e-23 2.0841e-24 1.765e-25 1.4042e-26 1.0495e-27 7.3687e-29 4.8602e-30 3.0114e-31 1.7529e-32 9.5847e-34 4.9234e-35 2.3758e-36 1.077e-37 4.5864e-39 1.8348e-40 6.8954e-42 2.4344e-43 8.0736e-45 2.5154e-46 7.3622e-48 2.0242e-49 5.2285e-51 1.2686e-52 +1.0176e-52 4.1937e-51 1.6236e-49 5.9052e-48 2.0176e-46 6.4759e-45 1.9526e-43 5.5308e-42 1.4717e-40 3.6787e-39 8.6386e-38 1.9056e-36 3.9491e-35 7.6879e-34 1.406e-32 2.4155e-31 3.8984e-30 5.9104e-29 8.4181e-28 1.1263e-26 1.4157e-25 1.6716e-24 1.8542e-23 1.9321e-22 1.8913e-21 1.7392e-20 1.5025e-19 1.2193e-18 9.2955e-18 6.6572e-17 4.4788e-16 2.8307e-15 1.6807e-14 9.374e-14 4.9116e-13 2.4176e-12 1.1179e-11 4.8559e-11 1.9815e-10 7.5959e-10 2.7354e-09 9.2536e-09 2.9408e-08 8.7796e-08 2.4623e-07 6.4873e-07 1.6056e-06 3.7332e-06 8.154e-06 1.6731e-05 3.225e-05 5.8397e-05 9.9336e-05 0.00015874 0.0002383 0.00033605 0.00044519 0.00055405 0.00064775 0.00071142 0.000734 0.00071142 0.00064775 0.00055405 0.00044519 0.00033605 0.0002383 0.00015874 9.9336e-05 5.8397e-05 3.225e-05 1.6731e-05 8.154e-06 3.7332e-06 1.6056e-06 6.4873e-07 2.4623e-07 8.7796e-08 2.9408e-08 9.2536e-09 2.7354e-09 7.5959e-10 1.9815e-10 4.8559e-11 1.1179e-11 2.4176e-12 4.9116e-13 9.374e-14 1.6807e-14 2.8307e-15 4.4788e-16 6.6572e-17 9.2955e-18 1.2193e-18 1.5025e-19 1.7392e-20 1.8913e-21 1.9321e-22 1.8542e-23 1.6716e-24 1.4157e-25 1.1263e-26 8.4181e-28 5.9104e-29 3.8984e-30 2.4155e-31 1.406e-32 7.6879e-34 3.9491e-35 1.9056e-36 8.6386e-38 3.6787e-39 1.4717e-40 5.5308e-42 1.9526e-43 6.4759e-45 2.0176e-46 5.9052e-48 1.6236e-49 4.1937e-51 1.0176e-52 +8.1399e-53 3.3547e-51 1.2988e-49 4.7237e-48 1.6139e-46 5.1802e-45 1.5619e-43 4.4242e-42 1.1772e-40 2.9427e-39 6.9102e-38 1.5244e-36 3.159e-35 6.1497e-34 1.1247e-32 1.9322e-31 3.1184e-30 4.7279e-29 6.7339e-28 9.0098e-27 1.1325e-25 1.3372e-24 1.4832e-23 1.5456e-22 1.5129e-21 1.3913e-20 1.2019e-19 9.7536e-19 7.4357e-18 5.3253e-17 3.5827e-16 2.2644e-15 1.3444e-14 7.4985e-14 3.9289e-13 1.9339e-12 8.9422e-12 3.8843e-11 1.585e-10 6.0761e-10 2.1881e-09 7.4022e-09 2.3524e-08 7.023e-08 1.9697e-07 5.1894e-07 1.2844e-06 2.9863e-06 6.5226e-06 1.3384e-05 2.5797e-05 4.6713e-05 7.9462e-05 0.00012698 0.00019062 0.00026882 0.00035612 0.0004432 0.00051816 0.00056908 0.00058715 0.00056908 0.00051816 0.0004432 0.00035612 0.00026882 0.00019062 0.00012698 7.9462e-05 4.6713e-05 2.5797e-05 1.3384e-05 6.5226e-06 2.9863e-06 1.2844e-06 5.1894e-07 1.9697e-07 7.023e-08 2.3524e-08 7.4022e-09 2.1881e-09 6.0761e-10 1.585e-10 3.8843e-11 8.9422e-12 1.9339e-12 3.9289e-13 7.4985e-14 1.3444e-14 2.2644e-15 3.5827e-16 5.3253e-17 7.4357e-18 9.7536e-19 1.2019e-19 1.3913e-20 1.5129e-21 1.5456e-22 1.4832e-23 1.3372e-24 1.1325e-25 9.0098e-27 6.7339e-28 4.7279e-29 3.1184e-30 1.9322e-31 1.1247e-32 6.1497e-34 3.159e-35 1.5244e-36 6.9102e-38 2.9427e-39 1.1772e-40 4.4242e-42 1.5619e-43 5.1802e-45 1.6139e-46 4.7237e-48 1.2988e-49 3.3547e-51 8.1399e-53 +6.4937e-53 2.6762e-51 1.0361e-49 3.7684e-48 1.2875e-46 4.1326e-45 1.246e-43 3.5295e-42 9.3915e-41 2.3476e-39 5.5127e-38 1.2161e-36 2.5201e-35 4.906e-34 8.9722e-33 1.5414e-31 2.4877e-30 3.7717e-29 5.372e-28 7.1877e-27 9.0343e-26 1.0667e-24 1.1833e-23 1.233e-22 1.207e-21 1.1099e-20 9.5881e-20 7.781e-19 5.9319e-18 4.2483e-17 2.8582e-16 1.8064e-15 1.0725e-14 5.982e-14 3.1344e-13 1.5428e-12 7.1338e-12 3.0988e-11 1.2645e-10 4.8473e-10 1.7456e-09 5.9052e-09 1.8767e-08 5.6027e-08 1.5713e-07 4.1399e-07 1.0246e-06 2.3823e-06 5.2035e-06 1.0677e-05 2.058e-05 3.7266e-05 6.3392e-05 0.0001013 0.00015207 0.00021445 0.0002841 0.00035357 0.00041336 0.00045399 0.0004684 0.00045399 0.00041336 0.00035357 0.0002841 0.00021445 0.00015207 0.0001013 6.3392e-05 3.7266e-05 2.058e-05 1.0677e-05 5.2035e-06 2.3823e-06 1.0246e-06 4.1399e-07 1.5713e-07 5.6027e-08 1.8767e-08 5.9052e-09 1.7456e-09 4.8473e-10 1.2645e-10 3.0988e-11 7.1338e-12 1.5428e-12 3.1344e-13 5.982e-14 1.0725e-14 1.8064e-15 2.8582e-16 4.2483e-17 5.9319e-18 7.781e-19 9.5881e-20 1.1099e-20 1.207e-21 1.233e-22 1.1833e-23 1.0667e-24 9.0343e-26 7.1877e-27 5.372e-28 3.7717e-29 2.4877e-30 1.5414e-31 8.9722e-33 4.906e-34 2.5201e-35 1.2161e-36 5.5127e-38 2.3476e-39 9.3915e-41 3.5295e-42 1.246e-43 4.1326e-45 1.2875e-46 3.7684e-48 1.0361e-49 2.6762e-51 6.4937e-53 +5.1664e-53 2.1292e-51 8.2435e-50 2.9982e-48 1.0244e-46 3.2879e-45 9.9137e-44 2.8081e-42 7.472e-41 1.8678e-39 4.3859e-38 9.6752e-37 2.005e-35 3.9033e-34 7.1383e-33 1.2264e-31 1.9793e-30 3.0008e-29 4.274e-28 5.7186e-27 7.1878e-26 8.4871e-25 9.4141e-24 9.8098e-23 9.6027e-22 8.8305e-21 7.6284e-20 6.1906e-19 4.7195e-18 3.38e-17 2.274e-16 1.4372e-15 8.533e-15 4.7594e-14 2.4937e-13 1.2275e-12 5.6757e-12 2.4654e-11 1.006e-10 3.8565e-10 1.3888e-09 4.6982e-09 1.4931e-08 4.4576e-08 1.2502e-07 3.2937e-07 8.152e-07 1.8954e-06 4.1399e-06 8.4946e-06 1.6374e-05 2.9649e-05 5.0435e-05 8.0595e-05 0.00012099 0.00017062 0.00022603 0.0002813 0.00032888 0.0003612 0.00037267 0.0003612 0.00032888 0.0002813 0.00022603 0.00017062 0.00012099 8.0595e-05 5.0435e-05 2.9649e-05 1.6374e-05 8.4946e-06 4.1399e-06 1.8954e-06 8.152e-07 3.2937e-07 1.2502e-07 4.4576e-08 1.4931e-08 4.6982e-09 1.3888e-09 3.8565e-10 1.006e-10 2.4654e-11 5.6757e-12 1.2275e-12 2.4937e-13 4.7594e-14 8.533e-15 1.4372e-15 2.274e-16 3.38e-17 4.7195e-18 6.1906e-19 7.6284e-20 8.8305e-21 9.6027e-22 9.8098e-23 9.4141e-24 8.4871e-25 7.1878e-26 5.7186e-27 4.274e-28 3.0008e-29 1.9793e-30 1.2264e-31 7.1383e-33 3.9033e-34 2.005e-35 9.6752e-37 4.3859e-38 1.8678e-39 7.472e-41 2.8081e-42 9.9137e-44 3.2879e-45 1.0244e-46 2.9982e-48 8.2435e-50 2.1292e-51 5.1664e-53 +4.0994e-53 1.6895e-51 6.5409e-50 2.3789e-48 8.128e-47 2.6088e-45 7.8661e-44 2.2281e-42 5.9287e-41 1.482e-39 3.4801e-38 7.6769e-37 1.5909e-35 3.0971e-34 5.664e-33 9.7308e-32 1.5705e-30 2.381e-29 3.3913e-28 4.5375e-27 5.7032e-26 6.7342e-25 7.4698e-24 7.7837e-23 7.6194e-22 7.0066e-21 6.0528e-20 4.912e-19 3.7447e-18 2.6819e-17 1.8043e-16 1.1404e-15 6.7707e-15 3.7764e-14 1.9787e-13 9.7394e-13 4.5034e-12 1.9562e-11 7.9825e-11 3.06e-10 1.102e-09 3.7279e-09 1.1847e-08 3.5369e-08 9.9195e-08 2.6134e-07 6.4683e-07 1.5039e-06 3.2849e-06 6.7401e-06 1.2992e-05 2.3525e-05 4.0018e-05 6.3949e-05 9.5998e-05 0.00013538 0.00017935 0.0002232 0.00026095 0.0002866 0.0002957 0.0002866 0.00026095 0.0002232 0.00017935 0.00013538 9.5998e-05 6.3949e-05 4.0018e-05 2.3525e-05 1.2992e-05 6.7401e-06 3.2849e-06 1.5039e-06 6.4683e-07 2.6134e-07 9.9195e-08 3.5369e-08 1.1847e-08 3.7279e-09 1.102e-09 3.06e-10 7.9825e-11 1.9562e-11 4.5034e-12 9.7394e-13 1.9787e-13 3.7764e-14 6.7707e-15 1.1404e-15 1.8043e-16 2.6819e-17 3.7447e-18 4.912e-19 6.0528e-20 7.0066e-21 7.6194e-22 7.7837e-23 7.4698e-24 6.7342e-25 5.7032e-26 4.5375e-27 3.3913e-28 2.381e-29 1.5705e-30 9.7308e-32 5.664e-33 3.0971e-34 1.5909e-35 7.6769e-37 3.4801e-38 1.482e-39 5.9287e-41 2.2281e-42 7.8661e-44 2.6088e-45 8.128e-47 2.3789e-48 6.5409e-50 1.6895e-51 4.0994e-53 +3.2439e-53 1.3369e-51 5.176e-50 1.8825e-48 6.4319e-47 2.0644e-45 6.2247e-44 1.7631e-42 4.6916e-41 1.1727e-39 2.7539e-38 6.075e-37 1.2589e-35 2.4508e-34 4.4821e-33 7.7002e-32 1.2428e-30 1.8842e-29 2.6836e-28 3.5906e-27 4.5131e-26 5.3289e-25 5.911e-24 6.1594e-23 6.0294e-22 5.5445e-21 4.7897e-20 3.887e-19 2.9633e-18 2.1222e-17 1.4278e-16 9.024e-16 5.3578e-15 2.9883e-14 1.5658e-13 7.707e-13 3.5637e-12 1.548e-11 6.3168e-11 2.4215e-10 8.7201e-10 2.95e-09 9.375e-09 2.7988e-08 7.8495e-08 2.0681e-07 5.1185e-07 1.1901e-06 2.5994e-06 5.3337e-06 1.0281e-05 1.8616e-05 3.1667e-05 5.0604e-05 7.5966e-05 0.00010713 0.00014192 0.00017663 0.0002065 0.00022679 0.00023399 0.00022679 0.0002065 0.00017663 0.00014192 0.00010713 7.5966e-05 5.0604e-05 3.1667e-05 1.8616e-05 1.0281e-05 5.3337e-06 2.5994e-06 1.1901e-06 5.1185e-07 2.0681e-07 7.8495e-08 2.7988e-08 9.375e-09 2.95e-09 8.7201e-10 2.4215e-10 6.3168e-11 1.548e-11 3.5637e-12 7.707e-13 1.5658e-13 2.9883e-14 5.3578e-15 9.024e-16 1.4278e-16 2.1222e-17 2.9633e-18 3.887e-19 4.7897e-20 5.5445e-21 6.0294e-22 6.1594e-23 5.911e-24 5.3289e-25 4.5131e-26 3.5906e-27 2.6836e-28 1.8842e-29 1.2428e-30 7.7002e-32 4.4821e-33 2.4508e-34 1.2589e-35 6.075e-37 2.7539e-38 1.1727e-39 4.6916e-41 1.7631e-42 6.2247e-44 2.0644e-45 6.4319e-47 1.8825e-48 5.176e-50 1.3369e-51 3.2439e-53 +2.5601e-53 1.0551e-51 4.0849e-50 1.4857e-48 5.0761e-47 1.6292e-45 4.9125e-44 1.3915e-42 3.7026e-41 9.2553e-40 2.1734e-38 4.7943e-37 9.9354e-36 1.9342e-34 3.5372e-33 6.077e-32 9.8078e-31 1.487e-29 2.1179e-28 2.8337e-27 3.5617e-26 4.2056e-25 4.665e-24 4.861e-23 4.7584e-22 4.3757e-21 3.7801e-20 3.0676e-19 2.3386e-18 1.6749e-17 1.1268e-16 7.1217e-16 4.2284e-15 2.3584e-14 1.2357e-13 6.0824e-13 2.8125e-12 1.2217e-11 4.9852e-11 1.911e-10 6.8819e-10 2.3281e-09 7.3987e-09 2.2088e-08 6.1949e-08 1.6321e-07 4.0396e-07 9.3922e-07 2.0515e-06 4.2093e-06 8.1137e-06 1.4692e-05 2.4992e-05 3.9937e-05 5.9952e-05 8.4546e-05 0.00011201 0.00013939 0.00016297 0.00017898 0.00018467 0.00017898 0.00016297 0.00013939 0.00011201 8.4546e-05 5.9952e-05 3.9937e-05 2.4992e-05 1.4692e-05 8.1137e-06 4.2093e-06 2.0515e-06 9.3922e-07 4.0396e-07 1.6321e-07 6.1949e-08 2.2088e-08 7.3987e-09 2.3281e-09 6.8819e-10 1.911e-10 4.9852e-11 1.2217e-11 2.8125e-12 6.0824e-13 1.2357e-13 2.3584e-14 4.2284e-15 7.1217e-16 1.1268e-16 1.6749e-17 2.3386e-18 3.0676e-19 3.7801e-20 4.3757e-21 4.7584e-22 4.861e-23 4.665e-24 4.2056e-25 3.5617e-26 2.8337e-27 2.1179e-28 1.487e-29 9.8078e-31 6.077e-32 3.5372e-33 1.9342e-34 9.9354e-36 4.7943e-37 2.1734e-38 9.2553e-40 3.7026e-41 1.3915e-42 4.9125e-44 1.6292e-45 5.0761e-47 1.4857e-48 4.0849e-50 1.0551e-51 2.5601e-53 +2.015e-53 8.3044e-52 3.2151e-50 1.1693e-48 3.9953e-47 1.2823e-45 3.8665e-44 1.0952e-42 2.9142e-41 7.2846e-40 1.7106e-38 3.7735e-37 7.8199e-36 1.5223e-34 2.7841e-33 4.7831e-32 7.7195e-31 1.1704e-29 1.6669e-28 2.2304e-27 2.8034e-26 3.3101e-25 3.6717e-24 3.826e-23 3.7452e-22 3.4441e-21 2.9752e-20 2.4145e-19 1.8407e-18 1.3183e-17 8.869e-17 5.6054e-16 3.3281e-15 1.8562e-14 9.726e-14 4.7873e-13 2.2136e-12 9.6156e-12 3.9237e-11 1.5041e-10 5.4166e-10 1.8324e-09 5.8234e-09 1.7385e-08 4.8758e-08 1.2846e-07 3.1794e-07 7.3924e-07 1.6147e-06 3.3131e-06 6.3861e-06 1.1564e-05 1.9671e-05 3.1433e-05 4.7187e-05 6.6545e-05 8.8157e-05 0.00010971 0.00012827 0.00014087 0.00014535 0.00014087 0.00012827 0.00010971 8.8157e-05 6.6545e-05 4.7187e-05 3.1433e-05 1.9671e-05 1.1564e-05 6.3861e-06 3.3131e-06 1.6147e-06 7.3924e-07 3.1794e-07 1.2846e-07 4.8758e-08 1.7385e-08 5.8234e-09 1.8324e-09 5.4166e-10 1.5041e-10 3.9237e-11 9.6156e-12 2.2136e-12 4.7873e-13 9.726e-14 1.8562e-14 3.3281e-15 5.6054e-16 8.869e-17 1.3183e-17 1.8407e-18 2.4145e-19 2.9752e-20 3.4441e-21 3.7452e-22 3.826e-23 3.6717e-24 3.3101e-25 2.8034e-26 2.2304e-27 1.6669e-28 1.1704e-29 7.7195e-31 4.7831e-32 2.7841e-33 1.5223e-34 7.8199e-36 3.7735e-37 1.7106e-38 7.2846e-40 2.9142e-41 1.0952e-42 3.8665e-44 1.2823e-45 3.9953e-47 1.1693e-48 3.2151e-50 8.3044e-52 2.015e-53 +1.5817e-53 6.5187e-52 2.5238e-50 9.179e-49 3.1362e-47 1.0066e-45 3.0351e-44 8.597e-43 2.2876e-41 5.7182e-40 1.3428e-38 2.9621e-37 6.1384e-36 1.195e-34 2.1854e-33 3.7546e-32 6.0596e-31 9.1871e-30 1.3085e-28 1.7508e-27 2.2006e-26 2.5984e-25 2.8822e-24 3.0033e-23 2.9399e-22 2.7035e-21 2.3354e-20 1.8953e-19 1.4449e-18 1.0348e-17 6.9619e-17 4.4e-16 2.6124e-15 1.4571e-14 7.6346e-14 3.7579e-13 1.7376e-12 7.5479e-12 3.08e-11 1.1807e-10 4.2518e-10 1.4384e-09 4.5712e-09 1.3647e-08 3.8274e-08 1.0084e-07 2.4958e-07 5.8028e-07 1.2675e-06 2.6006e-06 5.0129e-06 9.0772e-06 1.5441e-05 2.4674e-05 3.704e-05 5.2235e-05 6.9201e-05 8.6122e-05 0.00010069 0.00011058 0.00011409 0.00011058 0.00010069 8.6122e-05 6.9201e-05 5.2235e-05 3.704e-05 2.4674e-05 1.5441e-05 9.0772e-06 5.0129e-06 2.6006e-06 1.2675e-06 5.8028e-07 2.4958e-07 1.0084e-07 3.8274e-08 1.3647e-08 4.5712e-09 1.4384e-09 4.2518e-10 1.1807e-10 3.08e-11 7.5479e-12 1.7376e-12 3.7579e-13 7.6346e-14 1.4571e-14 2.6124e-15 4.4e-16 6.9619e-17 1.0348e-17 1.4449e-18 1.8953e-19 2.3354e-20 2.7035e-21 2.9399e-22 3.0033e-23 2.8822e-24 2.5984e-25 2.2006e-26 1.7508e-27 1.3085e-28 9.1871e-30 6.0596e-31 3.7546e-32 2.1854e-33 1.195e-34 6.1384e-36 2.9621e-37 1.3428e-38 5.7182e-40 2.2876e-41 8.597e-43 3.0351e-44 1.0066e-45 3.1362e-47 9.179e-49 2.5238e-50 6.5187e-52 1.5817e-53 +1.2383e-53 5.1033e-52 1.9758e-50 7.1859e-49 2.4552e-47 7.8803e-46 2.3761e-44 6.7303e-43 1.7909e-41 4.4766e-40 1.0512e-38 2.3189e-37 4.8055e-36 9.3552e-35 1.7109e-33 2.9393e-32 4.7438e-31 7.1923e-30 1.0244e-28 1.3706e-27 1.7227e-26 2.0342e-25 2.2564e-24 2.3512e-23 2.3015e-22 2.1165e-21 1.8283e-20 1.4838e-19 1.1312e-18 8.101e-18 5.4502e-17 3.4446e-16 2.0452e-15 1.1407e-14 5.9769e-14 2.9419e-13 1.3603e-12 5.909e-12 2.4112e-11 9.2433e-11 3.3286e-10 1.1261e-09 3.5786e-09 1.0684e-08 2.9963e-08 7.8943e-08 1.9539e-07 4.5428e-07 9.9225e-07 2.036e-06 3.9244e-06 7.1062e-06 1.2088e-05 1.9317e-05 2.8998e-05 4.0893e-05 5.4175e-05 6.7422e-05 7.8824e-05 8.6571e-05 8.9319e-05 8.6571e-05 7.8824e-05 6.7422e-05 5.4175e-05 4.0893e-05 2.8998e-05 1.9317e-05 1.2088e-05 7.1062e-06 3.9244e-06 2.036e-06 9.9225e-07 4.5428e-07 1.9539e-07 7.8943e-08 2.9963e-08 1.0684e-08 3.5786e-09 1.1261e-09 3.3286e-10 9.2433e-11 2.4112e-11 5.909e-12 1.3603e-12 2.9419e-13 5.9769e-14 1.1407e-14 2.0452e-15 3.4446e-16 5.4502e-17 8.101e-18 1.1312e-18 1.4838e-19 1.8283e-20 2.1165e-21 2.3015e-22 2.3512e-23 2.2564e-24 2.0342e-25 1.7227e-26 1.3706e-27 1.0244e-28 7.1923e-30 4.7438e-31 2.9393e-32 1.7109e-33 9.3552e-35 4.8055e-36 2.3189e-37 1.0512e-38 4.4766e-40 1.7909e-41 6.7303e-43 2.3761e-44 7.8803e-46 2.4552e-47 7.1859e-49 1.9758e-50 5.1033e-52 1.2383e-53 +9.6681e-54 3.9845e-52 1.5426e-50 5.6106e-49 1.917e-47 6.1528e-46 1.8552e-44 5.2548e-43 1.3983e-41 3.4952e-40 8.2076e-39 1.8106e-37 3.752e-36 7.3043e-35 1.3358e-33 2.2949e-32 3.7039e-31 5.6156e-30 7.9981e-29 1.0701e-27 1.3451e-26 1.5882e-25 1.7617e-24 1.8357e-23 1.797e-22 1.6525e-21 1.4275e-20 1.1585e-19 8.8318e-19 6.3251e-18 4.2554e-17 2.6895e-16 1.5968e-15 8.9063e-15 4.6666e-14 2.297e-13 1.0621e-12 4.6136e-12 1.8826e-11 7.2169e-11 2.5989e-10 8.792e-10 2.7941e-09 8.3416e-09 2.3395e-08 6.1636e-08 1.5255e-07 3.5469e-07 7.7472e-07 1.5896e-06 3.0641e-06 5.5483e-06 9.438e-06 1.5082e-05 2.2641e-05 3.1928e-05 4.2298e-05 5.2641e-05 6.1544e-05 6.7593e-05 6.9738e-05 6.7593e-05 6.1544e-05 5.2641e-05 4.2298e-05 3.1928e-05 2.2641e-05 1.5082e-05 9.438e-06 5.5483e-06 3.0641e-06 1.5896e-06 7.7472e-07 3.5469e-07 1.5255e-07 6.1636e-08 2.3395e-08 8.3416e-09 2.7941e-09 8.792e-10 2.5989e-10 7.2169e-11 1.8826e-11 4.6136e-12 1.0621e-12 2.297e-13 4.6666e-14 8.9063e-15 1.5968e-15 2.6895e-16 4.2554e-17 6.3251e-18 8.8318e-19 1.1585e-19 1.4275e-20 1.6525e-21 1.797e-22 1.8357e-23 1.7617e-24 1.5882e-25 1.3451e-26 1.0701e-27 7.9981e-29 5.6156e-30 3.7039e-31 2.2949e-32 1.3358e-33 7.3043e-35 3.752e-36 1.8106e-37 8.2076e-39 3.4952e-40 1.3983e-41 5.2548e-43 1.8552e-44 6.1528e-46 1.917e-47 5.6106e-49 1.5426e-50 3.9845e-52 9.6681e-54 +7.5284e-54 3.1027e-52 1.2012e-50 4.3689e-49 1.4927e-47 4.7911e-46 1.4446e-44 4.0919e-43 1.0888e-41 2.7217e-40 6.3911e-39 1.4099e-37 2.9217e-36 5.6878e-35 1.0402e-33 1.787e-32 2.8841e-31 4.3728e-30 6.228e-29 8.333e-28 1.0474e-26 1.2367e-25 1.3718e-24 1.4295e-23 1.3993e-22 1.2868e-21 1.1116e-20 9.0209e-20 6.8772e-19 4.9252e-18 3.3136e-17 2.0943e-16 1.2434e-15 6.9353e-15 3.6338e-14 1.7886e-13 8.2705e-13 3.5926e-12 1.466e-11 5.6197e-11 2.0237e-10 6.8462e-10 2.1757e-09 6.4955e-09 1.8217e-08 4.7996e-08 1.1879e-07 2.762e-07 6.0327e-07 1.2378e-06 2.386e-06 4.3204e-06 7.3493e-06 1.1744e-05 1.763e-05 2.4862e-05 3.2937e-05 4.0991e-05 4.7923e-05 5.2634e-05 5.4304e-05 5.2634e-05 4.7923e-05 4.0991e-05 3.2937e-05 2.4862e-05 1.763e-05 1.1744e-05 7.3493e-06 4.3204e-06 2.386e-06 1.2378e-06 6.0327e-07 2.762e-07 1.1879e-07 4.7996e-08 1.8217e-08 6.4955e-09 2.1757e-09 6.8462e-10 2.0237e-10 5.6197e-11 1.466e-11 3.5926e-12 8.2705e-13 1.7886e-13 3.6338e-14 6.9353e-15 1.2434e-15 2.0943e-16 3.3136e-17 4.9252e-18 6.8772e-19 9.0209e-20 1.1116e-20 1.2868e-21 1.3993e-22 1.4295e-23 1.3718e-24 1.2367e-25 1.0474e-26 8.333e-28 6.228e-29 4.3728e-30 2.8841e-31 1.787e-32 1.0402e-33 5.6878e-35 2.9217e-36 1.4099e-37 6.3911e-39 2.7217e-40 1.0888e-41 4.0919e-43 1.4446e-44 4.7911e-46 1.4927e-47 4.3689e-49 1.2012e-50 3.1027e-52 7.5284e-54 +5.8467e-54 2.4096e-52 9.3289e-51 3.3929e-49 1.1593e-47 3.7208e-46 1.1219e-44 3.1778e-43 8.4558e-42 2.1137e-40 4.9634e-39 1.0949e-37 2.269e-36 4.4172e-35 8.0782e-34 1.3878e-32 2.2399e-31 3.3959e-30 4.8368e-29 6.4715e-28 8.1342e-27 9.6046e-26 1.0654e-24 1.1101e-23 1.0867e-22 9.9931e-22 8.6327e-21 7.0057e-20 5.3409e-19 3.825e-18 2.5734e-17 1.6264e-16 9.6566e-16 5.386e-15 2.8221e-14 1.3891e-13 6.423e-13 2.79e-12 1.1385e-11 4.3643e-11 1.5717e-10 5.3168e-10 1.6897e-09 5.0445e-09 1.4148e-08 3.7274e-08 9.2254e-08 2.145e-07 4.685e-07 9.613e-07 1.853e-06 3.3553e-06 5.7075e-06 9.1206e-06 1.3692e-05 1.9308e-05 2.5579e-05 3.1834e-05 3.7218e-05 4.0876e-05 4.2173e-05 4.0876e-05 3.7218e-05 3.1834e-05 2.5579e-05 1.9308e-05 1.3692e-05 9.1206e-06 5.7075e-06 3.3553e-06 1.853e-06 9.613e-07 4.685e-07 2.145e-07 9.2254e-08 3.7274e-08 1.4148e-08 5.0445e-09 1.6897e-09 5.3168e-10 1.5717e-10 4.3643e-11 1.1385e-11 2.79e-12 6.423e-13 1.3891e-13 2.8221e-14 5.386e-15 9.6566e-16 1.6264e-16 2.5734e-17 3.825e-18 5.3409e-19 7.0057e-20 8.6327e-21 9.9931e-22 1.0867e-22 1.1101e-23 1.0654e-24 9.6046e-26 8.1342e-27 6.4715e-28 4.8368e-29 3.3959e-30 2.2399e-31 1.3878e-32 8.0782e-34 4.4172e-35 2.269e-36 1.0949e-37 4.9634e-39 2.1137e-40 8.4558e-42 3.1778e-43 1.1219e-44 3.7208e-46 1.1593e-47 3.3929e-49 9.3289e-51 2.4096e-52 5.8467e-54 +4.5285e-54 1.8663e-52 7.2256e-51 2.628e-49 8.9789e-48 2.8819e-46 8.6895e-45 2.4613e-43 6.5493e-42 1.6371e-40 3.8444e-39 8.4805e-38 1.7574e-36 3.4213e-35 6.2569e-34 1.0749e-32 1.7349e-31 2.6303e-30 3.7463e-29 5.0124e-28 6.3002e-27 7.4391e-26 8.2517e-25 8.5985e-24 8.417e-23 7.7401e-22 6.6864e-21 5.4262e-20 4.1367e-19 2.9626e-18 1.9932e-17 1.2597e-16 7.4794e-16 4.1717e-15 2.1858e-14 1.0759e-13 4.9749e-13 2.161e-12 8.8181e-12 3.3803e-11 1.2173e-10 4.1181e-10 1.3087e-09 3.9071e-09 1.0958e-08 2.887e-08 7.1454e-08 1.6614e-07 3.6287e-07 7.4457e-07 1.4352e-06 2.5988e-06 4.4207e-06 7.0643e-06 1.0605e-05 1.4955e-05 1.9812e-05 2.4657e-05 2.8827e-05 3.166e-05 3.2665e-05 3.166e-05 2.8827e-05 2.4657e-05 1.9812e-05 1.4955e-05 1.0605e-05 7.0643e-06 4.4207e-06 2.5988e-06 1.4352e-06 7.4457e-07 3.6287e-07 1.6614e-07 7.1454e-08 2.887e-08 1.0958e-08 3.9071e-09 1.3087e-09 4.1181e-10 1.2173e-10 3.3803e-11 8.8181e-12 2.161e-12 4.9749e-13 1.0759e-13 2.1858e-14 4.1717e-15 7.4794e-16 1.2597e-16 1.9932e-17 2.9626e-18 4.1367e-19 5.4262e-20 6.6864e-21 7.7401e-22 8.417e-23 8.5985e-24 8.2517e-25 7.4391e-26 6.3002e-27 5.0124e-28 3.7463e-29 2.6303e-30 1.7349e-31 1.0749e-32 6.2569e-34 3.4213e-35 1.7574e-36 8.4805e-38 3.8444e-39 1.6371e-40 6.5493e-42 2.4613e-43 8.6895e-45 2.8819e-46 8.9789e-48 2.628e-49 7.2256e-51 1.8663e-52 4.5285e-54 +3.4982e-54 1.4417e-52 5.5816e-51 2.03e-49 6.936e-48 2.2262e-46 6.7125e-45 1.9013e-43 5.0592e-42 1.2646e-40 2.9697e-39 6.551e-38 1.3576e-36 2.6429e-35 4.8333e-34 8.3037e-33 1.3401e-31 2.0318e-30 2.8939e-29 3.872e-28 4.8668e-27 5.7466e-26 6.3743e-25 6.6421e-24 6.5019e-23 5.9791e-22 5.1651e-21 4.1916e-20 3.1955e-19 2.2886e-18 1.5397e-17 9.7312e-17 5.7777e-16 3.2225e-15 1.6885e-14 8.311e-14 3.843e-13 1.6693e-12 6.8118e-12 2.6112e-11 9.4034e-11 3.1811e-10 1.011e-09 3.0182e-09 8.4647e-09 2.2302e-08 5.5197e-08 1.2834e-07 2.8031e-07 5.7516e-07 1.1087e-06 2.0075e-06 3.4149e-06 5.457e-06 8.1919e-06 1.1552e-05 1.5305e-05 1.9047e-05 2.2268e-05 2.4457e-05 2.5233e-05 2.4457e-05 2.2268e-05 1.9047e-05 1.5305e-05 1.1552e-05 8.1919e-06 5.457e-06 3.4149e-06 2.0075e-06 1.1087e-06 5.7516e-07 2.8031e-07 1.2834e-07 5.5197e-08 2.2302e-08 8.4647e-09 3.0182e-09 1.011e-09 3.1811e-10 9.4034e-11 2.6112e-11 6.8118e-12 1.6693e-12 3.843e-13 8.311e-14 1.6885e-14 3.2225e-15 5.7777e-16 9.7312e-17 1.5397e-17 2.2886e-18 3.1955e-19 4.1916e-20 5.1651e-21 5.9791e-22 6.5019e-23 6.6421e-24 6.3743e-25 5.7466e-26 4.8668e-27 3.872e-28 2.8939e-29 2.0318e-30 1.3401e-31 8.3037e-33 4.8333e-34 2.6429e-35 1.3576e-36 6.551e-38 2.9697e-39 1.2646e-40 5.0592e-42 1.9013e-43 6.7125e-45 2.2262e-46 6.936e-48 2.03e-49 5.5816e-51 1.4417e-52 3.4982e-54 +2.6951e-54 1.1107e-52 4.3002e-51 1.564e-49 5.3437e-48 1.7151e-46 5.1715e-45 1.4648e-43 3.8978e-42 9.7432e-41 2.2879e-39 5.0471e-38 1.0459e-36 2.0361e-35 3.7237e-34 6.3974e-33 1.0325e-31 1.5654e-30 2.2295e-29 2.9831e-28 3.7495e-27 4.4273e-26 4.9109e-25 5.1173e-24 5.0092e-23 4.6064e-22 3.9793e-21 3.2293e-20 2.4619e-19 1.7632e-18 1.1862e-17 7.4972e-17 4.4513e-16 2.4827e-15 1.3009e-14 6.403e-14 2.9607e-13 1.2861e-12 5.248e-12 2.0118e-11 7.2447e-11 2.4508e-10 7.7887e-10 2.3253e-09 6.5214e-09 1.7182e-08 4.2525e-08 9.8874e-08 2.1596e-07 4.4312e-07 8.5414e-07 1.5466e-06 2.6309e-06 4.2042e-06 6.3113e-06 8.9003e-06 1.1791e-05 1.4674e-05 1.7156e-05 1.8842e-05 1.944e-05 1.8842e-05 1.7156e-05 1.4674e-05 1.1791e-05 8.9003e-06 6.3113e-06 4.2042e-06 2.6309e-06 1.5466e-06 8.5414e-07 4.4312e-07 2.1596e-07 9.8874e-08 4.2525e-08 1.7182e-08 6.5214e-09 2.3253e-09 7.7887e-10 2.4508e-10 7.2447e-11 2.0118e-11 5.248e-12 1.2861e-12 2.9607e-13 6.403e-14 1.3009e-14 2.4827e-15 4.4513e-16 7.4972e-17 1.1862e-17 1.7632e-18 2.4619e-19 3.2293e-20 3.9793e-21 4.6064e-22 5.0092e-23 5.1173e-24 4.9109e-25 4.4273e-26 3.7495e-27 2.9831e-28 2.2295e-29 1.5654e-30 1.0325e-31 6.3974e-33 3.7237e-34 2.0361e-35 1.0459e-36 5.0471e-38 2.2879e-39 9.7432e-41 3.8978e-42 1.4648e-43 5.1715e-45 1.7151e-46 5.3437e-48 1.564e-49 4.3002e-51 1.1107e-52 2.6951e-54 +2.0708e-54 8.5345e-53 3.3042e-51 1.2017e-49 4.106e-48 1.3179e-46 3.9736e-45 1.1255e-43 2.995e-42 7.4864e-41 1.758e-39 3.8781e-38 8.0366e-37 1.5645e-35 2.8612e-34 4.9156e-33 7.9334e-32 1.2028e-30 1.7131e-29 2.2921e-28 2.881e-27 3.4018e-26 3.7734e-25 3.932e-24 3.849e-23 3.5395e-22 3.0576e-21 2.4814e-20 1.8917e-19 1.3548e-18 9.1147e-18 5.7607e-17 3.4203e-16 1.9077e-15 9.9955e-15 4.9199e-14 2.275e-13 9.882e-13 4.0325e-12 1.5458e-11 5.5666e-11 1.8832e-10 5.9847e-10 1.7867e-09 5.0109e-09 1.3202e-08 3.2675e-08 7.5972e-08 1.6594e-07 3.4049e-07 6.563e-07 1.1884e-06 2.0216e-06 3.2304e-06 4.8495e-06 6.8388e-06 9.06e-06 1.1275e-05 1.3182e-05 1.4478e-05 1.4937e-05 1.4478e-05 1.3182e-05 1.1275e-05 9.06e-06 6.8388e-06 4.8495e-06 3.2304e-06 2.0216e-06 1.1884e-06 6.563e-07 3.4049e-07 1.6594e-07 7.5972e-08 3.2675e-08 1.3202e-08 5.0109e-09 1.7867e-09 5.9847e-10 1.8832e-10 5.5666e-11 1.5458e-11 4.0325e-12 9.882e-13 2.275e-13 4.9199e-14 9.9955e-15 1.9077e-15 3.4203e-16 5.7607e-17 9.1147e-18 1.3548e-18 1.8917e-19 2.4814e-20 3.0576e-21 3.5395e-22 3.849e-23 3.932e-24 3.7734e-25 3.4018e-26 2.881e-27 2.2921e-28 1.7131e-29 1.2028e-30 7.9334e-32 4.9156e-33 2.8612e-34 1.5645e-35 8.0366e-37 3.8781e-38 1.758e-39 7.4864e-41 2.995e-42 1.1255e-43 3.9736e-45 1.3179e-46 4.106e-48 1.2017e-49 3.3042e-51 8.5345e-53 2.0708e-54 +1.587e-54 6.5403e-53 2.5321e-51 9.2095e-50 3.1466e-48 1.0099e-46 3.0452e-45 8.6255e-44 2.2952e-42 5.7372e-41 1.3472e-39 2.9719e-38 6.1588e-37 1.199e-35 2.1927e-34 3.767e-33 6.0797e-32 9.2176e-31 1.3128e-29 1.7566e-28 2.2079e-27 2.607e-26 2.8917e-25 3.0132e-24 2.9496e-23 2.7124e-22 2.3432e-21 1.9016e-20 1.4497e-19 1.0382e-18 6.985e-18 4.4146e-17 2.6211e-16 1.4619e-15 7.6599e-15 3.7704e-14 1.7434e-13 7.573e-13 3.0902e-12 1.1846e-11 4.2659e-11 1.4431e-10 4.5863e-10 1.3692e-09 3.8401e-09 1.0117e-08 2.504e-08 5.8221e-08 1.2717e-07 2.6093e-07 5.0295e-07 9.1073e-07 1.5492e-06 2.4756e-06 3.7163e-06 5.2409e-06 6.943e-06 8.6407e-06 1.0102e-05 1.1095e-05 1.1447e-05 1.1095e-05 1.0102e-05 8.6407e-06 6.943e-06 5.2409e-06 3.7163e-06 2.4756e-06 1.5492e-06 9.1073e-07 5.0295e-07 2.6093e-07 1.2717e-07 5.8221e-08 2.504e-08 1.0117e-08 3.8401e-09 1.3692e-09 4.5863e-10 1.4431e-10 4.2659e-11 1.1846e-11 3.0902e-12 7.573e-13 1.7434e-13 3.7704e-14 7.6599e-15 1.4619e-15 2.6211e-16 4.4146e-17 6.985e-18 1.0382e-18 1.4497e-19 1.9016e-20 2.3432e-21 2.7124e-22 2.9496e-23 3.0132e-24 2.8917e-25 2.607e-26 2.2079e-27 1.7566e-28 1.3128e-29 9.2176e-31 6.0797e-32 3.767e-33 2.1927e-34 1.199e-35 6.1588e-37 2.9719e-38 1.3472e-39 5.7372e-41 2.2952e-42 8.6255e-44 3.0452e-45 1.0099e-46 3.1466e-48 9.2095e-50 2.5321e-51 6.5403e-53 1.587e-54 +1.2129e-54 4.9988e-53 1.9353e-51 7.0389e-50 2.4049e-48 7.7191e-47 2.3275e-45 6.5925e-44 1.7542e-42 4.385e-41 1.0297e-39 2.2715e-38 4.7072e-37 9.1638e-36 1.6759e-34 2.8792e-33 4.6467e-32 7.0451e-31 1.0034e-29 1.3426e-28 1.6875e-27 1.9925e-26 2.2102e-25 2.3031e-24 2.2544e-23 2.0731e-22 1.7909e-21 1.4534e-20 1.108e-19 7.9352e-19 5.3387e-18 3.3741e-17 2.0033e-16 1.1174e-15 5.8546e-15 2.8817e-14 1.3325e-13 5.7881e-13 2.3619e-12 9.0541e-12 3.2605e-11 1.103e-10 3.5054e-10 1.0465e-09 2.935e-09 7.7327e-09 1.9139e-08 4.4499e-08 9.7194e-08 1.9943e-07 3.8441e-07 6.9608e-07 1.1841e-06 1.8921e-06 2.8404e-06 4.0056e-06 5.3066e-06 6.6042e-06 7.7211e-06 8.48e-06 8.7491e-06 8.48e-06 7.7211e-06 6.6042e-06 5.3066e-06 4.0056e-06 2.8404e-06 1.8921e-06 1.1841e-06 6.9608e-07 3.8441e-07 1.9943e-07 9.7194e-08 4.4499e-08 1.9139e-08 7.7327e-09 2.935e-09 1.0465e-09 3.5054e-10 1.103e-10 3.2605e-11 9.0541e-12 2.3619e-12 5.7881e-13 1.3325e-13 2.8817e-14 5.8546e-15 1.1174e-15 2.0033e-16 3.3741e-17 5.3387e-18 7.9352e-19 1.108e-19 1.4534e-20 1.7909e-21 2.0731e-22 2.2544e-23 2.3031e-24 2.2102e-25 1.9925e-26 1.6875e-27 1.3426e-28 1.0034e-29 7.0451e-31 4.6467e-32 2.8792e-33 1.6759e-34 9.1638e-36 4.7072e-37 2.2715e-38 1.0297e-39 4.385e-41 1.7542e-42 6.5925e-44 2.3275e-45 7.7191e-47 2.4049e-48 7.0389e-50 1.9353e-51 4.9988e-53 1.2129e-54 +9.246e-55 3.8105e-53 1.4753e-51 5.3656e-50 1.8333e-48 5.8841e-47 1.7742e-45 5.0254e-44 1.3372e-42 3.3426e-41 7.8492e-40 1.7315e-38 3.5882e-37 6.9854e-36 1.2775e-34 2.1948e-33 3.5421e-32 5.3704e-31 7.6489e-30 1.0234e-28 1.2863e-27 1.5189e-26 1.6848e-25 1.7556e-24 1.7185e-23 1.5803e-22 1.3652e-21 1.1079e-20 8.4462e-20 6.0489e-19 4.0696e-18 2.5721e-17 1.5271e-16 8.5175e-16 4.4628e-15 2.1967e-14 1.0157e-13 4.4122e-13 1.8004e-12 6.9018e-12 2.4854e-11 8.4081e-11 2.6721e-10 7.9774e-10 2.2373e-09 5.8945e-09 1.4589e-08 3.3921e-08 7.409e-08 1.5202e-07 2.9303e-07 5.3061e-07 9.026e-07 1.4423e-06 2.1652e-06 3.0534e-06 4.0452e-06 5.0343e-06 5.8857e-06 6.4641e-06 6.6693e-06 6.4641e-06 5.8857e-06 5.0343e-06 4.0452e-06 3.0534e-06 2.1652e-06 1.4423e-06 9.026e-07 5.3061e-07 2.9303e-07 1.5202e-07 7.409e-08 3.3921e-08 1.4589e-08 5.8945e-09 2.2373e-09 7.9774e-10 2.6721e-10 8.4081e-11 2.4854e-11 6.9018e-12 1.8004e-12 4.4122e-13 1.0157e-13 2.1967e-14 4.4628e-15 8.5175e-16 1.5271e-16 2.5721e-17 4.0696e-18 6.0489e-19 8.4462e-20 1.1079e-20 1.3652e-21 1.5803e-22 1.7185e-23 1.7556e-24 1.6848e-25 1.5189e-26 1.2863e-27 1.0234e-28 7.6489e-30 5.3704e-31 3.5421e-32 2.1948e-33 1.2775e-34 6.9854e-36 3.5882e-37 1.7315e-38 7.8492e-40 3.3426e-41 1.3372e-42 5.0254e-44 1.7742e-45 5.8841e-47 1.8333e-48 5.3656e-50 1.4753e-51 3.8105e-53 9.246e-55 +7.0294e-55 2.897e-53 1.1216e-51 4.0793e-50 1.3938e-48 4.4735e-47 1.3489e-45 3.8207e-44 1.0166e-42 2.5413e-41 5.9675e-40 1.3164e-38 2.728e-37 5.3108e-36 9.7124e-35 1.6686e-33 2.693e-32 4.0829e-31 5.8152e-30 7.7807e-29 9.7797e-28 1.1548e-26 1.2809e-25 1.3347e-24 1.3065e-23 1.2015e-22 1.0379e-21 8.423e-21 6.4214e-20 4.5988e-19 3.094e-18 1.9555e-17 1.161e-16 6.4756e-16 3.393e-15 1.6701e-14 7.7224e-14 3.3544e-13 1.3688e-12 5.2472e-12 1.8896e-11 6.3924e-11 2.0315e-10 6.065e-10 1.701e-09 4.4814e-09 1.1092e-08 2.5789e-08 5.6328e-08 1.1558e-07 2.2278e-07 4.0341e-07 6.8622e-07 1.0966e-06 1.6461e-06 2.3214e-06 3.0754e-06 3.8274e-06 4.4747e-06 4.9145e-06 5.0705e-06 4.9145e-06 4.4747e-06 3.8274e-06 3.0754e-06 2.3214e-06 1.6461e-06 1.0966e-06 6.8622e-07 4.0341e-07 2.2278e-07 1.1558e-07 5.6328e-08 2.5789e-08 1.1092e-08 4.4814e-09 1.701e-09 6.065e-10 2.0315e-10 6.3924e-11 1.8896e-11 5.2472e-12 1.3688e-12 3.3544e-13 7.7224e-14 1.6701e-14 3.393e-15 6.4756e-16 1.161e-16 1.9555e-17 3.094e-18 4.5988e-19 6.4214e-20 8.423e-21 1.0379e-21 1.2015e-22 1.3065e-23 1.3347e-24 1.2809e-25 1.1548e-26 9.7797e-28 7.7807e-29 5.8152e-30 4.0829e-31 2.693e-32 1.6686e-33 9.7124e-35 5.3108e-36 2.728e-37 1.3164e-38 5.9675e-40 2.5413e-41 1.0166e-42 3.8207e-44 1.3489e-45 4.4735e-47 1.3938e-48 4.0793e-50 1.1216e-51 2.897e-53 7.0294e-55 +5.3301e-55 2.1967e-53 8.5047e-52 3.0932e-50 1.0568e-48 3.3921e-47 1.0228e-45 2.8971e-44 7.7088e-43 1.9269e-41 4.5249e-40 9.9818e-39 2.0685e-37 4.027e-36 7.3645e-35 1.2652e-33 2.042e-32 3.0959e-31 4.4095e-30 5.8998e-29 7.4156e-28 8.7561e-27 9.7125e-26 1.0121e-24 9.907e-24 9.1103e-23 7.8701e-22 6.3868e-21 4.8691e-20 3.4871e-19 2.346e-18 1.4827e-17 8.8035e-17 4.9102e-16 2.5728e-15 1.2664e-14 5.8556e-14 2.5435e-13 1.0379e-12 3.9788e-12 1.4328e-11 4.8471e-11 1.5404e-10 4.5988e-10 1.2898e-09 3.3981e-09 8.4104e-09 1.9555e-08 4.2711e-08 8.7638e-08 1.6893e-07 3.0589e-07 5.2033e-07 8.3149e-07 1.2482e-06 1.7603e-06 2.332e-06 2.9022e-06 3.393e-06 3.7265e-06 3.8448e-06 3.7265e-06 3.393e-06 2.9022e-06 2.332e-06 1.7603e-06 1.2482e-06 8.3149e-07 5.2033e-07 3.0589e-07 1.6893e-07 8.7638e-08 4.2711e-08 1.9555e-08 8.4104e-09 3.3981e-09 1.2898e-09 4.5988e-10 1.5404e-10 4.8471e-11 1.4328e-11 3.9788e-12 1.0379e-12 2.5435e-13 5.8556e-14 1.2664e-14 2.5728e-15 4.9102e-16 8.8035e-17 1.4827e-17 2.346e-18 3.4871e-19 4.8691e-20 6.3868e-21 7.8701e-22 9.1103e-23 9.907e-24 1.0121e-24 9.7125e-26 8.7561e-27 7.4156e-28 5.8998e-29 4.4095e-30 3.0959e-31 2.042e-32 1.2652e-33 7.3645e-35 4.027e-36 2.0685e-37 9.9818e-39 4.5249e-40 1.9269e-41 7.7088e-43 2.8971e-44 1.0228e-45 3.3921e-47 1.0568e-48 3.0932e-50 8.5047e-52 2.1967e-53 5.3301e-55 +4.031e-55 1.6613e-53 6.4318e-52 2.3393e-50 7.9924e-49 2.5653e-47 7.7349e-46 2.1909e-44 5.8298e-43 1.4573e-41 3.422e-40 7.5489e-39 1.5644e-37 3.0454e-36 5.5695e-35 9.5684e-34 1.5443e-32 2.3413e-31 3.3347e-30 4.4618e-29 5.6081e-28 6.6218e-27 7.3451e-26 7.6538e-25 7.4922e-24 6.8897e-23 5.9518e-22 4.8301e-21 3.6823e-20 2.6371e-19 1.7742e-18 1.1213e-17 6.6577e-17 3.7134e-16 1.9457e-15 9.5769e-15 4.4283e-14 1.9236e-13 7.8494e-13 3.009e-12 1.0836e-11 3.6657e-11 1.1649e-10 3.4779e-10 9.754e-10 2.5698e-09 6.3604e-09 1.4788e-08 3.2301e-08 6.6277e-08 1.2775e-07 2.3133e-07 3.935e-07 6.2882e-07 9.4397e-07 1.3312e-06 1.7636e-06 2.1948e-06 2.566e-06 2.8182e-06 2.9076e-06 2.8182e-06 2.566e-06 2.1948e-06 1.7636e-06 1.3312e-06 9.4397e-07 6.2882e-07 3.935e-07 2.3133e-07 1.2775e-07 6.6277e-08 3.2301e-08 1.4788e-08 6.3604e-09 2.5698e-09 9.754e-10 3.4779e-10 1.1649e-10 3.6657e-11 1.0836e-11 3.009e-12 7.8494e-13 1.9236e-13 4.4283e-14 9.5769e-15 1.9457e-15 3.7134e-16 6.6577e-17 1.1213e-17 1.7742e-18 2.6371e-19 3.6823e-20 4.8301e-21 5.9518e-22 6.8897e-23 7.4922e-24 7.6538e-25 7.3451e-26 6.6218e-27 5.6081e-28 4.4618e-29 3.3347e-30 2.3413e-31 1.5443e-32 9.5684e-34 5.5695e-35 3.0454e-36 1.5644e-37 7.5489e-39 3.422e-40 1.4573e-41 5.8298e-43 2.1909e-44 7.7349e-46 2.5653e-47 7.9924e-49 2.3393e-50 6.4318e-52 1.6613e-53 4.031e-55 +3.0404e-55 1.253e-53 4.8513e-52 1.7644e-50 6.0284e-49 1.9349e-47 5.8341e-46 1.6525e-44 4.3972e-43 1.0992e-41 2.5811e-40 5.6938e-39 1.1799e-37 2.2971e-36 4.2009e-35 7.2171e-34 1.1648e-32 1.766e-31 2.5152e-30 3.3653e-29 4.23e-28 4.9946e-27 5.5402e-26 5.773e-25 5.6511e-24 5.1967e-23 4.4892e-22 3.6432e-21 2.7774e-20 1.9891e-19 1.3382e-18 8.4578e-18 5.0217e-17 2.8009e-16 1.4675e-15 7.2235e-15 3.3401e-14 1.4509e-13 5.9205e-13 2.2696e-12 8.173e-12 2.7649e-11 8.7868e-11 2.6233e-10 7.3571e-10 1.9383e-09 4.7974e-09 1.1154e-08 2.4363e-08 4.999e-08 9.6359e-08 1.7448e-07 2.9681e-07 4.7429e-07 7.12e-07 1.0041e-06 1.3302e-06 1.6555e-06 1.9354e-06 2.1256e-06 2.1931e-06 2.1256e-06 1.9354e-06 1.6555e-06 1.3302e-06 1.0041e-06 7.12e-07 4.7429e-07 2.9681e-07 1.7448e-07 9.6359e-08 4.999e-08 2.4363e-08 1.1154e-08 4.7974e-09 1.9383e-09 7.3571e-10 2.6233e-10 8.7868e-11 2.7649e-11 8.173e-12 2.2696e-12 5.9205e-13 1.4509e-13 3.3401e-14 7.2235e-15 1.4675e-15 2.8009e-16 5.0217e-17 8.4578e-18 1.3382e-18 1.9891e-19 2.7774e-20 3.6432e-21 4.4892e-22 5.1967e-23 5.6511e-24 5.773e-25 5.5402e-26 4.9946e-27 4.23e-28 3.3653e-29 2.5152e-30 1.766e-31 1.1648e-32 7.2171e-34 4.2009e-35 2.2971e-36 1.1799e-37 5.6938e-39 2.5811e-40 1.0992e-41 4.3972e-43 1.6525e-44 5.8341e-46 1.9349e-47 6.0284e-49 1.7644e-50 4.8513e-52 1.253e-53 3.0404e-55 diff --git a/mcstas-comps/data/MCViNE/fcc_toy_atoms.dat b/mcstas-comps/data/MCViNE/fcc_toy_atoms.dat new file mode 100644 index 0000000000..73bd962451 --- /dev/null +++ b/mcstas-comps/data/MCViNE/fcc_toy_atoms.dat @@ -0,0 +1,2 @@ +# x y z mass b_coh sigma_inc sigma_abs +0 0 0 26.98 3.449 0.0082 0.231 diff --git a/mcstas-comps/data/MCViNE/fcc_toy_phonons/DOS b/mcstas-comps/data/MCViNE/fcc_toy_phonons/DOS new file mode 100644 index 0000000000..f4021edefb Binary files /dev/null and b/mcstas-comps/data/MCViNE/fcc_toy_phonons/DOS differ diff --git a/mcstas-comps/data/MCViNE/fcc_toy_phonons/Omega2 b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Omega2 new file mode 100644 index 0000000000..d4e3ada8ab Binary files /dev/null and b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Omega2 differ diff --git a/mcstas-comps/data/MCViNE/fcc_toy_phonons/Polarizations b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Polarizations new file mode 100644 index 0000000000..75f5c29d32 Binary files /dev/null and b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Polarizations differ diff --git a/mcstas-comps/data/MCViNE/fcc_toy_phonons/Qgridinfo b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Qgridinfo new file mode 100644 index 0000000000..811b3b086e --- /dev/null +++ b/mcstas-comps/data/MCViNE/fcc_toy_phonons/Qgridinfo @@ -0,0 +1,6 @@ +b1 = [np.float64(-1.5514037795505151), np.float64(1.5514037795505151), np.float64(1.5514037795505151)] +b2 = [np.float64(1.5514037795505151), np.float64(-1.5514037795505151), np.float64(1.5514037795505151)] +b3 = [np.float64(1.5514037795505151), np.float64(1.5514037795505151), np.float64(-1.5514037795505151)] +n1 = 13 +n2 = 13 +n3 = 13 diff --git a/mcstas-comps/data/MCViNE/make_fcc_toy_phonons.py b/mcstas-comps/data/MCViNE/make_fcc_toy_phonons.py new file mode 100644 index 0000000000..487dbaf074 --- /dev/null +++ b/mcstas-comps/data/MCViNE/make_fcc_toy_phonons.py @@ -0,0 +1,52 @@ +import numpy as np, importlib.util, struct, itertools, os +"""Toy fcc nearest-neighbour Born-von Karman phonons (a=4.05 AA, 1 atom) written in +MCViNE IDF format (Qgridinfo, Omega2, Polarizations, DOS). Needs the MCViNE repo +for the IDF writers: set MCVINE_IDF to mcvine/packages/mccomponents/python/mccomponents/sample/idf""" +MCVINE_IDF=os.environ.get('MCVINE_IDF','mcvine/packages/mccomponents/python/mccomponents/sample/idf') +os.makedirs('fcc_toy_phonons', exist_ok=True) +def load(name): + sp=importlib.util.spec_from_file_location(name,MCVINE_IDF+'/%s.py'%name) + m=importlib.util.module_from_spec(sp); sp.loader.exec_module(m); return m +O2=load('Omega2'); PO=load('Polarizations') +hbar=1.05457148e-34; hertz2mev=hbar/1.60217653e-22 +a=4.05 +nn=np.array([p for p in itertools.product([-1,0,1],repeat=3) if sum(abs(np.array(p)))==2])*a/2 # 12 neighbours +b=2*np.pi/a*np.array([[-1,1,1],[1,-1,1],[1,1,-1]]) +def dyn(q): + D=np.zeros((3,3)) + for R in nn: + Rh=R/np.linalg.norm(R); D+= (1-np.cos(q@R))*np.outer(Rh,Rh) + return D +Emax_target=38. +# scale: max eigenvalue over zone +lam_max=max(np.linalg.eigvalsh(dyn(c@b)).max() for c in np.random.rand(3000,3)) +C=(Emax_target/hertz2mev)**2/lam_max +def phonons(q): + w2,ev=np.linalg.eigh(dyn(q)*C); ev=ev.T + for m in range(3): + i=np.argmax(abs(ev[m])); + if ev[m,i]<0: ev[m]*=-1 + return w2, ev # rows = modes +if __name__=='__main__': + n=13 + f=np.linspace(0,1,n) + om2=[];pol=[] + for i,j,k in itertools.product(range(n),repeat=3): + q=np.array([f[i],f[j],f[k]])@b + w2,ev=phonons(q); om2.append(w2); pol.append(ev.reshape(3,1,3).astype(complex)) + om2=np.array(om2); pol=np.array(pol) + O2.write(om2,'fcc_toy_phonons/Omega2'); PO.write(pol,'fcc_toy_phonons/Polarizations') + with open('fcc_toy_phonons/Qgridinfo','w') as fh: + for i in range(3): fh.write("b%d = [%r, %r, %r]\n"%(i+1,*b[i])) + for i in range(3): fh.write("n%d = %d\n"%(i+1,n)) + # DOS by sampling + E=np.sqrt(np.clip(np.array([phonons(c@b)[0] for c in np.random.rand(200000,3)]),0,None))*hertz2mev + h,edges=np.histogram(E.ravel(),bins=200,range=(0,40)); e=0.5*(edges[1:]+edges[:-1]) + np.savetxt('fcc_toy_dos.dat', np.c_[e,h/h.sum()/0.2], header='E(meV) g') + # IDF DOS (THz) with bins starting at 0 + dE_THz=0.2/hertz2mev/1e12/2/np.pi + with open('fcc_toy_phonons/DOS','wb') as fh: + fh.write(struct.pack('<64s',b'DOS')); fh.write(struct.pack('e; + if (e->n >= e->cap) { + e->cap = e->cap ? 2 * e->cap : 64; + e->op = (int*)mcvine_xrealloc (e->op, e->cap * sizeof (int)); + e->val = (double*)mcvine_xrealloc (e->val, e->cap * sizeof (double)); + } + e->op[e->n] = op; + e->val[e->n] = val; + e->n++; +} +static void +mcvx_skip (mcvx_parser* P) { + while (P->s[P->pos] == ' ' || P->s[P->pos] == '\t' || P->s[P->pos] == '\n' || P->s[P->pos] == '\r') + P->pos++; +} +static int +mcvx_peek (mcvx_parser* P) { + mcvx_skip (P); + return P->s[P->pos]; +} +static void +mcvx_fail (mcvx_parser* P, const char* m) { + if (!P->err) { + P->err = 1; + snprintf (P->msg, sizeof (P->msg), "%s at position %d", m, P->pos); + } +} +static void mcvx_or (mcvx_parser* P); +static void mcvx_unary (mcvx_parser* P); + +static void +mcvx_primary (mcvx_parser* P) { + int c = mcvx_peek (P); + if (P->err) + return; + if (c == '(') { + P->pos++; + mcvx_or (P); + if (mcvx_peek (P) != ')') { + mcvx_fail (P, "expected ')'"); + return; + } + P->pos++; + return; + } + if ((c >= '0' && c <= '9') || c == '.') { + char* end; + double v = strtod (P->s + P->pos, &end); + if (end == P->s + P->pos) { + mcvx_fail (P, "bad number"); + return; + } + P->pos = end - P->s; + mcvx_emit (P, MCVX_CONST, v); + return; + } + if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || c == '_') { + char name[64]; + int n = 0, i; + while (n < 63 + && ((P->s[P->pos] >= 'a' && P->s[P->pos] <= 'z') || (P->s[P->pos] >= 'A' && P->s[P->pos] <= 'Z') || (P->s[P->pos] >= '0' && P->s[P->pos] <= '9') + || P->s[P->pos] == '_')) + name[n++] = P->s[P->pos++]; + name[n] = 0; + for (i = 0; i < P->nvars; i++) + if (!strcmp (name, P->vars[i])) { + mcvx_emit (P, MCVX_VAR, i); + return; + } + if (mcvx_peek (P) == '(') { + int nargs = 0; + P->pos++; + if (mcvx_peek (P) != ')') { + for (;;) { + mcvx_or (P); + nargs++; + if (P->err) + return; + if (mcvx_peek (P) == ',') { + P->pos++; + continue; + } + break; + } + } + if (mcvx_peek (P) != ')') { + mcvx_fail (P, "expected ')' after function arguments"); + return; + } + P->pos++; + if (!strcmp (name, "if")) { + if (nargs != 3) + mcvx_fail (P, "if() needs 3 arguments"); + else + mcvx_emit (P, MCVX_IF, 0); + return; + } + for (i = 0; mcvx_fn1_names[i]; i++) + if (!strcmp (name, mcvx_fn1_names[i])) { + if (nargs != 1) + mcvx_fail (P, "function needs 1 argument"); + else + mcvx_emit (P, MCVX_FN1, i); + return; + } + for (i = 0; mcvx_fn2_names[i]; i++) + if (!strcmp (name, mcvx_fn2_names[i])) { + if (nargs != 2) + mcvx_fail (P, "function needs 2 arguments"); + else + mcvx_emit (P, MCVX_FN2, i); + return; + } + mcvx_fail (P, "unknown function"); + return; + } + if (!strcmp (name, "pi")) { + mcvx_emit (P, MCVX_CONST, MCVINE_PI); + return; + } + if (!strcmp (name, "e")) { + mcvx_emit (P, MCVX_CONST, exp (1.0)); + return; + } + snprintf (P->msg, sizeof (P->msg), "unknown variable '%s' at position %d", name, P->pos); + P->err = 1; + return; + } + mcvx_fail (P, "unexpected character"); +} +static void +mcvx_power (mcvx_parser* P) { + mcvx_primary (P); + if (P->err) + return; + if (mcvx_peek (P) == '^' || (P->s[P->pos] == '*' && P->s[P->pos + 1] == '*')) { + P->pos += (P->s[P->pos] == '^') ? 1 : 2; + mcvx_unary (P); + mcvx_emit (P, MCVX_POW, 0); + } +} +static void +mcvx_unary (mcvx_parser* P) { + int c = mcvx_peek (P); + if (c == '-') { + P->pos++; + mcvx_unary (P); + mcvx_emit (P, MCVX_NEG, 0); + return; + } + if (c == '+') { + P->pos++; + mcvx_unary (P); + return; + } + if (c == '!') { + P->pos++; + mcvx_unary (P); + mcvx_emit (P, MCVX_NOT, 0); + return; + } + mcvx_power (P); +} +static void +mcvx_prod (mcvx_parser* P) { + mcvx_unary (P); + for (;;) { + int c = mcvx_peek (P); + if (P->err) + return; + if (c == '*' && P->s[P->pos + 1] != '*') { + P->pos++; + mcvx_unary (P); + mcvx_emit (P, MCVX_MUL, 0); + } else if (c == '/') { + P->pos++; + mcvx_unary (P); + mcvx_emit (P, MCVX_DIV, 0); + } else if (c == '%') { + P->pos++; + mcvx_unary (P); + mcvx_emit (P, MCVX_MOD, 0); + } else + return; + } +} +static void +mcvx_sum (mcvx_parser* P) { + mcvx_prod (P); + for (;;) { + int c = mcvx_peek (P); + if (P->err) + return; + if (c == '+') { + P->pos++; + mcvx_prod (P); + mcvx_emit (P, MCVX_ADD, 0); + } else if (c == '-') { + P->pos++; + mcvx_prod (P); + mcvx_emit (P, MCVX_SUB, 0); + } else + return; + } +} +static void +mcvx_cmp (mcvx_parser* P) { + mcvx_sum (P); + for (;;) { + int c = mcvx_peek (P), c2 = P->s[P->pos + 1]; + if (P->err) + return; + if (c == '<' && c2 == '=') { + P->pos += 2; + mcvx_sum (P); + mcvx_emit (P, MCVX_LE, 0); + } else if (c == '>' && c2 == '=') { + P->pos += 2; + mcvx_sum (P); + mcvx_emit (P, MCVX_GE, 0); + } else if (c == '!' && c2 == '=') { + P->pos += 2; + mcvx_sum (P); + mcvx_emit (P, MCVX_NE, 0); + } else if (c == '=') { + P->pos += (c2 == '=') ? 2 : 1; + mcvx_sum (P); + mcvx_emit (P, MCVX_EQ, 0); + } else if (c == '<') { + P->pos++; + mcvx_sum (P); + mcvx_emit (P, MCVX_LT, 0); + } else if (c == '>') { + P->pos++; + mcvx_sum (P); + mcvx_emit (P, MCVX_GT, 0); + } else + return; + } +} +static void +mcvx_and (mcvx_parser* P) { + mcvx_cmp (P); + while (!P->err && mcvx_peek (P) == '&') { + P->pos++; + if (P->s[P->pos] == '&') + P->pos++; + mcvx_cmp (P); + mcvx_emit (P, MCVX_AND, 0); + } +} +static void +mcvx_or (mcvx_parser* P) { + mcvx_and (P); + while (!P->err && mcvx_peek (P) == '|') { + P->pos++; + if (P->s[P->pos] == '|') + P->pos++; + mcvx_and (P); + mcvx_emit (P, MCVX_OR, 0); + } +} + +int +mcvine_expr_compile (mcvine_expr* e, const char* src, int nvars, const char** varnames, const char* owner) { + mcvx_parser P; + int i, depth = 0, maxdepth = 0; + memset (e, 0, sizeof (*e)); + if (!src || !src[0]) { + fprintf (stderr, "%s: empty expression\n", owner); + return 1; + } + strncpy (e->text, src, sizeof (e->text) - 1); + memset (&P, 0, sizeof (P)); + P.s = src; + P.e = e; + P.nvars = nvars; + P.vars = varnames; + mcvx_or (&P); + if (!P.err && mcvx_peek (&P) != 0) + mcvx_fail (&P, "trailing characters"); + if (P.err) { + fprintf (stderr, "%s: cannot parse expression \"%s\": %s\n (allowed variables:", owner, src, P.msg); + for (i = 0; i < nvars; i++) + fprintf (stderr, " %s", varnames[i]); + fprintf (stderr, ")\n"); + return 1; + } + for (i = 0; i < e->n; i++) { + int op = e->op[i]; + if (op == MCVX_CONST || op == MCVX_VAR) + depth++; + else if (op == MCVX_NEG || op == MCVX_NOT || op == MCVX_FN1) + ; + else if (op == MCVX_IF) + depth -= 2; + else + depth--; + if (depth > maxdepth) + maxdepth = depth; + } + if (maxdepth > MCVINE_EXPR_MAXSTACK) { + fprintf (stderr, "%s: expression too deep\n", owner); + return 1; + } + return 0; +} + +void +mcvine_expr_free (mcvine_expr* e) { + free (e->op); + free (e->val); + e->op = NULL; + e->val = NULL; + e->n = e->cap = 0; +} + +double +mcvine_expr_eval (const mcvine_expr* e, const double* vars) { + double st[MCVINE_EXPR_MAXSTACK]; + int sp = 0, i; + for (i = 0; i < e->n; i++) { + double a, b; + switch (e->op[i]) { + case MCVX_CONST: + st[sp++] = e->val[i]; + break; + case MCVX_VAR: + st[sp++] = vars[(int)e->val[i]]; + break; + case MCVX_NEG: + st[sp - 1] = -st[sp - 1]; + break; + case MCVX_NOT: + st[sp - 1] = (st[sp - 1] == 0); + break; + case MCVX_FN1: + a = st[sp - 1]; + switch ((int)e->val[i]) { + case 0: + a = sin (a); + break; + case 1: + a = cos (a); + break; + case 2: + a = tan (a); + break; + case 3: + a = asin (a); + break; + case 4: + a = acos (a); + break; + case 5: + a = atan (a); + break; + case 6: + a = sinh (a); + break; + case 7: + a = cosh (a); + break; + case 8: + a = tanh (a); + break; + case 9: + a = exp (a); + break; + case 10: + a = log (a); + break; + case 11: + a = log10 (a); + break; + case 12: + a = log (a) / log (2.0); + break; + case 13: + a = sqrt (a); + break; + case 14: + a = fabs (a); + break; + case 15: + a = floor (a); + break; + case 16: + a = ceil (a); + break; + case 17: + a = floor (a + 0.5); + break; + case 18: + a = (a > 0) - (a < 0); + break; + case 19: + a = 1 / tan (a); + break; + case 20: + a = 1 / cos (a); + break; + case 21: + a = 1 / sin (a); + break; + case 22: + a = pow (2.0, a); + break; + case 23: + a = cbrt (a); + break; + case 24: + a = trunc (a); + break; + } + st[sp - 1] = a; + break; + case MCVX_FN2: + b = st[--sp]; + a = st[sp - 1]; + switch ((int)e->val[i]) { + case 0: + a = pow (a, b); + break; + case 1: + a = atan2 (a, b); + break; + case 2: + a = a < b ? a : b; + break; + case 3: + a = a > b ? a : b; + break; + case 4: + a = hypot (a, b); + break; + case 5: + a = fmod (a, b); + break; + } + st[sp - 1] = a; + break; + case MCVX_IF: { + double c3 = st[--sp], c2 = st[--sp]; + st[sp - 1] = (st[sp - 1] != 0) ? c2 : c3; + } break; + default: + b = st[--sp]; + a = st[sp - 1]; + switch (e->op[i]) { + case MCVX_ADD: + a = a + b; + break; + case MCVX_SUB: + a = a - b; + break; + case MCVX_MUL: + a = a * b; + break; + case MCVX_DIV: + a = a / b; + break; + case MCVX_MOD: + a = fmod (a, b); + break; + case MCVX_POW: + a = pow (a, b); + break; + case MCVX_LT: + a = a < b; + break; + case MCVX_GT: + a = a > b; + break; + case MCVX_LE: + a = a <= b; + break; + case MCVX_GE: + a = a >= b; + break; + case MCVX_EQ: + a = a == b; + break; + case MCVX_NE: + a = a != b; + break; + case MCVX_AND: + a = (a != 0) && (b != 0); + break; + case MCVX_OR: + a = (a != 0) || (b != 0); + break; + } + st[sp - 1] = a; + } + } + return sp > 0 ? st[sp - 1] : 0; +} + +/* ======================================================================== */ +/* files and grids */ +/* ======================================================================== */ +FILE* +mcvine_fopen (const char* name, const char* mode) { + /* Use the McStas file search (current dir, instrument dir, $MCSTAS/data, + $MCSTAS/contrib) from read_table-lib when it is available. */ + char buf[4096]; + if (!name || !name[0]) + return NULL; + strncpy (buf, name, sizeof (buf) - 1); + buf[sizeof (buf) - 1] = 0; +#ifdef READ_TABLE_LIB_H + return Open_File (buf, mode, NULL); +#else + { + FILE* f = fopen (buf, mode); + const char* env; + char path[8192]; + if (f) + return f; + env = getenv ("MCSTAS"); + if (env) { + snprintf (path, sizeof (path), "%s/data/%s", env, buf); + f = fopen (path, mode); + if (f) + return f; + } + return NULL; + } +#endif +} + +int +mcvine_read_rows (const char* file, mcvine_rows* r, const char* owner) { + FILE* f = mcvine_fopen (file, "r"); + size_t cap = 1 << 16; + char* line; + int rowcap = 0; + memset (r, 0, sizeof (*r)); + if (!f) { + fprintf (stderr, "%s: cannot open file '%s'\n", owner, file); + return 1; + } + line = (char*)mcvine_xmalloc (cap); + for (;;) { + size_t len = 0; + int c; + char *s, *end; + int n = 0, ncap = 16; + double* vals; + while ((c = fgetc (f)) != EOF && c != '\n') { + if (len + 2 >= cap) { + cap *= 2; + line = (char*)mcvine_xrealloc (line, cap); + } + line[len++] = (char)c; + } + line[len] = 0; + if (c == EOF && len == 0) + break; + s = line; + while (*s == ' ' || *s == '\t' || *s == '\r') + s++; + if (*s == '#' || *s == 0 || *s == '%') { + if (c == EOF) + break; + continue; + } + for (end = s; *end; end++) + if (*end == ',' || *end == ';' || *end == '[' || *end == ']') + *end = ' '; + vals = (double*)mcvine_xmalloc (ncap * sizeof (double)); + for (;;) { + double v = strtod (s, &end); + if (end == s) + break; + if (n >= ncap) { + ncap *= 2; + vals = (double*)mcvine_xrealloc (vals, ncap * sizeof (double)); + } + vals[n++] = v; + s = end; + } + if (n > 0) { + if (r->nrows >= rowcap) { + rowcap = rowcap ? 2 * rowcap : 64; + r->rows = (double**)mcvine_xrealloc (r->rows, rowcap * sizeof (double*)); + r->ncols = (int*)mcvine_xrealloc (r->ncols, rowcap * sizeof (int)); + } + r->rows[r->nrows] = vals; + r->ncols[r->nrows] = n; + r->nrows++; + } else + free (vals); + if (c == EOF) + break; + } + free (line); + fclose (f); + if (r->nrows == 0) { + fprintf (stderr, "%s: no numeric data in '%s'\n", owner, file); + return 1; + } + return 0; +} + +void +mcvine_free_rows (mcvine_rows* r) { + int i; + for (i = 0; i < r->nrows; i++) + free (r->rows[i]); + free (r->rows); + free (r->ncols); + memset (r, 0, sizeof (*r)); +} + +/* flatten rows [first, nrows) into one array; returns count */ +static int +mcvine_rows_flatten (const mcvine_rows* r, int first, double** out) { + int i, j, n = 0, k = 0; + for (i = first; i < r->nrows; i++) + n += r->ncols[i]; + *out = (double*)mcvine_xmalloc ((n > 0 ? n : 1) * sizeof (double)); + for (i = first; i < r->nrows; i++) + for (j = 0; j < r->ncols[i]; j++) + (*out)[k++] = r->rows[i][j]; + return n; +} + +/* index i with x[i] <= v <= x[i+1]; -1 if outside */ +static int +mcvine_bracket (const double* x, int n, double v, double* frac) { + int lo = 0, hi = n - 1; + if (n < 2 || v < x[0] || v > x[n - 1] || v != v) + return -1; + while (hi - lo > 1) { + int m = (lo + hi) / 2; + if (x[m] <= v) + lo = m; + else + hi = m; + } + *frac = (x[hi] > x[lo]) ? (v - x[lo]) / (x[hi] - x[lo]) : 0; + return lo; +} + +int +mcvine_table1d_load (mcvine_table1d* t, const char* file, const char* owner) { + mcvine_rows r; + int i; + if (mcvine_read_rows (file, &r, owner)) + return 1; + t->n = 0; + t->x = (double*)mcvine_xmalloc (r.nrows * sizeof (double)); + t->y = (double*)mcvine_xmalloc (r.nrows * sizeof (double)); + for (i = 0; i < r.nrows; i++) + if (r.ncols[i] >= 2) { + t->x[t->n] = r.rows[i][0]; + t->y[t->n] = r.rows[i][1]; + t->n++; + } + mcvine_free_rows (&r); + for (i = 1; i < t->n; i++) + if (t->x[i] <= t->x[i - 1]) { + fprintf (stderr, "%s: first column of '%s' must be strictly ascending\n", owner, file); + return 1; + } + if (t->n < 2) { + fprintf (stderr, "%s: '%s' needs at least 2 rows with 2 columns\n", owner, file); + return 1; + } + return 0; +} +double +mcvine_table1d_eval (const mcvine_table1d* t, double x) { + double f; + int i = mcvine_bracket (t->x, t->n, x, &f); + if (i < 0) + return 0; + return t->y[i] * (1 - f) + t->y[i + 1] * f; +} + +double +mcvine_grid2d_eval (const mcvine_grid2d* g, double x, double y) { + double fx, fy; + int i = mcvine_bracket (g->x, g->nx, x, &fx), j = mcvine_bracket (g->y, g->ny, y, &fy); + const double* f = g->f; + int ny = g->ny; + if (i < 0 || j < 0) + return 0; + return (1 - fx) * (1 - fy) * f[i * ny + j] + fx * (1 - fy) * f[(i + 1) * ny + j] + (1 - fx) * fy * f[i * ny + j + 1] + fx * fy * f[(i + 1) * ny + j + 1]; +} +static int +mcvine_axis_ok (const double* x, int n, const char* what, const char* file, const char* owner) { + int i; + if (n < 2) { + fprintf (stderr, "%s: %s axis in '%s' needs >= 2 values\n", owner, what, file); + return 0; + } + for (i = 1; i < n; i++) + if (x[i] <= x[i - 1]) { + fprintf (stderr, "%s: %s axis in '%s' must be ascending\n", owner, what, file); + return 0; + } + return 1; +} +int +mcvine_grid2d_load_sqw (mcvine_grid2d* g, const char* file, const char* owner) { + mcvine_rows r; + double* flat; + int n, i; + if (mcvine_read_rows (file, &r, owner)) + return 1; + if (r.nrows < 3) { + fprintf (stderr, "%s: '%s': expected q row, w row and S matrix\n", owner, file); + return 1; + } + g->nx = r.ncols[0]; + g->ny = r.ncols[1]; + g->x = (double*)mcvine_xmalloc (g->nx * sizeof (double)); + g->y = (double*)mcvine_xmalloc (g->ny * sizeof (double)); + memcpy (g->x, r.rows[0], g->nx * sizeof (double)); + memcpy (g->y, r.rows[1], g->ny * sizeof (double)); + n = mcvine_rows_flatten (&r, 2, &flat); + mcvine_free_rows (&r); + if (!mcvine_axis_ok (g->x, g->nx, "q", file, owner) || !mcvine_axis_ok (g->y, g->ny, "w", file, owner)) + return 1; + if (n != g->nx * g->ny) { + fprintf (stderr, "%s: '%s': S matrix has %d values, expected nq*nw=%d\n", owner, file, n, g->nx * g->ny); + return 1; + } + g->f = flat; /* already q-major: f[iq*nw + iw] */ + for (i = 0; i < n; i++) + if (g->f[i] != g->f[i]) + g->f[i] = 0; + return 0; +} +int +mcvine_grid2d_load_image (mcvine_grid2d* g, const char* file, const char* owner) { + mcvine_rows r; + double* flat; + int n, ix, iy; + if (mcvine_read_rows (file, &r, owner)) + return 1; + if (r.nrows < 3) { + fprintf (stderr, "%s: '%s': expected x row, y row and data\n", owner, file); + return 1; + } + g->nx = r.ncols[0]; + g->ny = r.ncols[1]; + g->x = (double*)mcvine_xmalloc (g->nx * sizeof (double)); + g->y = (double*)mcvine_xmalloc (g->ny * sizeof (double)); + memcpy (g->x, r.rows[0], g->nx * sizeof (double)); + memcpy (g->y, r.rows[1], g->ny * sizeof (double)); + n = mcvine_rows_flatten (&r, 2, &flat); + mcvine_free_rows (&r); + if (!mcvine_axis_ok (g->x, g->nx, "x", file, owner) || !mcvine_axis_ok (g->y, g->ny, "y", file, owner)) + return 1; + if (n != g->nx * g->ny) { + fprintf (stderr, "%s: '%s': data has %d values, expected nx*ny=%d\n", owner, file, n, g->nx * g->ny); + return 1; + } + g->f = (double*)mcvine_xmalloc (n * sizeof (double)); + for (iy = 0; iy < g->ny; iy++) + for (ix = 0; ix < g->nx; ix++) + g->f[ix * g->ny + iy] = flat[iy * g->nx + ix]; + free (flat); + return 0; +} + +int +mcvine_grid3d_load (mcvine_grid3d* g, const char* file, const char* owner) { + mcvine_rows r; + int i, n; + if (mcvine_read_rows (file, &r, owner)) + return 1; + if (r.nrows < 4) { + fprintf (stderr, "%s: '%s': expected 3 axis rows (min max n) + data\n", owner, file); + return 1; + } + for (i = 0; i < 3; i++) { + if (r.ncols[i] < 3) { + fprintf (stderr, "%s: '%s': axis row %d must be 'min max n'\n", owner, file, i + 1); + return 1; + } + g->min[i] = r.rows[i][0]; + g->max[i] = r.rows[i][1]; + g->n[i] = (int)(r.rows[i][2] + 0.5); + if (g->n[i] < 2 || g->max[i] <= g->min[i]) { + fprintf (stderr, "%s: '%s': bad axis %d\n", owner, file, i + 1); + return 1; + } + g->step[i] = (g->max[i] - g->min[i]) / (g->n[i] - 1); + } + n = mcvine_rows_flatten (&r, 3, &g->f); + mcvine_free_rows (&r); + if (n != g->n[0] * g->n[1] * g->n[2]) { + fprintf (stderr, "%s: '%s': %d data values, expected %d\n", owner, file, n, g->n[0] * g->n[1] * g->n[2]); + return 1; + } + return 0; +} +double +mcvine_grid3d_eval (const mcvine_grid3d* g, double x, double y, double z) { + double v[3] = { x, y, z }, fr[3]; + int id[3], k, n1 = g->n[1], n2 = g->n[2]; + double c00, c01, c10, c11, c0, c1; + const double* f = g->f; + for (k = 0; k < 3; k++) { + double rr = (v[k] - g->min[k]) / g->step[k]; + if (rr < 0 || rr > g->n[k] - 1 || rr != rr) + return 0; + id[k] = (int)floor (rr); + if (id[k] >= g->n[k] - 1) + id[k] = g->n[k] - 2; + fr[k] = rr - id[k]; + } +#define MCV_G3(i, j, l) f[((i) * n1 + (j)) * n2 + (l)] + c00 = MCV_G3 (id[0], id[1], id[2]) * (1 - fr[0]) + MCV_G3 (id[0] + 1, id[1], id[2]) * fr[0]; + c01 = MCV_G3 (id[0], id[1], id[2] + 1) * (1 - fr[0]) + MCV_G3 (id[0] + 1, id[1], id[2] + 1) * fr[0]; + c10 = MCV_G3 (id[0], id[1] + 1, id[2]) * (1 - fr[0]) + MCV_G3 (id[0] + 1, id[1] + 1, id[2]) * fr[0]; + c11 = MCV_G3 (id[0], id[1] + 1, id[2] + 1) * (1 - fr[0]) + MCV_G3 (id[0] + 1, id[1] + 1, id[2] + 1) * fr[0]; +#undef MCV_G3 + c0 = c00 * (1 - fr[1]) + c10 * fr[1]; + c1 = c01 * (1 - fr[1]) + c11 * fr[1]; + return c0 * (1 - fr[2]) + c1 * fr[2]; +} + +double +mcvine_func_eval (const mcvine_func* f, const double* v) { + switch (f->mode) { + case 0: + return f->c; + case 1: + return mcvine_expr_eval (&f->expr, v); + case 2: + return mcvine_table1d_eval (&f->t1, v[0]); + case 3: + return mcvine_grid2d_eval (&f->g2, v[0], v[1]); + case 4: + return mcvine_grid3d_eval (&f->g3, v[0], v[1], v[2]); + } + return 0; +} + +int +mcvine_func_setup (mcvine_func* f, const char* expr, const char* file, int filetype, int nvars, const char** vars, const char* owner) { + memset (f, 0, sizeof (*f)); + if (file && file[0] && strcmp (file, "NULL") && strcmp (file, "0")) { + f->mode = filetype; + if (filetype == 2) + return mcvine_table1d_load (&f->t1, file, owner); + if (filetype == 3) + return mcvine_grid2d_load_sqw (&f->g2, file, owner); + if (filetype == 4) + return mcvine_grid3d_load (&f->g3, file, owner); + fprintf (stderr, "%s: internal error, bad file type\n", owner); + return 1; + } + if (!expr || !expr[0]) { + fprintf (stderr, "%s: need an expression or a data file\n", owner); + return 1; + } + { + char* end; + double c = strtod (expr, &end); + while (end && (*end == ' ' || *end == '\t')) + end++; + if (end != expr && end && *end == 0) { + f->mode = 0; + f->c = c; + return 0; + } + } + f->mode = 1; + return mcvine_expr_compile (&f->expr, expr, nvars, vars, owner); +} + +/* ======================================================================== */ +/* vectors */ +/* ======================================================================== */ +double +mcvine_len3 (const double* a) { + return sqrt (a[0] * a[0] + a[1] * a[1] + a[2] * a[2]); +} +void +mcvine_cross3 (const double* a, const double* b, double* c) { + c[0] = a[1] * b[2] - a[2] * b[1]; + c[1] = a[2] * b[0] - a[0] * b[2]; + c[2] = a[0] * b[1] - a[1] * b[0]; +} +void +mcvine_frame (const double* v, double* e1, double* e2, double* e3) { + double l = mcvine_len3 (v); + e1[0] = v[0] / l; + e1[1] = v[1] / l; + e1[2] = v[2] / l; + if (fabs (e1[0]) > 1e-4 || fabs (e1[1]) > 1e-4) { + double z[3] = { 0, 0, 1 }, m; + mcvine_cross3 (z, e1, e2); + m = mcvine_len3 (e2); + e2[0] /= m; + e2[1] /= m; + e2[2] /= m; + } else { + e2[0] = 1; + e2[1] = 0; + e2[2] = 0; + } + mcvine_cross3 (e1, e2, e3); +} +void +mcvine_dir_from_frame (const double* e1, const double* e2, const double* e3, double cost, double sint, double phi, double* dir) { + double c = cos (phi), s = sin (phi); + int i; + for (i = 0; i < 3; i++) + dir[i] = sint * c * e2[i] + sint * s * e3[i] + cost * e1[i]; +} +static void +mcvine_random_direction (double* d, _class_particle* _particle) { + double cost = 2 * rand01 () - 1, sint = sqrt (1 - cost * cost), phi = 2 * MCVINE_PI * rand01 (); + d[0] = sint * cos (phi); + d[1] = sint * sin (phi); + d[2] = cost; +} +static double +mcvine_E2k (double E) { + return E > 0 ? V2K * SE2V * sqrt (E) : 0; +} +static double +mcvine_k2E (double k) { + return VS2E * (K2V * k) * (K2V * k); +} + +/* Ridders' method (mccomponents/math/rootfinding.cc, zridd) */ +typedef double (*mcvine_f1) (double, void*); +static int +mcvine_zridd (mcvine_f1 f, void* ctx, double x1, double x2, double xacc, double* root) { + double fl = f (x1, ctx), fh = f (x2, ctx), ans, xl, xh, xm, fm, s, xnew, fnew; + int j; + if (fl * fh >= 0) { + if (fl == 0) { + *root = x1; + return 1; + } + if (fh == 0) { + *root = x2; + return 1; + } + return 0; + } + xl = x1; + xh = x2; + ans = -1.11e30; + for (j = 1; j < 60; j++) { + xm = 0.5 * (xl + xh); + fm = f (xm, ctx); + s = sqrt (fm * fm - fl * fh); + if (s == 0.0) + break; + xnew = xm + (xm - xl) * ((fl >= fh ? 1.0 : -1.0) * fm / s); + if (fabs (xnew - ans) <= xacc) { + ans = xnew; + break; + } + ans = xnew; + fnew = f (ans, ctx); + if (fnew == 0.0) + break; + if ((fnew >= 0 ? fabs (fm) : -fabs (fm)) != fm) { + xl = xm; + fl = fm; + xh = ans; + fh = fnew; + } else if ((fnew >= 0 ? fabs (fl) : -fabs (fl)) != fl) { + xh = ans; + fh = fnew; + } else if ((fnew >= 0 ? fabs (fh) : -fabs (fh)) != fh) { + xl = ans; + fl = fnew; + } else + return 0; + if (fabs (xh - xl) <= xacc) + break; + } + if (ans == -1.11e30) + return 0; + *root = ans; + return 1; +} +/* FindRootsEvenly: split [x1,x2] into nsteps and bracket each piece */ +static int +mcvine_find_roots (mcvine_f1 f, void* ctx, double x1, double x2, int nsteps, double xacc, double* roots, int maxroots) { + int i, n = 0; + double step = (x2 - x1) / nsteps; + for (i = 0; i < nsteps && n < maxroots; i++) { + double r; + if (mcvine_zridd (f, ctx, x1 + step * i, x1 + step * (i + 1), xacc, &r)) + roots[n++] = r; + } + return n; +} + +/* ======================================================================== */ +/* shapes and transport (mccomponents/lib/homogeneous_scatterer) */ +/* ======================================================================== */ +int +mcvine_shape_init (mcvine_shape* s, double radius, double xwidth, double yheight, double zdepth, double thickness, const char* owner) { + memset (s, 0, sizeof (*s)); + s->radius = radius; + s->xwidth = xwidth; + s->yheight = yheight; + s->zdepth = zdepth; + s->thickness = thickness; + if (xwidth > 0 && yheight > 0 && zdepth > 0) + s->type = MCVINE_SHAPE_BOX; + else if (radius > 0 && yheight > 0) + s->type = MCVINE_SHAPE_CYLINDER; + else if (radius > 0) + s->type = MCVINE_SHAPE_SPHERE; + else { + fprintf (stderr, "%s: specify a box (xwidth,yheight,zdepth), a cylinder (radius,yheight[,thickness]) or a sphere (radius)\n", owner); + return 1; + } + if (s->type == MCVINE_SHAPE_CYLINDER && thickness >= radius) { + fprintf (stderr, "%s: thickness must be smaller than radius\n", owner); + return 1; + } + return 0; +} + +int +mcvine_shape_segments (const mcvine_shape* s, double x, double y, double z, double vx, double vy, double vz, double* seg) { + double t0 = 0, t1 = 0, t2 = 0, t3 = 0, raw[4]; + int n = 0, i, k = 0, hit = 0; + switch (s->type) { + case MCVINE_SHAPE_BOX: + hit = box_intersect (&t0, &t3, x, y, z, vx, vy, vz, s->xwidth, s->yheight, s->zdepth); + break; + case MCVINE_SHAPE_CYLINDER: + hit = cylinder_intersect (&t0, &t3, x, y, z, vx, vy, vz, s->radius, s->yheight); + break; + case MCVINE_SHAPE_SPHERE: + hit = sphere_intersect (&t0, &t3, x, y, z, vx, vy, vz, s->radius); + break; + } + if (!hit) + return 0; + if (s->type == MCVINE_SHAPE_CYLINDER && s->thickness > 0 && cylinder_intersect (&t1, &t2, x, y, z, vx, vy, vz, s->radius - s->thickness, s->yheight) + && t2 > t1) { + raw[0] = t0; + raw[1] = t1; + raw[2] = t2; + raw[3] = t3; + n = 2; + } else { + raw[0] = t0; + raw[1] = t3; + n = 1; + } + for (i = 0; i < n; i++) { + double a = raw[2 * i], b = raw[2 * i + 1]; + if (a < 0) + a = 0; + if (b > a + 1e-15) { + seg[2 * k] = a; + seg[2 * k + 1] = b; + k++; + } + } + return k; +} + +double +mcvine_xs2coeff (double xs_barn, double V_AA3) { + return V_AA3 > 0 ? xs_barn / V_AA3 * 100.0 : 0; +} + +void +mcvine_scatterer_init (mcvine_scatterer* sc, const mcvine_shape* s, double mu2200, double sigma, double pack, double p_transmit, int order) { + sc->shape = *s; + sc->mu2200 = mu2200; + sc->sigma = sigma; + sc->pack = pack > 0 ? pack : 1; + sc->p_transmit = (p_transmit > 0 && p_transmit < 1) ? p_transmit : 0; + sc->order = order > 0 ? order : 1; +} + +int +mcvine_scatterer_interact (const mcvine_scatterer* sc, void* kernel, mcvine_S_fn S, _class_particle* _particle) { + double seg[4], r[3], vel[3]; + int nseg, k, nscat = 0; + for (k = 0;; k++) { + double v, T, L, mu, sig, tot, s, w, dt, acc; + int i; + nseg = mcvine_shape_segments (&sc->shape, _particle->x, _particle->y, _particle->z, _particle->vx, _particle->vy, _particle->vz, seg); + if (!nseg) + break; + v = sqrt (_particle->vx * _particle->vx + _particle->vy * _particle->vy + _particle->vz * _particle->vz); + if (v <= 0) + return -1; + T = 0; + for (i = 0; i < nseg; i++) + T += seg[2 * i + 1] - seg[2 * i]; + L = T * v; + mu = sc->mu2200 * 2200.0 / v * sc->pack; + sig = sc->sigma * sc->pack; + tot = mu + sig; + if (k == 0) { + /* first passage: MCViNE interact_path1 (uniform depth, forced scattering) */ + if (sc->p_transmit > 0 && rand01 () < sc->p_transmit) { + _particle->p *= exp (-tot * L) / sc->p_transmit; + return 0; + } + s = rand01 () * L; + w = L * exp (-tot * s) * sig; + if (sc->p_transmit > 0) + w /= (1 - sc->p_transmit); + } else { + double Pint; + if (k >= sc->order) { + _particle->p *= exp (-tot * L); + break; + } /* leave, attenuated */ + Pint = 1 - exp (-tot * L); + if (!(tot > 0) || rand01 () >= Pint) + break; /* escapes unscattered */ + s = -log (1 - rand01 () * Pint) / tot; + w = sig / tot; + } + /* move to the interaction point at path length s inside the material */ + dt = s / v; + acc = 0; + for (i = 0; i < nseg; i++) { + double d = seg[2 * i + 1] - seg[2 * i]; + if (dt <= acc + d || i == nseg - 1) { + dt = seg[2 * i] + (dt - acc); + break; + } + acc += d; + } + _particle->x += _particle->vx * dt; + _particle->y += _particle->vy * dt; + _particle->z += _particle->vz * dt; + _particle->t += dt; + _particle->p *= w; + r[0] = _particle->x; + r[1] = _particle->y; + r[2] = _particle->z; + vel[0] = _particle->vx; + vel[1] = _particle->vy; + vel[2] = _particle->vz; + if (!S (kernel, r, vel, _particle->t, &_particle->p, _particle)) + return -1; + if (!(_particle->p > 0) || vel[0] != vel[0] || vel[1] != vel[1] || vel[2] != vel[2]) + return -1; + _particle->vx = vel[0]; + _particle->vy = vel[1]; + _particle->vz = vel[2]; + nscat++; + } + return nscat; +} + +/* ======================================================================== */ +/* simple kernels */ +/* ======================================================================== */ +/* ConstantEnergyTransferKernel.cc */ +int +mcvine_S_ConstantEnergyTransfer (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_ConstantEnergyTransfer* k = (mcvine_kernel_ConstantEnergyTransfer*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Ef = Ei - k->m_E, vf, d[3]; + if (Ef < 0) + return 0; + vf = SE2V * sqrt (Ef); + mcvine_random_direction (d, _particle); + v[0] = d[0] * vf; + v[1] = d[1] * vf; + v[2] = d[2] * vf; + return 1; +} + +/* ConstantQEKernel.cc */ +int +mcvine_S_ConstantQE (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_ConstantQE* k = (mcvine_kernel_ConstantQE*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Ef = Ei - k->m_E, vf, ki, kf, cost, sint, e1[3], e2[3], e3[3], d[3]; + if (Ef <= 0) + return 0; + vf = SE2V * sqrt (Ef); + ki = V2K * vi; + kf = V2K * vf; + cost = (ki * ki + kf * kf - k->m_Q * k->m_Q) / (2 * ki * kf); + if (cost * cost > 1) + return 0; + sint = sqrt (1 - cost * cost); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + v[0] = d[0] * vf; + v[1] = d[1] * vf; + v[2] = d[2] * vf; + return 1; +} + +/* ConstantvQEKernel.cc */ +int +mcvine_S_ConstantvQE (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_ConstantvQE* k = (mcvine_kernel_ConstantvQE*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Ef, vf, E, x; + int i; + for (i = 0; i < 3; i++) + v[i] = (v[i] * V2K - k->m_Q[i]) * K2V; + vf = mcvine_len3 (v); + Ef = VS2E * vf * vf; + E = Ei - Ef; + x = (E - k->m_E) / k->m_dE; + *p *= exp (-x * x / 2); + return 1; +} + +/* E_Q_Kernel.icc : S(Q,E) = S(Q) delta(E - E(Q)) */ +int +mcvine_S_E_Q (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_E_Q* k = (mcvine_kernel_E_Q*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Q = 0, E, Ef, vf = 0, ki = V2K * vi, kf = 0, cost = 0, cost2 = 0, sint; + double e1[3], e2[3], e3[3], d[3]; + int counter = 0, ok = 0, maxtries = k->m_unbiased ? 1 : 100; + /* MCViNE retries up to 100 times and divides the weight by the number of + attempts; that is slightly biased (E[1/n] != acceptance). unbiased=1: + a single attempt, forbidden events get weight 0. */ + while (counter++ < maxtries) { + Q = k->m_Qmin + (k->m_Qmax - k->m_Qmin) * rand01 (); + E = mcvine_func_eval (&k->m_E_Q, &Q); + Ef = Ei - E; + if (Ef < 0) + continue; + vf = SE2V * sqrt (Ef); + kf = V2K * vf; + cost = (ki * ki + kf * kf - Q * Q) / (2 * ki * kf); + cost2 = cost * cost; + if (cost2 > 1) + continue; + ok = 1; + break; + } + if (!ok) + return 0; + sint = sqrt (1 - cost2); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + *p *= mcvine_func_eval (&k->m_S_Q, &Q) * (vf / vi); + *p *= Q * (k->m_Qmax - k->m_Qmin) / counter / (kf * ki) / 2; + v[0] = d[0] * vf; + v[1] = d[1] * vf; + v[2] = d[2] * vf; + return 1; +} + +/* Broadened_E_Q_Kernel.icc / LorentzianBroadened_E_Q_Kernel.icc */ +void +mcvine_Broadened_E_Q_init (mcvine_kernel_Broadened_E_Q* k) { + int i, N = 100; + double dQ = (k->m_Qmax - k->m_Qmin) / N; + k->m_Emin = 1e300; + k->m_Emax = -1e300; + for (i = 0; i < N; i++) { + double Q = k->m_Qmin + dQ * i, E = mcvine_func_eval (&k->m_E_Q, &Q), w = mcvine_func_eval (&k->m_W_Q, &Q); + if (E - 3 * w < k->m_Emin) + k->m_Emin = E - 3 * w; + if (E + 3 * w > k->m_Emax) + k->m_Emax = E + 3 * w; + } +} +int +mcvine_S_Broadened_E_Q (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_Broadened_E_Q* k = (mcvine_kernel_Broadened_E_Q*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Q = 0, E, Ef = 0, vf = 0, ki = V2K * vi, kf = 0, cost = 0, cost2 = 0, sint; + double e1[3], e2[3], e3[3], d[3]; + int count = 0, ok = 0, maxtries = k->m_unbiased ? 1 : 99; + if (Ei < k->m_Emin) + return 0; + /* MCViNE retries (at most 99 successful tries) without correcting the weight + for the acceptance probability; unbiased=1 uses a single attempt. */ + while (count++ < maxtries) { + double dE; + Q = k->m_Qmin + (k->m_Qmax - k->m_Qmin) * rand01 (); + if (k->m_lorentzian) + dE = tan (MCVINE_PI * (rand01 () - 0.5)) * mcvine_func_eval (&k->m_W_Q, &Q); + else { + double x1, x2, w; /* polar Box-Muller, as mccomponents/math/random/gaussian.cc */ + do { + x1 = 2 * rand01 () - 1; + x2 = 2 * rand01 () - 1; + w = x1 * x1 + x2 * x2; + } while (w >= 1 || w == 0); + dE = x1 * sqrt (-2 * log (w) / w) * mcvine_func_eval (&k->m_W_Q, &Q); + } + E = mcvine_func_eval (&k->m_E_Q, &Q) + dE; + Ef = Ei - E; + if (Ef <= 0) + continue; + vf = SE2V * sqrt (Ef); + kf = V2K * vf; + cost = (ki * ki + kf * kf - Q * Q) / (2 * ki * kf); + cost2 = cost * cost; + if (cost2 > 1) + continue; + ok = 1; + break; + } + if (!ok) + return 0; + sint = sqrt (1 - cost2); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + *p *= mcvine_func_eval (&k->m_S_Q, &Q) * (vf / vi); + *p /= 4 * MCVINE_PI; + *p *= Q * (k->m_Qmax - k->m_Qmin) / (kf * ki) * 2 * MCVINE_PI; + v[0] = d[0] * vf; + v[1] = d[1] * vf; + v[2] = d[2] * vf; + return 1; +} + +/* E_vQ_Kernel.icc : S(vQ,E) = S(vQ) delta(E - E(vQ)) */ +typedef struct { + const mcvine_func* E; + double ukf[3], ki[3], Ei; +} mcvine_evq_ctx; +static double +mcvine_evq_f (double kf, void* c) { + mcvine_evq_ctx* x = (mcvine_evq_ctx*)c; + double Q[3]; + int i; + for (i = 0; i < 3; i++) + Q[i] = x->ki[i] - x->ukf[i] * kf; + return x->Ei - mcvine_k2E (kf) - mcvine_func_eval (x->E, Q); +} +int +mcvine_S_E_vQ (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_E_vQ* k = (mcvine_kernel_E_vQ*)kk; + mcvine_evq_ctx c; + double roots[1024], vi = mcvine_len3 (v), kmag, kf, dkf, df, E, Q[3]; + int i, nkf, idx; + c.E = &k->m_E_Q; + c.Ei = VS2E * vi * vi; + for (i = 0; i < 3; i++) + c.ki[i] = V2K * v[i]; + kmag = V2K * vi; + mcvine_random_direction (c.ukf, _particle); + nkf = mcvine_find_roots (mcvine_evq_f, &c, mcvine_E2k (c.Ei - k->m_Emax > 0 ? c.Ei - k->m_Emax : 0), mcvine_E2k (c.Ei), k->m_nsteps, k->m_xacc, roots, 1024); + if (nkf < 1) + return 0; + idx = nkf > 1 ? (int)floor (rand01 () * nkf) : 0; + if (idx >= nkf) + idx = nkf - 1; + kf = roots[idx]; + *p *= nkf; + dkf = kmag / 200; + df = fabs (-mcvine_evq_f (kf + 2 * dkf, &c) + 8 * mcvine_evq_f (kf + dkf, &c) - 8 * mcvine_evq_f (kf - dkf, &c) + mcvine_evq_f (kf - 2 * dkf, &c)) / 12 / dkf; + if (!(df > 0)) + return 0; + *p *= 2 * MCVINE_KSQ2E * kf / df; + for (i = 0; i < 3; i++) + Q[i] = c.ki[i] - c.ukf[i] * kf; + E = c.Ei - mcvine_k2E (kf); + if (fabs (E - mcvine_func_eval (&k->m_E_Q, Q)) > k->m_Emax * 1e-5) + return 0; + for (i = 0; i < 3; i++) + v[i] = c.ukf[i] * kf * K2V; + *p *= mcvine_func_eval (&k->m_S_Q, Q) * kf / kmag; + return 1; +} + +/* SQkernel.cc : elastic, isotropic S(|Q|) */ +int +mcvine_S_SQ (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_SQ* k = (mcvine_kernel_SQ*)kk; + double vi = mcvine_len3 (v), ki = V2K * vi, kf = ki, Qmin, Qmax, Q, cost, sint, e1[3], e2[3], e3[3], d[3]; + Qmin = k->m_Qmin > 0 ? k->m_Qmin : 0; + Qmax = k->m_Qmax < ki + kf ? k->m_Qmax : ki + kf; + if (Qmax < Qmin) + return 0; + Q = Qmin + (Qmax - Qmin) * rand01 (); + *p *= mcvine_func_eval (&k->m_S, &Q) * Q * (Qmax - Qmin) / (2 * ki * ki); + cost = (kf * kf + ki * ki - Q * Q) / 2 / kf / ki; + if (cost > 1) + cost = 1; + if (cost < -1) + cost = -1; + sint = sqrt (1 - cost * cost); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + v[0] = d[0] * vi; + v[1] = d[1] * vi; + v[2] = d[2] * vi; + return 1; +} + +/* SvQkernel.cc : elastic, S(vector Q) */ +int +mcvine_S_SvQ (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_SvQ* k = (mcvine_kernel_SvQ*)kk; + double vi = mcvine_len3 (v), d[3], Q[3]; + int i; + mcvine_random_direction (d, _particle); + for (i = 0; i < 3; i++) + Q[i] = V2K * (v[i] - d[i] * vi); + *p *= mcvine_func_eval (&k->m_S, Q); + for (i = 0; i < 3; i++) + v[i] = d[i] * vi; + return 1; +} + +/* SQEkernel.cc and SQE_EnergyFocusing_Kernel.cc */ +int +mcvine_S_SQE (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_SQE* k = (mcvine_kernel_SQE*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, ki = V2K * vi, Emin, Emax, E, Ef, kf, Qmin, Qmax, Q, cost, sint, qe[2]; + double e1[3], e2[3], e3[3], d[3]; + if (k->m_Emin > Ei) + return 0; + if (k->m_focusing) { + double Emin1 = Ei - (k->m_Ef + k->m_dEf), Emax1 = Ei - (k->m_Ef - k->m_dEf); + Emin = k->m_Emin > Emin1 ? k->m_Emin : Emin1; + Emax = Emax1 < Ei ? Emax1 : Ei; + if (k->m_Emax < Emax) + Emax = k->m_Emax; + } else { + Emin = k->m_Emin; + Emax = k->m_Emax < Ei ? k->m_Emax : Ei; + } + if (!(Emax > Emin)) + return 0; + E = Emin + (Emax - Emin) * rand01 (); + Ef = Ei - E; + kf = mcvine_E2k (Ef); + Qmin = fabs (ki - kf); + if (k->m_Qmin > Qmin) + Qmin = k->m_Qmin; + Qmax = ki + kf; + if (k->m_Qmax < Qmax) + Qmax = k->m_Qmax; + if (Qmax < Qmin) + return 0; + Q = Qmin + (Qmax - Qmin) * rand01 (); + qe[0] = Q; + qe[1] = E; + *p *= mcvine_func_eval (&k->m_S, qe) * Q * (Qmax - Qmin) * (Emax - Emin) / (2 * ki * ki); + cost = (kf * kf + ki * ki - Q * Q) / 2 / kf / ki; + if (cost > 1) + cost = 1; + if (cost < -1) + cost = -1; + sint = sqrt (1 - cost * cost); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + v[0] = d[0] * kf * K2V; + v[1] = d[1] * kf * K2V; + v[2] = d[2] * kf * K2V; + return 1; +} + +/* DGSSXResKernel.cc : resolution kernel, aim at a target disk and TOF window. + mcvine_DGSSXRes_final: given a unit final direction, the solid angle it was + sampled from and the distance L to the target, set the final velocity. */ +int +mcvine_DGSSXRes_final (const mcvine_kernel_DGSSXRes* k, const double* dir, double solid_angle, double L, double* v, double t, double* p, + _class_particle* _particle) { + double tof, vf, Ef, dEdt, vi = mcvine_len3 (v); + tof = k->m_tof_at_target + (rand01 () - 0.5) * k->m_dtof; + if (tof - t <= 0) + return 0; + vf = L / (tof - t); + Ef = VS2E * vf * vf; + dEdt = 2 * Ef / tof; + *p *= solid_angle / 4 / MCVINE_PI * k->m_dtof * dEdt * vf / vi; + v[0] = dir[0] * vf; + v[1] = dir[1] * vf; + v[2] = dir[2] * vf; + return 1; +} +int +mcvine_S_DGSSXRes (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_DGSSXRes* k = (mcvine_kernel_DGSSXRes*)kk; + double disp[3], d[3], solid_angle = 0, n; + int i; + for (i = 0; i < 3; i++) + disp[i] = k->m_target[i] - r[i]; + randvec_target_circle (&d[0], &d[1], &d[2], &solid_angle, disp[0], disp[1], disp[2], k->m_target_radius); + n = mcvine_len3 (d); + for (i = 0; i < 3; i++) + d[i] /= n; + return mcvine_DGSSXRes_final (k, d, solid_angle, mcvine_len3 (disp), v, t, p, _particle); +} + +/* mcvine/acc kernels/SANS2D_ongrid.py : S(Qx,Qy) on a grid, beam along z */ +int +mcvine_S_SANS2D_ongrid (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_SANS2D_ongrid* k = (mcvine_kernel_SANS2D_ongrid*)kk; + double vi2 = v[0] * v[0] + v[1] * v[1] + v[2] * v[2], Qx, Qy, vz2; + Qx = k->m_Qx_min + (k->m_Qx_max - k->m_Qx_min) * rand01 (); + Qy = k->m_Qy_min + (k->m_Qy_max - k->m_Qy_min) * rand01 (); + v[0] -= K2V * Qx; + v[1] -= K2V * Qy; + vz2 = vi2 - v[0] * v[0] - v[1] * v[1]; + if (vz2 <= 0) + return 0; + v[2] = sqrt (vz2); + *p *= mcvine_grid2d_eval (&k->m_S, Qx, Qy); + return 1; +} + +/* ======================================================================== */ +/* phonon support */ +/* ======================================================================== */ +double +mcvine_bose (double E, double T) { + return 1.0 / (exp (fabs (E) / (T * MCVINE_KELVIN2MEV)) - 1); +} +double +mcvine_phonon_bose_factor (double E, double T) { /* phonon/utils.cc */ + if (E == 0) + return 1; + return (E > 0 ? 1.0 : 0.0) + mcvine_bose (E, T); +} + +/* regression y = c x ; returns R^2 (phonon/utils.py linear_regression) */ +static double +mcvine_linreg0 (const double* x, const double* y, int n, double* c) { + double xy = 0, xx = 0, ys = 0, ave, tot = 0, err = 0; + int i; + for (i = 0; i < n; i++) { + xy += x[i] * y[i]; + xx += x[i] * x[i]; + ys += y[i]; + } + *c = xx > 0 ? xy / xx : 0; + ave = ys / n; + for (i = 0; i < n; i++) { + tot += (y[i] - ave) * (y[i] - ave); + err += (y[i] - *c * x[i]) * (y[i] - *c * x[i]); + } + return tot > 0 ? 1 - err / tot : 1; +} +/* fitparabolic() from phonon/utils.py; returns 0 when fit is bad */ +static int +mcvine_fitparabolic (const double* E, double* g, int n, int force, const char* owner) { + int N = 100, minN = 20, i, bad = 1; + double c = 0, R2, *x; + if (N > n) + N = n; + x = (double*)mcvine_xmalloc (n * sizeof (double)); + for (i = 0; i < n; i++) + x[i] = E[i] * E[i]; + while (N > minN) { + R2 = mcvine_linreg0 (x, g, N, &c); + if (R2 < 0.9) + N--; + else { + bad = 0; + break; + } + } + if (bad) { + if (!force) { + free (x); + return 0; + } + fprintf (stderr, "%s: warning: unable to fit DOS to parabolic (forced)\n", owner); + } + for (i = 0; i < N && i < n; i++) + g[i] = c * x[i]; + free (x); + return 1; +} +/* smooth(x, 21, 'hanning') from phonon/utils.py */ +static void +mcvine_smooth21 (double* x, int n) { + const int w = 21; + int i, m, ns = n + 2 * w - 2; + double *s, *y, win[21], sum = 0; + if (n < w) + return; + s = (double*)mcvine_xmalloc (ns * sizeof (double)); + y = (double*)mcvine_xmalloc (n * sizeof (double)); + for (m = 0; m < w; m++) { + win[m] = 0.5 - 0.5 * cos (2 * MCVINE_PI * m / (w - 1)); + sum += win[m]; + } + for (i = 0; i < w - 1; i++) + s[i] = x[w - 1 - i]; + for (i = 0; i < n; i++) + s[w - 1 + i] = x[i]; + for (i = 0; i < w - 1; i++) + s[w - 1 + n + i] = x[n - 1 - i]; + for (i = 0; i < n; i++) { + double acc = 0; + int j = i + (w / 2 - 1); + for (m = 0; m < w; m++) + acc += win[m] / sum * s[j + m]; + y[i] = acc; + } + memcpy (x, y, n * sizeof (double)); + free (s); + free (y); +} + +static int +mcvine_dos_from_arrays (mcvine_dos* d, const double* E0, const double* g0, int n0, const char* owner) { + int i, n, uniform = 1; + double *E, *g, area = 0, c, R2, x[20], y[20]; + for (i = 2; i < n0; i++) + if (fabs ((E0[i] - E0[i - 1]) - (E0[1] - E0[0])) > 1e-6 * fabs (E0[1] - E0[0]) + 1e-12) + uniform = 0; + if (n0 < 500 || !uniform) { + double dE = E0[n0 - 1] / 500.0; + n = 500; + E = (double*)mcvine_xmalloc (n * sizeof (double)); + g = (double*)mcvine_xmalloc (n * sizeof (double)); + for (i = 0; i < n; i++) { /* np.interp semantics */ + double e = i * dE, f; + int j; + E[i] = e; + if (e <= E0[0]) + g[i] = g0[0]; + else if (e >= E0[n0 - 1]) + g[i] = g0[n0 - 1]; + else { + j = mcvine_bracket (E0, n0, e, &f); + g[i] = g0[j] * (1 - f) + g0[j + 1] * f; + } + } + } else { + n = n0; + E = (double*)mcvine_xmalloc (n * sizeof (double)); + g = (double*)mcvine_xmalloc (n * sizeof (double)); + memcpy (E, E0, n * sizeof (double)); + memcpy (g, g0, n * sizeof (double)); + } + if (!mcvine_fitparabolic (E, g, n, 0, owner)) { + mcvine_smooth21 (g, n); + g[0] = 0; + mcvine_fitparabolic (E, g, n, 1, owner); + } + d->n = n; + d->e0 = E[0]; + d->de = E[1] - E[0]; + d->emax = d->e0 + d->de * (n - 1); + for (i = 0; i < n; i++) + area += g[i]; + area *= d->de; + if (!(area > 0)) { + fprintf (stderr, "%s: DOS has zero area\n", owner); + free (E); + free (g); + return 1; + } + for (i = 0; i < n; i++) + g[i] /= area; + d->Z = g; + free (E); + /* LinearlyInterpolatedDOS::_compute_sod : fit first 20 points to c*E^2 */ + for (i = 0; i < 20 && i < n; i++) { + x[i] = (d->e0 + d->de * i) * (d->e0 + d->de * i); + y[i] = d->Z[i]; + } + R2 = mcvine_linreg0 (x, y, i, &c); + if (R2 < 0.9) + fprintf (stderr, "%s: warning: DOS low-E part is not parabolic (R2=%g)\n", owner, R2); + d->sod = c; + return 0; +} + +static int +mcvine_idf_header (FILE* f, char* filetype, int* D, int* Nb, int* Nq) { + char ft[65], comment[1024]; + int version, v[3]; + if (fread (ft, 1, 64, f) != 64) + return 1; + ft[64] = 0; + if (fread (&version, sizeof (int), 1, f) != 1) + return 1; + if (fread (comment, 1, 1024, f) != 1024) + return 1; + strcpy (filetype, ft); + if (D) { + if (fread (v, sizeof (int), 3, f) != 3) + return 1; + *D = v[0]; + *Nb = v[1]; + *Nq = v[2]; + } + return 0; +} + +int +mcvine_dos_load (mcvine_dos* d, const char* file, int ascii_THz, const char* owner) { + FILE* f = mcvine_fopen (file, "rb"); + char magic[4] = { 0, 0, 0, 0 }; + double *E, *g; + int n, i, ret; + memset (d, 0, sizeof (*d)); + if (!f) { + fprintf (stderr, "%s: cannot open DOS file '%s'\n", owner, file); + return 1; + } + if (fread (magic, 1, 3, f) == 3 && !strncmp (magic, "DOS", 3)) { + char ft[65]; + double dE; + rewind (f); + if (mcvine_idf_header (f, ft, NULL, NULL, NULL) || fread (&n, sizeof (int), 1, f) != 1 || fread (&dE, sizeof (double), 1, f) != 1) { + fprintf (stderr, "%s: corrupt IDF DOS file '%s'\n", owner, file); + fclose (f); + return 1; + } + E = (double*)mcvine_xmalloc (n * sizeof (double)); + g = (double*)mcvine_xmalloc (n * sizeof (double)); + if ((int)fread (g, sizeof (double), n, f) != n) { + fprintf (stderr, "%s: corrupt IDF DOS file '%s'\n", owner, file); + fclose (f); + free (E); + free (g); + return 1; + } + for (i = 0; i < n; i++) + E[i] = i * dE * 2 * MCVINE_PI * 1e12 * MCVINE_HERTZ2MEV; /* THz -> meV */ + fclose (f); + } else { + mcvine_rows r; + int thz = ascii_THz; + char line[4096]; + rewind (f); + while (fgets (line, sizeof (line), f)) + if (line[0] == '#' && (strstr (line, "TeraHz") || strstr (line, "THz"))) + thz = 1; + fclose (f); + if (mcvine_read_rows (file, &r, owner)) + return 1; + E = (double*)mcvine_xmalloc (r.nrows * sizeof (double)); + g = (double*)mcvine_xmalloc (r.nrows * sizeof (double)); + n = 0; + for (i = 0; i < r.nrows; i++) + if (r.ncols[i] >= 2) { + E[n] = r.rows[i][0] * (thz ? 2 * MCVINE_PI * 1e12 * MCVINE_HERTZ2MEV : 1); + g[n] = r.rows[i][1]; + n++; + } + mcvine_free_rows (&r); + } + if (n < 3) { + fprintf (stderr, "%s: DOS '%s' has too few points\n", owner, file); + free (E); + free (g); + return 1; + } + for (i = 1; i < n; i++) + if (E[i] <= E[i - 1]) { + fprintf (stderr, "%s: DOS energies must be ascending\n", owner); + free (E); + free (g); + return 1; + } + if (E[0] < 0) { + fprintf (stderr, "%s: DOS energies must be >= 0\n", owner); + free (E); + free (g); + return 1; + } + ret = mcvine_dos_from_arrays (d, E, g, n, owner); + free (E); + free (g); + return ret; +} + +double +mcvine_dos_value (const mcvine_dos* d, double E) { + double r; + int i; + if (E < d->e0 || E >= d->emax) + return 0; + r = (E - d->e0) / d->de; + i = (int)floor (r); + if (i >= d->n - 1) + i = d->n - 2; + r -= i; + return d->Z[i] * (1 - r) + d->Z[i + 1] * r; +} + +/* phonon/DWFromDOS.icc : 2W = core * Q^2 */ +double +mcvine_dw_core_from_dos (const mcvine_dos* d, double mass, double T, int ns) { + double core = 0, wmin = d->e0, wmax = d->emax, dw = (wmax - wmin) / (ns - 1 + .00000001), *f, f0; + int i, first = -1; + f = (double*)calloc (ns, sizeof (double)); + for (i = 0; i < ns; i++) { + double w = dw * i + wmin, Z = mcvine_dos_value (d, w), frac = 1; + if (w < wmax / ns / 100.) + continue; + if (first == -1) + first = i; + f[i] = (2 * mcvine_bose (w, T) + 1) / w * Z; + if (i == ns - 1) + frac = 0.5; + core += f[i] * frac; + } + if (first < 0 || first + 1 >= ns) { + free (f); + return 0; + } + f0 = f[first] - (dw * first + wmin) * (f[first + 1] - f[first]) / dw; + core += f0 / 2; + free (f); + core /= MCVINE_ECHARGE * 1e-3; + core *= dw; + core *= MCVINE_HBAR * MCVINE_HBAR / 2 / MCVINE_AMU / mass; + core *= 1e20; + return core; +} + +int +mcvine_atoms_load (mcvine_atom** atoms, const char* file, const char* owner) { + mcvine_rows r; + int i, n = 0; + if (mcvine_read_rows (file, &r, owner)) + return -1; + *atoms = (mcvine_atom*)calloc (r.nrows, sizeof (mcvine_atom)); + for (i = 0; i < r.nrows; i++) { + mcvine_atom* a; + if (r.ncols[i] < 7) { + fprintf (stderr, "%s: atoms file '%s' row %d: need x y z mass b_coh sigma_inc sigma_abs\n", owner, file, i + 1); + mcvine_free_rows (&r); + return -1; + } + a = &(*atoms)[n++]; + a->pos[0] = r.rows[i][0]; + a->pos[1] = r.rows[i][1]; + a->pos[2] = r.rows[i][2]; + a->mass = r.rows[i][3]; + a->b_coh = r.rows[i][4]; + a->xs_inc = r.rows[i][5]; + a->xs_abs = r.rows[i][6]; + a->xs_coh = 4 * MCVINE_PI * a->b_coh * a->b_coh / 100.0; /* fm^2 -> barn */ + } + mcvine_free_rows (&r); + return n; +} + +/* ---- IDF dispersion ---- */ +static int +mcvine_parse_qgridinfo (mcvine_dispersion* d, const char* path, const char* owner) { + FILE* f = mcvine_fopen (path, "r"); + char line[4096]; + int got = 0; + if (!f) { + fprintf (stderr, "%s: cannot open '%s'\n", owner, path); + return 1; + } + while (fgets (line, sizeof (line), f)) { + char *eq = strchr (line, '='), name[16] = { 0 }, *s, *q; + int ni = 0; + if (!eq || line[0] == '#') + continue; + for (s = line; s < eq && ni < 15; s++) + if (*s != ' ' && *s != '\t') + name[ni++] = *s; + /* strip python decorations: array(, numpy., np., brackets */ + for (s = eq + 1; *s; s++) + if (*s == '[' || *s == ']' || *s == '\n' || *s == '\r') + *s = ' '; + while ((q = strstr (eq + 1, "numpy.array"))) + memset (q, ' ', 11); + while ((q = strstr (eq + 1, "np.array"))) + memset (q, ' ', 8); + while ((q = strstr (eq + 1, "array"))) + memset (q, ' ', 5); + while ((q = strstr (eq + 1, "numpy.float64"))) + memset (q, ' ', 13); + while ((q = strstr (eq + 1, "np.float64"))) + memset (q, ' ', 10); + while ((q = strstr (eq + 1, "float"))) + memset (q, ' ', 5); + if (name[0] == 'b' && name[1] >= '1' && name[1] <= '3' && !name[2]) { + int idx = name[1] - '1', c = 0; + char buf[4096]; + strncpy (buf, eq + 1, sizeof (buf) - 1); + buf[sizeof (buf) - 1] = 0; + /* split on commas at parenthesis depth 0; if there is a single + parenthesised token, e.g. "(x, y, z)", unwrap it and split again */ + { + int pass; + for (pass = 0; pass < 2; pass++) { + char* parts[3]; + int np_ = 0, depth = 0; + char* start = buf; + for (s = buf;; s++) { + if (*s == '(') + depth++; + else if (*s == ')') + depth--; + if ((*s == ',' && depth == 0) || *s == 0) { + int end = (*s == 0); + *s = 0; + if (np_ < 3) + parts[np_] = start; + np_++; + start = s + 1; + if (end) + break; + } + } + if (np_ == 1 && pass == 0) { + char *a0 = parts[0], *z; + while (*a0 == ' ') + a0++; + z = a0 + strlen (a0) - 1; + while (z > a0 && *z == ' ') + z--; + if (*a0 == '(' && *z == ')') { + *a0 = ' '; + *z = 0; + memmove (buf, a0, strlen (a0) + 1); + continue; + } + } + for (c = 0; c < np_ && c < 3; c++) { + mcvine_expr ex; + if (mcvine_expr_compile (&ex, parts[c], 0, NULL, owner)) { + fclose (f); + return 1; + } + d->b[idx][c] = mcvine_expr_eval (&ex, NULL); + mcvine_expr_free (&ex); + } + if (np_ != 3) + c = np_; + break; + } + } + if (c != 3) { + fprintf (stderr, "%s: '%s': %s needs 3 components\n", owner, path, name); + fclose (f); + return 1; + } + got |= 1 << idx; + } else if (name[0] == 'n' && name[1] >= '1' && name[1] <= '3' && !name[2]) { + mcvine_expr ex; + if (mcvine_expr_compile (&ex, eq + 1, 0, NULL, owner)) { + fclose (f); + return 1; + } + d->n[name[1] - '1'] = (int)(mcvine_expr_eval (&ex, NULL) + 0.5); + mcvine_expr_free (&ex); + got |= 8 << (name[1] - '1'); + } + } + fclose (f); + if (got != 63) { + fprintf (stderr, "%s: '%s' must define b1,b2,b3,n1,n2,n3\n", owner, path); + return 1; + } + return 0; +} + +static void +mcvine_inv3 (double m[3][3], double inv[3][3]) { + double det = m[0][0] * (m[1][1] * m[2][2] - m[1][2] * m[2][1]) - m[0][1] * (m[1][0] * m[2][2] - m[1][2] * m[2][0]) + + m[0][2] * (m[1][0] * m[2][1] - m[1][1] * m[2][0]); + inv[0][0] = (m[1][1] * m[2][2] - m[1][2] * m[2][1]) / det; + inv[0][1] = -(m[0][1] * m[2][2] - m[0][2] * m[2][1]) / det; + inv[0][2] = (m[0][1] * m[1][2] - m[0][2] * m[1][1]) / det; + inv[1][0] = -(m[1][0] * m[2][2] - m[1][2] * m[2][0]) / det; + inv[1][1] = (m[0][0] * m[2][2] - m[0][2] * m[2][0]) / det; + inv[1][2] = -(m[0][0] * m[1][2] - m[0][2] * m[1][0]) / det; + inv[2][0] = (m[1][0] * m[2][1] - m[1][1] * m[2][0]) / det; + inv[2][1] = -(m[0][0] * m[2][1] - m[0][1] * m[2][0]) / det; + inv[2][2] = (m[0][0] * m[1][1] - m[0][1] * m[1][0]) / det; +} + +int +mcvine_dispersion_load_idf (mcvine_dispersion* d, const char* dir, const char* owner) { + char path[4096], ft[65]; + FILE* f; + int D, Nb, Nq, Nq2, D2, Nb2, i, br, nq, nbr; + double inv[3][3], det; + size_t neps; + memset (d, 0, sizeof (*d)); + snprintf (path, sizeof (path), "%s/Qgridinfo", dir); + if (mcvine_parse_qgridinfo (d, path, owner)) + return 1; + mcvine_inv3 (d->b, inv); + for (i = 0; i < 3; i++) { + d->a[i][0] = inv[0][i]; + d->a[i][1] = inv[1][i]; + d->a[i][2] = inv[2][i]; + } + det = d->b[0][0] * (d->b[1][1] * d->b[2][2] - d->b[1][2] * d->b[2][1]) - d->b[0][1] * (d->b[1][0] * d->b[2][2] - d->b[1][2] * d->b[2][0]) + + d->b[0][2] * (d->b[1][0] * d->b[2][1] - d->b[1][1] * d->b[2][0]); + d->ucvol = pow (2 * MCVINE_PI, 3) / fabs (det); + /* Omega2 */ + snprintf (path, sizeof (path), "%s/Omega2", dir); + f = mcvine_fopen (path, "rb"); + if (!f || mcvine_idf_header (f, ft, &D, &Nb, &Nq) || strncmp (ft, "Omega2", 6)) { + fprintf (stderr, "%s: cannot read IDF '%s'\n", owner, path); + if (f) + fclose (f); + return 1; + } + nq = d->n[0] * d->n[1] * d->n[2]; + if (D != 3 || Nq != nq) { + fprintf (stderr, "%s: '%s': D=%d, N_q=%d but Qgridinfo gives %d points\n", owner, path, D, Nq, nq); + fclose (f); + return 1; + } + d->natoms = Nb; + d->nbranches = nbr = Nb * D; + d->E = (double*)mcvine_xmalloc ((size_t)nq * nbr * sizeof (double)); + if (fread (d->E, sizeof (double), (size_t)nq * nbr, f) != (size_t)nq * nbr) { + fprintf (stderr, "%s: '%s' truncated\n", owner, path); + fclose (f); + return 1; + } + fclose (f); + for (i = 0; i < nq * nbr; i++) + d->E[i] = sqrt (d->E[i] > 0 ? d->E[i] : 0) * MCVINE_HERTZ2MEV; + /* Polarizations */ + snprintf (path, sizeof (path), "%s/Polarizations", dir); + f = mcvine_fopen (path, "rb"); + if (!f || mcvine_idf_header (f, ft, &D2, &Nb2, &Nq2)) { + fprintf (stderr, "%s: cannot read IDF '%s'\n", owner, path); + if (f) + fclose (f); + return 1; + } + if (D2 != D || Nb2 != Nb || Nq2 != Nq) { + fprintf (stderr, "%s: '%s' shape does not match Omega2\n", owner, path); + fclose (f); + return 1; + } + neps = (size_t)nq * nbr * Nb * 3 * 2; + d->eps = (double*)mcvine_xmalloc (neps * sizeof (double)); + if (fread (d->eps, sizeof (double), neps, f) != neps) { + fprintf (stderr, "%s: '%s' truncated\n", owner, path); + fclose (f); + return 1; + } + fclose (f); + d->Emin = (double*)mcvine_xmalloc (nbr * sizeof (double)); + d->Emax = (double*)mcvine_xmalloc (nbr * sizeof (double)); + for (br = 0; br < nbr; br++) { + d->Emin[br] = 1e300; + d->Emax[br] = -1e300; + for (i = 0; i < nq; i++) { + double e = d->E[i * nbr + br]; + if (e < d->Emin[br]) + d->Emin[br] = e; + if (e > d->Emax[br]) + d->Emax[br] = e; + } + } + /* optional DOS */ + snprintf (path, sizeof (path), "%s/DOS", dir); + f = mcvine_fopen (path, "rb"); + if (f) { + fclose (f); + d->has_dos = !mcvine_dos_load (&d->m_dos, path, 1, owner); + } + return 0; +} + +/* fractional (reduced) coordinates of Q in the grid cell, then trilinear weights */ +static void +mcvine_disp_locate (const mcvine_dispersion* d, const double* Q, int* id, double* fr) { + int i; + for (i = 0; i < 3; i++) { + double c = d->a[i][0] * Q[0] + d->a[i][1] * Q[1] + d->a[i][2] * Q[2], r; + c -= floor (c); + r = c * (d->n[i] - 1); + id[i] = (int)floor (r); + if (id[i] >= d->n[i] - 1) + id[i] = d->n[i] - 2; + if (id[i] < 0) + id[i] = 0; + fr[i] = r - id[i]; + } +} +static double +mcvine_trilin (const double* f, const int* id, const double* fr, int n1, int n2, size_t stride, size_t off) { + double s = 0; + int a, b, c; + for (a = 0; a < 2; a++) + for (b = 0; b < 2; b++) + for (c = 0; c < 2; c++) { + double w = (a ? fr[0] : 1 - fr[0]) * (b ? fr[1] : 1 - fr[1]) * (c ? fr[2] : 1 - fr[2]); + if (w != 0) + s += w * f[((size_t)((id[0] + a) * n1 + id[1] + b) * n2 + id[2] + c) * stride + off]; + } + return s; +} +double +mcvine_dispersion_energy (const mcvine_dispersion* d, int branch, const double* Q) { + int id[3]; + double fr[3]; + mcvine_disp_locate (d, Q, id, fr); + return mcvine_trilin (d->E, id, fr, d->n[1], d->n[2], d->nbranches, branch); +} +void +mcvine_dispersion_polarization (const mcvine_dispersion* d, int branch, int atom, const double* Q, double* re, double* im) { + int id[3], c; + double fr[3]; + size_t stride = (size_t)d->nbranches * d->natoms * 6; + mcvine_disp_locate (d, Q, id, fr); + for (c = 0; c < 3; c++) { + size_t off = ((size_t)branch * d->natoms + atom) * 6 + c * 2; + re[c] = mcvine_trilin (d->eps, id, fr, d->n[1], d->n[2], stride, off); + im[c] = mcvine_trilin (d->eps, id, fr, d->n[1], d->n[2], stride, off + 1); + } +} + +/* phonon/scattering_length.icc : |sum_i b_i/sqrt(M_i) exp(iQ.d_i) (Q.eps_i)/|eps_i| |^2 */ +static double +mcvine_norm_slsum (const mcvine_dispersion* d, const mcvine_atom* atoms, int natoms, int branch, const double* Q) { + double sr = 0, si = 0; + int i; + for (i = 0; i < natoms; i++) { + double er[3], ei[3], epslen, qer, qei, qd, c, s, amp; + mcvine_dispersion_polarization (d, branch, i, Q, er, ei); + epslen = sqrt (er[0] * er[0] + er[1] * er[1] + er[2] * er[2] + ei[0] * ei[0] + ei[1] * ei[1] + ei[2] * ei[2]); + if (!(epslen > 0)) + continue; + qer = (Q[0] * er[0] + Q[1] * er[1] + Q[2] * er[2]) / epslen; + qei = (Q[0] * ei[0] + Q[1] * ei[1] + Q[2] * ei[2]) / epslen; + qd = Q[0] * atoms[i].pos[0] + Q[1] * atoms[i].pos[1] + Q[2] * atoms[i].pos[2]; + c = cos (qd); + s = sin (qd); + amp = atoms[i].b_coh / sqrt (atoms[i].mass); + sr += amp * (c * qer - s * qei); + si += amp * (c * qei + s * qer); + } + return sr * sr + si * si; +} + +/* ---- phonon kernels ---- */ +/* phonon/IncoherentElastic.cc */ +int +mcvine_S_Phonon_IncoherentElastic (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_Phonon_IncoherentElastic* k = (mcvine_kernel_Phonon_IncoherentElastic*)kk; + double vi = mcvine_len3 (v), theta = MCVINE_PI * rand01 (), phi = 2 * MCVINE_PI * rand01 (), Q, e1[3], e2[3], e3[3], d[3]; + Q = V2K * vi * 2 * sin (theta / 2); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cos (theta), sin (theta), phi, d); + v[0] = d[0] * vi; + v[1] = d[1] * vi; + v[2] = d[2] * vi; + *p *= sin (theta) * (MCVINE_PI / 2) * exp (-k->m_dw_core * Q * Q); + return 1; +} + +/* phonon/IncoherentInelastic.cc and IncoherentInelastic_EnergyFocusing.cc */ +int +mcvine_S_Phonon_IncoherentInelastic (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_Phonon_IncoherentInelastic* k = (mcvine_kernel_Phonon_IncoherentInelastic*)kk; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Ef, e_range, omega, vf, d[3], Q[3], Ql, beta, DW, EQ; + int i, is_small; + mcvine_random_direction (d, _particle); + if (k->m_focusing) { + double Efmax = k->m_Ef + k->m_dEf / 2.; + if (Ei - Efmax > k->m_max_omega || Ei - Efmax < 0) + return 0; + Ef = k->m_Ef + (rand01 () - 0.5) * k->m_dEf; + e_range = k->m_dEf; + if (Ef < 0) + return 0; + } else if (Ei > k->m_max_omega) { + e_range = 2 * k->m_max_omega; + Ef = Ei - k->m_max_omega + rand01 () * e_range; + } else { + e_range = Ei + k->m_max_omega; + Ef = rand01 () * e_range; + } + omega = Ei - Ef; + is_small = fabs (omega) < 1e-2 * k->m_max_omega; + vf = SE2V * sqrt (Ef); + for (i = 0; i < 3; i++) { + Q[i] = V2K * (v[i] - vf * d[i]); + v[i] = vf * d[i]; + } + Ql = mcvine_len3 (Q); + beta = 1. / (k->m_T * MCVINE_KELVIN2MEV); + DW = exp (-k->m_dw_core * Ql * Ql); + EQ = mcvine_k2E (Ql); + *p *= e_range / k->m_mass * (vf / vi) * DW; + if (is_small) + *p *= k->m_dos.sod / beta * EQ; + else + *p *= mcvine_phonon_bose_factor (omega, k->m_T) * mcvine_dos_value (&k->m_dos, fabs (omega)) * EQ / fabs (omega); + return 1; +} + +/* phonon/CoherentInelastic_PolyXtal.cc */ +int +mcvine_S_Phonon_CoherentInelastic_PolyXtal (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_Phonon_CoherentInelastic_PolyXtal* k = (mcvine_kernel_Phonon_CoherentInelastic_PolyXtal*)kk; + const mcvine_dispersion* D = k->m_disp; + double vi = mcvine_len3 (v), Ei = VS2E * vi * vi, Qmax, Q[3], vQ = 0, omega = 0, Ef = 0, vf = 0, Ql, ki, kf, cost, sint; + double e1[3], e2[3], e3[3], d[3], q, x, Q1, vol, norm, dE; + int branch, iter, ok = 0, i; + branch = (int)floor (rand01 () * D->nbranches); + if (branch >= D->nbranches) + branch = D->nbranches - 1; + *p *= D->nbranches; + Qmax = mcvine_E2k (Ei) + mcvine_E2k (Ei + k->m_max_omega); + /* pick_a_valid_Q_vector: MCViNE rejects until valid and uses an empirical + accessible reciprocal volume; m_unbiased=1: one cube sample, weight + uses the cube volume (2 Qmax)^3 exactly. */ + for (iter = 0; iter < (k->m_unbiased ? 1 : 100000); iter++) { + for (i = 0; i < 3; i++) + Q[i] = (2 * rand01 () - 1) * Qmax; + vQ = K2V * mcvine_len3 (Q); + omega = mcvine_dispersion_energy (D, branch, Q); + if (omega < k->m_min_omega) + continue; + if (omega < Ei) + Ef = (rand01 () >= 0.5) ? Ei + omega : Ei - omega; /* pick_Ef */ + else + Ef = Ei + omega; + vf = SE2V * sqrt (Ef); + if (vQ >= fabs (vi - vf) && vQ <= vi + vf) { + ok = 1; + break; + } + } + if (!ok) + return 0; + cost = (vi * vi + vf * vf - vQ * vQ) / (2 * vi * vf); + if (cost * cost > 1) + cost = cost > 0 ? 1 : -1; + sint = sqrt (1 - cost * cost); + mcvine_frame (v, e1, e2, e3); + mcvine_dir_from_frame (e1, e2, e3, cost, sint, 2 * MCVINE_PI * rand01 (), d); + for (i = 0; i < 3; i++) + v[i] = d[i] * vf; + ki = V2K * vi; + kf = V2K * vf; + Ql = V2K * vQ; + dE = Ei - Ef; + if (Ei > omega) + *p *= 2.0; /* two choices of E_f (see README: uses phonon energy) */ + norm = mcvine_norm_slsum (D, k->m_atoms, k->m_natoms, branch, Q); + norm *= 1e-30 * 4 * MCVINE_PI; + norm /= (k->m_xs_coh_tot * 1e-28); + *p *= MCVINE_KSQ2E * norm; + *p /= fabs (dE); + *p *= exp (-k->m_dw_core * Ql * Ql); + *p *= kf / ki; + *p *= mcvine_phonon_bose_factor (dE, k->m_T); + *p *= 1 / ki / kf / Ql; + q = mcvine_E2k (k->m_max_omega); + x = ki / q; /* calc_AccessibleReciVol */ + Q1 = ki + mcvine_E2k (Ei + k->m_max_omega / (1 + 7.6 * pow (x, 4))); + vol = k->m_unbiased ? 8 * Qmax * Qmax * Qmax : 4. / 3. * MCVINE_PI * Q1 * Q1 * Q1; + *p *= vol; + *p /= 8 * MCVINE_PI; + return 1; +} + +/* phonon/CoherentInelastic_SingleXtal.cc */ +typedef struct { + const mcvine_dispersion* D; + int branch; + double dir[3], vi[3], vil; +} mcvine_omq_ctx; +static double +mcvine_omq_f (double vf, void* c) { /* Omega_minus_deltaE.cc */ + mcvine_omq_ctx* x = (mcvine_omq_ctx*)c; + double q[3]; + int i; + for (i = 0; i < 3; i++) + q[i] = V2K * (x->vi[i] - vf * x->dir[i]); + return mcvine_dispersion_energy (x->D, x->branch, q) - VS2E * fabs (x->vil * x->vil - vf * vf); +} +int +mcvine_S_Phonon_CoherentInelastic_SingleXtal (void* kk, const double* r, double* v, double t, double* p, _class_particle* _particle) { + mcvine_kernel_Phonon_CoherentInelastic_SingleXtal* k = (mcvine_kernel_Phonon_CoherentInelastic_SingleXtal*)kk; + const mcvine_dispersion* D = k->m_disp; + mcvine_omq_ctx c; + double vil = mcvine_len3 (v), Ei = VS2E * vil * vil, roots[256], solid = 4 * MCVINE_PI, vf = 0, fac = 1; + int good[1024], ngood = 0, br, iter, nf = 0, i; + for (br = 0; br < D->nbranches && ngood < 1024; br++) + if (D->Emin[br] < Ei * 1.5) + good[ngood++] = br; + if (!ngood) + return 0; + c.D = D; + c.vil = vil; + for (i = 0; i < 3; i++) + c.vi[i] = v[i]; + /* MCViNE retries (up to 100 directions/branches) until omega(Q)=|Ei-Ef| has + a solution, without correcting the weight for the success probability: + absolute intensities come out too high by 1/P(success). m_unbiased=1 + makes a single attempt (unbiased; failed attempts get weight 0). */ + for (iter = 0; iter < (k->m_unbiased ? 1 : 100); iter++) { + if (k->m_target_radius > 0) { + double tx = k->m_target[0] - r[0], ty = k->m_target[1] - r[1], tz = k->m_target[2] - r[2], n; + randvec_target_circle (&c.dir[0], &c.dir[1], &c.dir[2], &solid, tx, ty, tz, k->m_target_radius); + n = mcvine_len3 (c.dir); + for (i = 0; i < 3; i++) + c.dir[i] /= n; + } else { + mcvine_random_direction (c.dir, _particle); + solid = 4 * MCVINE_PI; + } + i = (int)floor (rand01 () * ngood); + if (i >= ngood) + i = ngood - 1; + c.branch = good[i]; + nf = mcvine_find_roots (mcvine_omq_f, &c, 0, 2 * vil, k->m_nsteps, k->m_xacc, roots, 256); + if (nf > 0) + break; + } + if (nf < 1) + return 0; + { + double dv = k->m_deltaV_Jacobi * vil, f1, f2, J, Ef, omega, Q[3], ki, kf, norm; + int idx; + idx = (int)floor (rand01 () * nf); + if (idx >= nf) + idx = nf - 1; + vf = roots[idx]; + fac *= nf; + f1 = mcvine_omq_f (vf - dv, &c); + f2 = mcvine_omq_f (vf + dv, &c); + J = fabs (f2 - f1) / (2 * dv); + if (!(J > 0)) + return 0; + fac *= 2 * VS2E * vf / J; + fac *= solid; + fac *= ngood; + Ef = VS2E * vf * vf; + omega = Ei - Ef; + for (i = 0; i < 3; i++) + Q[i] = V2K * (v[i] - vf * c.dir[i]); + ki = V2K * vil; + kf = V2K * vf; + norm = mcvine_norm_slsum (D, k->m_atoms, k->m_natoms, c.branch, Q); + norm /= 1e30; + norm /= (k->m_xs_coh_tot * 1e-28); + fac *= MCVINE_KSQ2E * norm / fabs (omega); + fac *= kf / ki; + fac *= exp (-k->m_dw_core * (Q[0] * Q[0] + Q[1] * Q[1] + Q[2] * Q[2])); + fac *= mcvine_phonon_bose_factor (omega, k->m_T); + *p *= fac; + for (i = 0; i < 3; i++) + v[i] = c.dir[i] * vf; + } + return 1; +} + +#endif /* MCVINE_LIB_C */ diff --git a/mcstas-comps/share/mcvine-lib.h b/mcstas-comps/share/mcvine-lib.h new file mode 100644 index 0000000000..531e70edf1 --- /dev/null +++ b/mcstas-comps/share/mcvine-lib.h @@ -0,0 +1,315 @@ +/******************************************************************************* + * + * mcvine-lib.h : shared runtime for the MCViNE scattering kernels ported to + * McStas 3.x components (MCViNE_*.comp). + * + * Contents + * - constants (MCViNE values where the kernels depend on them) + * - a small run-time expression evaluator (replaces MCViNE's fparser, so + * E(Q), S(Q), S(Q,E), sigma(Q) ... can be given as strings) + * - numeric text-file readers and 1D/2D/3D interpolated grids + * - sample shapes (box / cylinder / hollow cylinder / sphere) + * - the MCViNE "HomogeneousNeutronScatterer" transport (single + optional + * multiple scattering, uniform-depth sampling, attenuation) + * - kernel data structures and S() functions, one per MCViNE kernel + * - phonon helpers: DOS (nice_dos), Debye-Waller from DOS, IDF readers, + * periodic linearly-interpolated dispersion on grid + * + * Use in a component SHARE block: %include "mcvine-lib" + * Keep mcvine-lib.h and mcvine-lib.c next to the .comp files (or pass -I). + * + * Source of the physics: https://github.com/mcvine/mcvine (mccomponents/lib/ + * kernels/sample) and https://github.com/mcvine/acc (SANS2D_ongrid). + * + *******************************************************************************/ +#ifndef MCVINE_LIB_H +#define MCVINE_LIB_H + +#include +#include +#include +#include + +#define MCVINE_PI 3.14159265358979323846 + +/* MCViNE physical constants (mccomponents/physics/constants.h) */ +#define MCVINE_HBAR 1.05457148e-34 +#define MCVINE_AMU 1.66053886e-27 +#define MCVINE_ECHARGE 1.60217653e-19 +#define MCVINE_KELVIN2MEV (1.0 / 11.605) +#define MCVINE_HERTZ2MEV (1.05457148e-34 / 1.60217653e-22) +/* k^2 [AA^-2] -> E [meV] ( = K2V*K2V*VS2E ) */ +#define MCVINE_KSQ2E (K2V * K2V * VS2E) + +/* ------------------------------------------------------------------------ */ +/* expression evaluator */ +/* ------------------------------------------------------------------------ */ +#define MCVINE_EXPR_MAXVARS 8 +#define MCVINE_EXPR_MAXSTACK 128 +typedef struct { + int n, cap; + int* op; + double* val; + char text[1024]; +} mcvine_expr; + +/* compile 'src' using variables varnames[0..nvars-1]. returns 0 on success */ +int mcvine_expr_compile (mcvine_expr* e, const char* src, int nvars, const char** varnames, const char* owner); +double mcvine_expr_eval (const mcvine_expr* e, const double* vars); +void mcvine_expr_free (mcvine_expr* e); + +/* ------------------------------------------------------------------------ */ +/* files, tables and grids */ +/* ------------------------------------------------------------------------ */ +typedef struct { + int nrows; + int* ncols; + double** rows; +} mcvine_rows; + +FILE* mcvine_fopen (const char* name, const char* mode); +int mcvine_read_rows (const char* file, mcvine_rows* r, const char* owner); +void mcvine_free_rows (mcvine_rows* r); + +/* 1D table y(x), x ascending, linear interpolation, 0 outside */ +typedef struct { + int n; + double *x, *y; +} mcvine_table1d; +int mcvine_table1d_load (mcvine_table1d* t, const char* file, const char* owner); +double mcvine_table1d_eval (const mcvine_table1d* t, double x); + +/* 2D grid f(x,y) on (possibly non-uniform) ascending axes, bilinear, 0 outside */ +typedef struct { + int nx, ny; + double *x, *y, *f; +} mcvine_grid2d; +double mcvine_grid2d_eval (const mcvine_grid2d* g, double x, double y); +/* S(Q,E) in the Isotropic_Sqw format: 1st numeric row = q values, + 2nd numeric row = w (E) values, then nq rows with nw values each */ +int mcvine_grid2d_load_sqw (mcvine_grid2d* g, const char* file, const char* owner); +/* image format: 1st row x axis values, 2nd row y axis values, + then ny rows with nx values each (row index = y) */ +int mcvine_grid2d_load_image (mcvine_grid2d* g, const char* file, const char* owner); + +/* 3D grid on uniform axes (point values, trilinear, 0 outside): + rows 1-3 : "min max n" for x, y, z; then nx*ny rows of nz values + (x slowest, z fastest) */ +typedef struct { + int n[3]; + double min[3], max[3], step[3]; + double* f; +} mcvine_grid3d; +int mcvine_grid3d_load (mcvine_grid3d* g, const char* file, const char* owner); +double mcvine_grid3d_eval (const mcvine_grid3d* g, double x, double y, double z); + +/* a scalar function of 1..3 variables given either as expression or file */ +typedef struct { + int mode; /* 0 const, 1 expression, 2 table1d, 3 grid2d, 4 grid3d */ + double c; + mcvine_expr expr; + mcvine_table1d t1; + mcvine_grid2d g2; + mcvine_grid3d g3; +} mcvine_func; +double mcvine_func_eval (const mcvine_func* f, const double* v); +/* set up from a file (if file non-empty; filetype 2=table1d, 3=sqw grid, + 4=grid3d) or else from an expression in the variables vars[] */ +int mcvine_func_setup (mcvine_func* f, const char* expr, const char* file, int filetype, int nvars, const char** vars, const char* owner); + +/* ------------------------------------------------------------------------ */ +/* vector helpers */ +/* ------------------------------------------------------------------------ */ +double mcvine_len3 (const double* a); +void mcvine_cross3 (const double* a, const double* b, double* c); +/* MCViNE local frame: e1 = v/|v|, e2 = (0,0,1) x e1 (or fallback), e3 = e1 x e2 */ +void mcvine_frame (const double* v, double* e1, double* e2, double* e3); +/* dir = sin(t)cos(phi) e2 + sin(t) sin(phi) e3 + cos(t) e1 */ +void mcvine_dir_from_frame (const double* e1, const double* e2, const double* e3, double cost, double sint, double phi, double* dir); + +/* ------------------------------------------------------------------------ */ +/* shapes and transport */ +/* ------------------------------------------------------------------------ */ +#define MCVINE_SHAPE_BOX 1 +#define MCVINE_SHAPE_CYLINDER 2 +#define MCVINE_SHAPE_SPHERE 3 +typedef struct { + int type; + double xwidth, yheight, zdepth, radius, thickness; +} mcvine_shape; + +int mcvine_shape_init (mcvine_shape* s, double radius, double xwidth, double yheight, double zdepth, double thickness, const char* owner); +/* time intervals [seg[2i], seg[2i+1]] (t>=0) spent inside the material */ +int mcvine_shape_segments (const mcvine_shape* s, double x, double y, double z, double vx, double vy, double vz, double* seg); + +/* kernel S function: modifies v (and may read r, t); multiplies *p by the + kernel weight; returns 1 on success, 0 if no scattering is possible. */ +typedef int (*mcvine_S_fn) (void* kernel, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_shape shape; + double mu2200; /* absorption coefficient at 2200 m/s [1/m] */ + double sigma; /* scattering coefficient [1/m] */ + double pack; /* packing factor */ + double p_transmit; /* MC fraction of unscattered (transmitted) events */ + int order; /* max scattering order (1 = single scattering) */ +} mcvine_scatterer; + +void mcvine_scatterer_init (mcvine_scatterer* sc, const mcvine_shape* s, double mu2200, double sigma, double pack, double p_transmit, int order); +/* returns -1: event must be absorbed; 0: missed/transmitted; n>0: scattered n times */ +int mcvine_scatterer_interact (const mcvine_scatterer* sc, void* kernel, mcvine_S_fn S, _class_particle* _particle); + +/* cross section helper: barn / AA^3 -> 1/m */ +double mcvine_xs2coeff (double xs_barn, double V_AA3); + +/* ------------------------------------------------------------------------ */ +/* kernels (one struct + one S function per MCViNE kernel) */ +/* ------------------------------------------------------------------------ */ +typedef struct { + double m_E; +} mcvine_kernel_ConstantEnergyTransfer; +int mcvine_S_ConstantEnergyTransfer (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + double m_Q, m_E; +} mcvine_kernel_ConstantQE; +int mcvine_S_ConstantQE (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + double m_Q[3], m_E, m_dE; +} mcvine_kernel_ConstantvQE; +int mcvine_S_ConstantvQE (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_E_Q, m_S_Q; + double m_Qmin, m_Qmax; + int m_unbiased; +} mcvine_kernel_E_Q; +int mcvine_S_E_Q (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_E_Q, m_S_Q, m_W_Q; + double m_Qmin, m_Qmax, m_Emin, m_Emax; + int m_lorentzian, m_unbiased; +} mcvine_kernel_Broadened_E_Q; +void mcvine_Broadened_E_Q_init (mcvine_kernel_Broadened_E_Q* k); +int mcvine_S_Broadened_E_Q (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_E_Q, m_S_Q; + double m_Emax; + int m_nsteps; + double m_xacc; +} mcvine_kernel_E_vQ; +int mcvine_S_E_vQ (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_S; + double m_Qmin, m_Qmax; +} mcvine_kernel_SQ; +int mcvine_S_SQ (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_S; +} mcvine_kernel_SvQ; +int mcvine_S_SvQ (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_func m_S; + double m_Qmin, m_Qmax, m_Emin, m_Emax, m_Ef, m_dEf; + int m_focusing; +} mcvine_kernel_SQE; +int mcvine_S_SQE (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + double m_target[3], m_target_radius, m_tof_at_target, m_dtof; +} mcvine_kernel_DGSSXRes; +int mcvine_DGSSXRes_final (const mcvine_kernel_DGSSXRes* k, const double* dir, double solid_angle, double L, double* v, double t, double* p, + _class_particle* _particle); +int mcvine_S_DGSSXRes (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_grid2d m_S; + double m_Qx_min, m_Qx_max, m_Qy_min, m_Qy_max; +} mcvine_kernel_SANS2D_ongrid; +int mcvine_S_SANS2D_ongrid (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +/* ---- phonon support ---- */ +typedef struct { + int n; + double e0, de, emax; + double* Z; + double sod; +} mcvine_dos; +/* reads 2-column ASCII (E[meV] g(E)) or IDF binary DOS (THz); applies + MCViNE's nice_dos() (resample >=500 pts, parabolic low-E, normalize) */ +int mcvine_dos_load (mcvine_dos* d, const char* file, int ascii_THz, const char* owner); +double mcvine_dos_value (const mcvine_dos* d, double E); +/* Debye-Waller core (2W = core*Q^2, AA^2) from DOS, MCViNE DWFromDOS */ +double mcvine_dw_core_from_dos (const mcvine_dos* d, double mass_amu, double T, int nsample); +double mcvine_bose (double E, double T); /* 1/(exp(|E|/kT)-1) */ +double mcvine_phonon_bose_factor (double E, double T); /* n+1 (E>0), n (E<0) */ + +typedef struct { + double pos[3]; + double mass; + double b_coh; + double xs_coh, xs_inc, xs_abs; +} mcvine_atom; +/* atoms file: columns x y z [AA, cartesian] mass[amu] b_coh[fm] sigma_inc[barn] sigma_abs[barn] */ +int mcvine_atoms_load (mcvine_atom** atoms, const char* file, const char* owner); + +typedef struct { + int natoms, nbranches; + int n[3]; + double b[3][3]; /* reciprocal basis vectors b1,b2,b3 (rows) [AA^-1] */ + double a[3][3]; /* dual vectors: a_i . b_j = delta_ij */ + double* E; /* [n1][n2][n3][nbr] */ + double* eps; /* [n1][n2][n3][nbr][natoms][3][2] */ + double *Emin, *Emax; /* per branch */ + double ucvol; /* (2 pi)^3/|b1.(b2 x b3)| [AA^3] */ + mcvine_dos m_dos; + int has_dos; +} mcvine_dispersion; +/* read an MCViNE IDF phonon directory: Qgridinfo, Omega2, Polarizations, DOS */ +int mcvine_dispersion_load_idf (mcvine_dispersion* d, const char* dir, const char* owner); +double mcvine_dispersion_energy (const mcvine_dispersion* d, int branch, const double* Q); +void mcvine_dispersion_polarization (const mcvine_dispersion* d, int branch, int atom, const double* Q, double* re, double* im); + +typedef struct { + double m_dw_core; +} mcvine_kernel_Phonon_IncoherentElastic; +int mcvine_S_Phonon_IncoherentElastic (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_dos m_dos; + double m_dw_core; + double m_T, m_mass; + double m_max_omega; + int m_focusing; + double m_Ef, m_dEf; +} mcvine_kernel_Phonon_IncoherentInelastic; +int mcvine_S_Phonon_IncoherentInelastic (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_dispersion* m_disp; + mcvine_atom* m_atoms; + int m_natoms; + double m_dw_core, m_T, m_max_omega, m_min_omega, m_xs_coh_tot; + int m_unbiased; +} mcvine_kernel_Phonon_CoherentInelastic_PolyXtal; +int mcvine_S_Phonon_CoherentInelastic_PolyXtal (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +typedef struct { + mcvine_dispersion* m_disp; + mcvine_atom* m_atoms; + int m_natoms; + double m_dw_core, m_T, m_xs_coh_tot, m_deltaV_Jacobi; + double m_target[3], m_target_radius; /* target_radius<=0: 4pi */ + int m_nsteps; + double m_xacc; + int m_unbiased; +} mcvine_kernel_Phonon_CoherentInelastic_SingleXtal; +int mcvine_S_Phonon_CoherentInelastic_SingleXtal (void* k, const double* r, double* v, double t, double* p, _class_particle* _particle); + +#endif /* MCVINE_LIB_H */ diff --git a/mcstas-comps/share/mcvine-union-lib.c b/mcstas-comps/share/mcvine-union-lib.c new file mode 100644 index 0000000000..05191a5d40 --- /dev/null +++ b/mcstas-comps/share/mcvine-union-lib.c @@ -0,0 +1,65 @@ +/******************************************************************************* + * mcvine-union-lib.c : implementation of mcvine-union-lib.h + *******************************************************************************/ +#ifndef MCVINE_UNION_LIB_C +#define MCVINE_UNION_LIB_C +#ifndef MCVINE_UNION_LIB_H + #include "mcvine-union-lib.h" +#endif + +int +MCViNE_physics_my (double* my, double* k_initial, union data_transfer_union data_transfer, struct focus_data_struct* focus_data, _class_particle* _particle) { + *my = data_transfer.pointer_to_a_MCViNE_physics_storage_struct->m_my_scattering; + return 1; +} + +int +MCViNE_physics_scattering (double* k_final, double* k_initial, double* weight, union data_transfer_union data_transfer, struct focus_data_struct* focus_data, + _class_particle* _particle) { + struct MCViNE_physics_storage_struct* st = data_transfer.pointer_to_a_MCViNE_physics_storage_struct; + double v[3], r[3] = { 0, 0, 0 }; + int ok, i; + for (i = 0; i < 3; i++) + v[i] = k_initial[i] * K2V; + if (st->m_kind == MCVINE_UNION_DGSSXRES) { + /* aim with the Union focusing set on the geometry (target_index, focus_r, ...) */ + Coords k_out; + double solid_angle = 0, d[3], n, L; + L = sqrt (focus_data->RayAim.x * focus_data->RayAim.x + focus_data->RayAim.y * focus_data->RayAim.y + focus_data->RayAim.z * focus_data->RayAim.z); + if (!(L > 0)) + return 0; + focus_data->focusing_function (&k_out, &solid_angle, focus_data); + n = sqrt (k_out.x * k_out.x + k_out.y * k_out.y + k_out.z * k_out.z); + d[0] = k_out.x / n; + d[1] = k_out.y / n; + d[2] = k_out.z / n; + ok = mcvine_DGSSXRes_final ((mcvine_kernel_DGSSXRes*)st->m_kernel, d, solid_angle, L, v, _particle->t, weight, _particle); + } else { + ok = st->m_S (st->m_kernel, r, v, _particle->t, weight, _particle); + } + if (!ok || !(*weight > 0) || v[0] != v[0] || v[1] != v[1] || v[2] != v[2]) + return 0; + for (i = 0; i < 3; i++) + k_final[i] = v[i] * V2K; + return 1; +} + +void +mcvine_union_register (struct scattering_process_struct* proc, struct global_process_element_struct* elem, struct MCViNE_physics_storage_struct* storage, + const char* name, int comp_index, double interact_fraction, int anisotropic, Rotation rot) { + scattering_process_struct_init (proc); + proc->non_isotropic_rot_index = anisotropic ? 1 : -1; + proc->needs_cross_section_focus = -1; + proc->eProcess = MCViNE; + sprintf (proc->name, "%s", name); + proc->process_p_interact = interact_fraction; + proc->data_transfer.pointer_to_a_MCViNE_physics_storage_struct = storage; + proc->probability_for_scattering_function = &MCViNE_physics_my; + proc->scattering_function = &MCViNE_physics_scattering; + rot_copy (proc->rotation_matrix, rot); + sprintf (elem->name, "%s", name); + elem->component_index = comp_index; + elem->p_scattering_process = proc; + add_element_to_process_list (&g_process_list, *elem); +} +#endif diff --git a/mcstas-comps/share/mcvine-union-lib.h b/mcstas-comps/share/mcvine-union-lib.h new file mode 100644 index 0000000000..49439a4a45 --- /dev/null +++ b/mcstas-comps/share/mcvine-union-lib.h @@ -0,0 +1,32 @@ +/******************************************************************************* + * + * mcvine-union-lib.h : glue between the MCViNE kernels (mcvine-lib) and the + * McStas Union framework. Used by the MCViNE_*_process.comp components. + * + * Requires the Union core to know the process type "MCViNE": the enum entry + * MCViNE in enum process, the member pointer_to_a_MCViNE_physics_storage_struct + * in union data_transfer_union (share/union-lib.c) and the MCViNE cases in + * physics_my / physics_scattering (share/union-suffix.c). + * + *******************************************************************************/ +#ifndef MCVINE_UNION_LIB_H +#define MCVINE_UNION_LIB_H + +#define MCVINE_UNION_GENERIC 0 /* kernel samples its own final state */ +#define MCVINE_UNION_DGSSXRES 1 /* final direction from Union focusing */ + +struct MCViNE_physics_storage_struct { + void* m_kernel; /* pointer to an mcvine_kernel_* struct */ + mcvine_S_fn m_S; /* its S() function */ + double m_my_scattering; /* scattering inverse penetration depth [1/m] */ + int m_kind; /* MCVINE_UNION_* */ +}; + +int MCViNE_physics_my (double* my, double* k_initial, union data_transfer_union data_transfer, struct focus_data_struct* focus_data, + _class_particle* _particle); +int MCViNE_physics_scattering (double* k_final, double* k_initial, double* weight, union data_transfer_union data_transfer, + struct focus_data_struct* focus_data, _class_particle* _particle); +/* fill a Union scattering_process_struct for an MCViNE kernel */ +void mcvine_union_register (struct scattering_process_struct* proc, struct global_process_element_struct* elem, struct MCViNE_physics_storage_struct* storage, + const char* name, int comp_index, double interact_fraction, int anisotropic, Rotation rot); +#endif diff --git a/mcstas-comps/share/union-lib.c b/mcstas-comps/share/union-lib.c index 2e8758361f..660f66aa5f 100755 --- a/mcstas-comps/share/union-lib.c +++ b/mcstas-comps/share/union-lib.c @@ -40,6 +40,7 @@ enum process { IncoherentPhonon, NCrystal, Non, + MCViNE, Template }; @@ -501,6 +502,7 @@ union data_transfer_union{ struct Texture_physics_storage_struct *pointer_to_a_Texture_physics_storage_struct; struct NCrystal_physics_storage_struct *pointer_to_a_NCrystal_physics_storage_struct; struct Non_physics_storage_struct *pointer_to_a_Non_physics_storage_struct; + struct MCViNE_physics_storage_struct *pointer_to_a_MCViNE_physics_storage_struct; struct Template_physics_storage_struct *pointer_to_a_Template_physics_storage_struct; // possible to add as many structs as wanted, without increasing memory footprint. }; diff --git a/mcstas-comps/share/union-suffix.c b/mcstas-comps/share/union-suffix.c index 93fee01643..dae6b38ea2 100644 --- a/mcstas-comps/share/union-suffix.c +++ b/mcstas-comps/share/union-suffix.c @@ -66,6 +66,11 @@ int physics_my(enum process choice, double *my,double *k_initial, union data_tra output = Non_physics_my(my, k_initial, data_transfer, focus_data, _particle); break; #endif + #ifdef PROCESS_MCVINE_DETECTOR + case MCViNE: + output = MCViNE_physics_my(my, k_initial, data_transfer, focus_data, _particle); + break; + #endif #ifdef PROCESS_TEMPLATE_DETECTOR case Template: output = Template_physics_my(my, k_initial, data_transfer, focus_data, _particle); @@ -135,6 +140,11 @@ int physics_scattering(enum process choice, double *k_final, double *k_initial, output = Non_physics_scattering(k_final, k_initial, weight, data_transfer, focus_data, _particle); break; #endif + #ifdef PROCESS_MCVINE_DETECTOR + case MCViNE: + output = MCViNE_physics_scattering(k_final, k_initial, weight, data_transfer, focus_data, _particle); + break; + #endif #ifdef PROCESS_TEMPLATE_DETECTOR case Template: output = Template_physics_scattering(k_final, k_initial, weight, data_transfer, focus_data, _particle);