Skip to content

Commit 1056fb2

Browse files
committed
fix: quantile pade
1 parent 6b90ffb commit 1056fb2

File tree

5 files changed

+4699
-4863
lines changed

5 files changed

+4699
-4863
lines changed

LandauEvalPadeApprox/EvalPDF.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
namespace LandauEvalPadeApprox {
55
class EvalPDF {
6-
static void Main() {
6+
static void Main_() {
77
List<double> xs = [];
88

99
for (double x = 0; x < 1; x += 1d / 4096) {

LandauEvalPadeApprox/EvalQuantile.cs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
namespace LandauEvalPadeApprox {
55
class EvalQuantile {
6-
static void Main_() {
6+
static void Main() {
77
{
88
List<MultiPrecision<Pow2.N16>> ps = [];
99

@@ -21,10 +21,7 @@ static void Main_() {
2121
for (int exp = -16384; exp > -262144; exp -= 4) {
2222
ps.Add(MultiPrecision<Pow2.N16>.Ldexp(1, exp));
2323
}
24-
for (int exp = -262144; exp > -4194304; exp -= 16) {
25-
ps.Add(MultiPrecision<Pow2.N16>.Ldexp(1, exp));
26-
}
27-
for (int exp = -4194304; exp >= -16777216; exp -= 64) {
24+
for (int exp = -262144; exp >= -1048576; exp -= 16) {
2825
ps.Add(MultiPrecision<Pow2.N16>.Ldexp(1, exp));
2926
}
3027

@@ -51,7 +48,7 @@ static void Main_() {
5148

5249
int exp0 = -1;
5350
for (int h = 16384; h >= 1; exp0 *= 2, h /= 2) {
54-
for (int exp = exp0; exp > exp0 * 2 && exp >= -400; exp--) {
51+
for (int exp = exp0; exp > exp0 * 2 && exp >= -600; exp--) {
5552
for (double v = 1; v > 0.5; v -= 1d / h) {
5653
ps.Add(MultiPrecision<Pow2.N16>.Ldexp(v, exp));
5754
}

LandauEvalPadeApprox/ExpectedQuantilePlusLimitN16.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
namespace LandauEvalPadeApprox {
77
internal class ExpectedQuantilePlusLimitN16 {
8-
static void Main() {
8+
static void Main_() {
99
using (StreamWriter sw = new("../../../../results_disused/quantile_upper_precision152_limit_scaled.csv")) {
1010
sw.WriteLine("u:=-log2(p),v:=cquantile(p)*p");
1111

0 commit comments

Comments
 (0)