Merge branch '5-bug-cannot-implement-own-distributions' into 'main'
Resolve "Bug: Cannot implement own distributions" Closes #5 See merge request open-source/dotnet/FastRng!3
This commit is contained in:
commit
fc8e666680
@ -16,7 +16,7 @@ public abstract class Distribution<TNum> : IDistribution<TNum> where TNum : IFlo
|
|||||||
this.fitter = new ShapeFitter<TNum>(this.ShapeFunction, rng, 100);
|
this.fitter = new ShapeFitter<TNum>(this.ShapeFunction, rng, 100);
|
||||||
}
|
}
|
||||||
|
|
||||||
private protected abstract TNum ShapeFunction(TNum x);
|
public abstract TNum ShapeFunction(TNum x);
|
||||||
|
|
||||||
public TNum GetDistributedValue(CancellationToken token = default) => this.fitter.NextNumber(token);
|
public TNum GetDistributedValue(CancellationToken token = default) => this.fitter.NextNumber(token);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user