歯車について勉強する3 の履歴(No.5)
更新- 履歴一覧
- 差分 を表示
- 現在との差分 を表示
- ソース を表示
- 工作/歯車について勉強する3 へ行く。
目次†
歯車を描く†
LANG: p5js_live
内歯車について:
- インボリュート曲線部分のみで歯形としているため歯数の少ない場合に歯底円まで届かない
- フィレットは付けていない
はすば歯車設計(転位係数を指定)†
KHK 小原歯車工業さんの 歯車技術資料 にある、
https://www.khkgears.co.jp/gear_technology/pdf/gijutu.pdf#page=23 の計算を行う
LANG:p5js_live const { tan, cos, sin, PI, atan, abs} = Math; const definitions = [ ["mn", "歯垂直モジュール", "m_n", "", [3], 1], ["alphan", "歯直角圧力角", "\\alpha_n", "", [20], PI / 180], ["beta", "基準円筒ねじれ角", "\\beta", "", [30], PI / 180], ["z", "歯数", "z", "", [12, 60], 1], ["xn", "歯直角転位係数", "x_n", "", [0.09809, 0], 1], [ "alphat", "正面圧力角", "\\alpha_t", "\\tan^{-1}\\Big(\\frac{\\tan\\alpha_n}{\\cos\\beta}\\Big)", ["?"], PI / 180, ], [ "invawt", "インボリュートαwt", "\\mathrm{inv}\\,\\alpha_{wt}", "2\\tan\\alpha_n\\big(\\frac{x_{n1}+x_{n2}}{z_1+z_2}\\big)+\\mathrm{inv}\\,\\alpha_t", ["?"], 1, ], [ "alphawt", "正面噛み合い圧力角", "\\alpha_{wt}", "\\mathrm{inv}^{-1}\\,(\\mathrm{inv}\\,\\alpha_{wt})", ["?"], PI / 180, ], [ "y", "中心距離修正係数", "y", "\\frac{z_1+z_2}{2\\cos\\beta}\\Big(\\frac{\\cos\\alpha_t}{\\cos\\alpha_{wt}}-1\\Big)", ["?"], 1, ], [ "a", "中心距離", "a", "\\Big(\\frac{z_1+z_2}{2\\cos\\beta}+y\\Big)m_n", ["?"], 1, ], [ "d", "基準円直径","d","\\frac{zm_n}{\\cos\\beta}", ["?","?"],1 ], [ "db", "基礎円直径","d_b","d\\cos\\alpha_t",["?","?"],1 ], [ "dw","噛合ピッチ円直径", "d_w","\\frac{d_b}{\\cos\\alpha_{wt}}",["?","?"],1 ], [ "ha", "歯末の丈","h_a","\\begin{aligned}h_{a1}=(1+y-x_{n2})m_n\\\\h_{a2}=(1+y-x_{n1})m_n\\end{aligned}",["?","?"],1 ], [ "h", "歯丈","h","\\{2.25+y-(x_{n1}+x_{n2})\\}m_n",["?"],1 ], [ "da", "歯先円直径", "d_a", "d+2h_a", ["?","?"],1 ], [ "df", "歯底円直径", "d_f", "d_a-2h", ["?","?"],1 ], ]; let controls = {}; function elem(tag, html = "", children = []) { const result = document.createElement(tag); if (html != "") result.innerHTML = html; children.forEach((c) => result.appendChild(c)); return result; } function inv(x) { return tan(x) - x; } function inverse_inv(inva) { if (inva == 0) return 0; if (inva < 0 || 20 < inva) return nan; let a = inva < 2.4 ? 1.441 * inva ** (1 / 3) - 0.374 * inva : 1.48; let a_prev = 2; for (;;) { const tana = tan(a); a += (inva - tana + a) / tana ** 2; if (abs(a_prev - a) < 1e-15) return a; a_prev = a; } } function recalc() { const c = controls; c.alphat = atan(tan(c.alphan) / cos(c.beta)); c.invawt = (2 * tan(c.alphan) * (c.xn1 + c.xn2)) / (c.z1 + c.z2) + inv(c.alphat); c.alphawt = inverse_inv(c.invawt); c.y = ((c.z1 + c.z2) / (2 * cos(c.beta))) * (cos(c.alphat) / cos(c.alphawt) - 1); c.a = ((c.z1 + c.z2) / (2 * cos(c.beta)) + c.y) * c.mn; c.d1=c.z1*c.mn/cos(c.beta); c.d2=c.z2*c.mn/cos(c.beta); c.db1=c.d1*cos(c.alphat); c.db2=c.d2*cos(c.alphat); c.dw1=c.db1/cos(c.alphawt) c.dw2=c.db2/cos(c.alphawt) c.ha1=(1+c.y-c.xn2)*c.mn; c.ha2=(1+c.y-c.xn1)*c.mn; c.h=(2.25+c.y-(c.xn1+c.xn2))*c.mn; c.da1=c.d1+2*c.ha1; c.da2=c.d2+2*c.ha2; c.df1=c.da1-2*c.h; c.df2=c.da2-2*c.h; } function setup() { p ? p.createCanvas(1, 1) : createCanvas(1, 1); let table = elem("TABLE", "", [ elem( "TR", "", ["項目名", "記号", "計算式", "歯車1", "歯車2"].map((s) => elem("TH", s)) ), ...definitions.map((def) => { const [name, label, notation, expression, values, scale] = def; const control = (n, v) => { let e; if (expression != "") { e = elem("SPAN", v); controls.__defineGetter__(name + n, () => e.innerHTML * scale); controls.__defineSetter__(name + n, (v) => (e.innerHTML = (v / scale).toPrecision(6))); } else { e = elem("INPUT"); e.value = v; e.style.textAlign = "right"; e.style.paddingRight = "0.2em"; e.style.width = "7em"; e.addEventListener("change", recalc); controls.__defineGetter__(name + n, () => e.value * scale); controls.__defineSetter__(name + n, (v) => (e.value = v / scale)); } return e; }; const values2controls = () => { if (values.length == 1) { const e = elem("TD", "", [control("", values[0])]); e.colSpan = 2; e.style.textAlign = "center"; return [e]; } else { return [ elem("TD", "", [control("1", values[0])]), elem("TD", "", [control("2", values[1])]), ]; } }; const tr = elem("TR", "", [ elem("TD", label), elem("TD", katex.renderToString(notation, { throwOnError: false })), elem("TD", expression != "" ? katex.renderToString(expression, { throwOnError: false }) : ''), ...values2controls(), ]); if (expression != "") { tr.style.backgroundColor = "#ffe"; }else{ tr.style.backgroundColor = "#eff"; } return tr; }), ]); table.border = 1; table.cellSpacing = 0; table.cellPadding = 2; (p ? p.createDiv() : createDiv()).elt.appendChild(table); recalc(); } if (p) { p.setup = setup; }
はすば歯車設計(中心間距離を指定)†
KHK 小原歯車工業さんの 歯車技術資料 にある、
https://www.khkgears.co.jp/gear_technology/pdf/gijutu.pdf#page=24 の計算を行う
(未稿)
ウォームギア設計†
LANG:p5js_live function input(i, label, value, func) { p.createSpan(label).position(0, 20 * i + 10); myInput = p.createInput(value).position(150, 20 * i + 10); if (func) { myInput.input(func); } else { myInput.elt.disabled = true; } return myInput; } const inputs = {}; function recalc() { inputs.beta.value(Math.asin(inputs.n.value() * inputs.m.value() / inputs.dp.value())/Math.PI*180) inputs.pitch.value(inputs.m.value() * Math.PI); inputs.mn.value( inputs.m.value() / Math.cos((inputs.beta.value() / 180) * Math.PI) ); inputs.pitchn.value( Math.PI * inputs.mn.value() ); inputs.vdp.value( inputs.dp.value()/Math.sin(inputs.beta.value()/180*Math.PI) ) } p.setup = () => { p.createCanvas(300,240) inputs.m = input(1, "歯直角モジュール", 4, recalc); inputs.dp = input(2, "基準円直径", 30, recalc); inputs.n = input(3, "条数", 1, recalc); inputs.pitch = input(5, "歯直角ピッチ", 0); inputs.beta = input(6, "ねじれ角", 0); inputs.mn = input(7, "正面モジュール", 4); inputs.pitchn = input(8, "正面ピッチ", 0); inputs.vdp = input(9, "仮想基準円直径", 0) recalc(); }
逆インボリュート計算機†
LANG: p5js_live p.setup = () => { p.createCanvas(1,1); p.createSpan('inv(a): '); const invAlpha = p.createInput(); invAlpha.value(0.1); const answer = p.createDiv(); const handler = () => { const inva = Number(invAlpha.value()); let a = 1.441 * inva ** (1/3) - 0.374*inva; if (inva>2) a = 1.48; let str = ''; for (let i = 0; i < 10; i++) { str += ` ${i} : ${a}<br/>`; const tana = Math.tan(a); a += (inva - tana + a) / tana ** 2; } str += `<br>inv(${a}) = ${Math.tan(a) - a}`; answer.html(str); } handler(); invAlpha.input(handler); }
Counter: 260 (from 2010/06/03),
today: 2,
yesterday: 1