本文整理汇总了C#中ConwayMaxwellPoisson类的典型用法代码示例。如果您正苦于以下问题:C# ConwayMaxwellPoisson类的具体用法?C# ConwayMaxwellPoisson怎么用?C# ConwayMaxwellPoisson使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ConwayMaxwellPoisson类属于命名空间,在下文中一共展示了ConwayMaxwellPoisson类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: ValidateMean
public void ValidateMean(
[Values(1, 2, 10, 20, 1, 2)] int lambda,
[Values(1, 1, 1, 1, 2, 2)] int nu,
[Values(1.0, 2.0, 10.0, 20.0, 0.697774657964008, 1.12635723962342)] double mean)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
AssertHelpers.AlmostEqual(mean, d.Mean, 10);
}
开发者ID:jvangael,项目名称:mathnet-numerics,代码行数:8,代码来源:ConwayMaxwellPoissonTests.cs
示例2: CanSampleSequence
public void CanSampleSequence()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var ied = d.Samples();
ied.Take(5).ToArray();
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:6,代码来源:ConwayMaxwellPoissonTests.cs
示例3: CanCreateConwayMaxwellPoisson
public void CanCreateConwayMaxwellPoisson(double lambda, double nu)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
Assert.AreEqual(lambda, d.Lambda);
Assert.AreEqual(nu, d.Nu);
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:6,代码来源:ConwayMaxwellPoissonTests.cs
示例4: ValidateMinimum
public void ValidateMinimum()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.AreEqual(0.0, d.Minimum);
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例5: ValidateProbabilityLn
public void ValidateProbabilityLn(double lambda, double nu, int x, double pln)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
AssertHelpers.AlmostEqualRelative(pln, d.ProbabilityLn(x), 12);
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例6: SetNuFails
public void SetNuFails(double nu)
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.Throws<ArgumentOutOfRangeException>(() => d.Nu = nu);
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例7: ValidateSkewnessThrowsNotSupportedException
public void ValidateSkewnessThrowsNotSupportedException()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.Throws<NotSupportedException>(() => { var s = d.Skewness; });
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例8: ValidateMaximum
public void ValidateMaximum()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var max = d.Maximum;
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例9: ValidateMedian
public void ValidateMedian()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var m = d.Median;
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例10: ConwayMaxwellPoissonCreateFailsWithBadParameters
public void ConwayMaxwellPoissonCreateFailsWithBadParameters(double lambda, double nu)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:4,代码来源:ConwayMaxwellPoissonTests.cs
示例11: ValidateEntropy
public void ValidateEntropy()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var e = d.Entropy;
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例12: CanCreateConwayMaxwellPoisson
public void CanCreateConwayMaxwellPoisson([Values(0.1, 1.0, 2.5, 10.0, Double.PositiveInfinity)] double lambda, [Values(0.0, 2.5, Double.PositiveInfinity)] double nu)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
Assert.AreEqual(lambda, d.Lambda);
Assert.AreEqual(nu, d.Nu);
}
开发者ID:jvangael,项目名称:mathnet-numerics,代码行数:6,代码来源:ConwayMaxwellPoissonTests.cs
示例13: ValidateProbabilityLn
public void ValidateProbabilityLn(
[Values(1.0, 1.0, 2.0, 2.0, 2.0, 2.0)] double lambda,
[Values(1.0, 1.0, 1.0, 1.0, 2.0, 2.0)] double nu,
[Values(1, 2, 1, 2, 1, 3)] int x,
[Values(-1.0, -1.69314718055995, -1.30685281944005, -1.30685281944005, -0.754324797564617, -2.95154937490084)] double pln)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
AssertHelpers.AlmostEqual(pln, d.ProbabilityLn(x), 13);
}
开发者ID:jvangael,项目名称:mathnet-numerics,代码行数:9,代码来源:ConwayMaxwellPoissonTests.cs
示例14: ValidateProbability
public void ValidateProbability(
[Values(1.0, 1.0, 2.0, 2.0, 2.0, 2.0)] double lambda,
[Values(1.0, 1.0, 1.0, 1.0, 2.0, 2.0)] double nu,
[Values(1, 2, 1, 2, 1, 3)] int x,
[Values(0.367879441171442, 0.183939720585721, 0.270670566473225, 0.270670566473225, 0.470328074204904, 0.052258674911656)] double p)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
AssertHelpers.AlmostEqual(p, d.Probability(x), 13);
}
开发者ID:jvangael,项目名称:mathnet-numerics,代码行数:9,代码来源:ConwayMaxwellPoissonTests.cs
示例15: SetNuFails
public void SetNuFails(double nu)
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.That(() => d.Nu = nu, Throws.ArgumentException);
}
开发者ID:kityandhero,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例16: ValidateMode
public void ValidateMode()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var m = d.Mode;
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例17: SetLambdaFails
public void SetLambdaFails(double lambda)
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.Throws<ArgumentOutOfRangeException>(() => d.Lambda = lambda);
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例18: ValidateProbability
public void ValidateProbability(double lambda, double nu, int x, double p)
{
var d = new ConwayMaxwellPoisson(lambda, nu);
AssertHelpers.AlmostEqual(p, d.Probability(x), 13);
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例19: ValidateEntropyThrowsNotSupportedException
public void ValidateEntropyThrowsNotSupportedException()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
Assert.Throws<NotSupportedException>(() => { var e = d.Entropy; });
}
开发者ID:EricGT,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
示例20: ValidateSkewness
public void ValidateSkewness()
{
var d = new ConwayMaxwellPoisson(1.0, 2.0);
var s = d.Skewness;
}
开发者ID:xmap2008,项目名称:mathnet-numerics,代码行数:5,代码来源:ConwayMaxwellPoissonTests.cs
注:本文中的ConwayMaxwellPoisson类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论