diff options
author | Elena of Valhalla'' Grandi <valhalla@trueelena.org> | 2014-06-29 09:06:42 +0200 |
---|---|---|
committer | Elena of Valhalla'' Grandi <valhalla@trueelena.org> | 2014-06-29 10:50:51 +0200 |
commit | e43199f64993a61830710f0dbad7ad688754dbe7 (patch) | |
tree | 0dde4d20e0ceb68980e87b49d18fce10749e37ec | |
parent | 6e4f99f514806fccef1e7073080e4f769011d8be (diff) |
Improved scaling factors
-rw-r--r-- | lib/utils.scad | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/lib/utils.scad b/lib/utils.scad index 6241712..07eb11e 100644 --- a/lib/utils.scad +++ b/lib/utils.scad @@ -1,13 +1,27 @@ + +// constant circumscribed sphere function circ_rad(size) = size * sqrt(3) / 2; -function s2s_d4(size) = circ_rad(size)*4/sqrt(6); +//function s2s_d4(size) = circ_rad(size)*4/sqrt(6); +//function s2s_d6(size) = size; +//function s2s_d8(size) = circ_rad(size)*2/sqrt(2); +//function s2s_d12(size) = circ_rad(size)*4/(sqrt(3)*(1+sqrt(5))); +//function s2s_d20(size) = circ_rad(size)*4/(sqrt(10+2*sqrt(5))); -function s2s_d6(size) = size; +// measured on existing dice (14 mm) -function s2s_d8(size) = circ_rad(size)*2/sqrt(2); +function s2s_d4(size) = size * 1.57; +function s2s_d6(size) = size; +function s2s_d8(size) = size * 1.21; +function s2s_d12(size) = size * 0.86; +function s2s_d20(size) = size * 0.86; -function s2s_d12(size) = circ_rad(size)*4/(sqrt(3)*(1+sqrt(5))); +// measured on existing dice (averaged between sizes) -function s2s_d20(size) = circ_rad(size)*4/(sqrt(10+2*sqrt(5))); +//function s2s_d4(size) = size * 1.40; +//function s2s_d6(size) = size; +//function s2s_d8(size) = size * 1.16; +//function s2s_d12(size) = size * 0.81; +//function s2s_d20(size) = size * 0.78; |