示例#1
0
        public static UnnormalizedDiscrete operator ^(UnnormalizedDiscrete dist, double exponent)
        {
            UnnormalizedDiscrete result = UnnormalizedDiscrete.Uniform(dist.Dimension);

            result.SetToPower(dist, exponent);
            return(result);
        }
示例#2
0
        /// <summary>
        /// Creates an unnormalized discrete distribution which is the ratio of two unnormalized discrete distributions
        /// </summary>
        /// <param name="a">The first distribution</param>
        /// <param name="b">The second distribution</param>
        /// <returns>The resulting unnormalized discrete distribution</returns>
        public static UnnormalizedDiscrete operator /(UnnormalizedDiscrete a, UnnormalizedDiscrete b)
        {
            UnnormalizedDiscrete result = UnnormalizedDiscrete.Uniform(a.Dimension);

            result.SetToRatio(a, b);
            return(result);
        }