算額(その979)
一七 大里郡岡部村岡 稲荷社 文化13年(1816)
埼玉県立図書館:埼玉県史料集 第二集『埼玉の算額』,昭和44年,誠美堂印刷所,埼玉県与野市.
外円内に水平な弦を引き,その上に甲円,乙円,丙円が入っている。甲円の直径は外円の直径の半分である。甲円の直径が 2 寸のとき,丙円の直径はいかほどか。
外円の半径と中心座標を R, (0, 0)
甲円の半径と中心座標を r1, (0, R - r1)
乙円の半径と中心座標を r2, (x2, r2 - 2r3)
丙円の半径と中心座標を r3, (0, -r3)
とおき,以下の連立方程式を解く。
include("julia-source.txt");
using SymPy
@syms R::positive, r1::positive,
r2::positive, x2::positive, r3::positive
R = 2r1
eq1 = x2^2 + (R - r1 - r2 + 2r3)^2 - (r1 + r2)^2
eq2 = x2^2 + (r2 - r3)^2 - (r2 + r3)^2
eq3 = x2^2 + (r2 - 2r3)^2 - (R - r2)^2
res = solve([eq1, eq2, eq3], (r3, r2, x2))[1]
(r1/2, 3*r1/4, sqrt(6)*r1/2)
丙円の半径 r3 は甲円の半径 r1の 1/2 である。
甲円の直径が 2 寸のとき,丙円の直径は 1 寸である。
その他のパラメータは以下のとおりである。
R = 2; r1 = 1; r2 = 0.75; x2 = 1.22474; r3 = 0.5
function draw(more=false)
pyplot(size=(500, 500), grid=false, aspectratio=1, label="", fontfamily="IPAMincho")
r1 = 2/2
(r3, r2, x2) = (r1/2, 3*r1/4, sqrt(6)*r1/2)
R = 2r1
@printf("甲円の直径が %g のとき,丙円の直径は %g である。\n", 2r1, 2r3)
@printf("R = %g; r1 = %g; r2 = %g; x2 = %g; r3 = %g\n", R, r1, r2, x2, r3)
plot()
circle(0, 0, R)
circle(0, R - r1, r1, :magenta)
circle2(x2, r2 - 2r3, r2, :green)
circle(0, -r3, r3, :blue)
y = -2r3
x = sqrt(R^2 - y^2)
segment(-x, y, x, y, :black)
if more
delta = (fontheight = (ylims()[2]- ylims()[1]) / 500 * 10 * 2) /3 # size[2] * fontsize * 2
hline!([0], color=:gray80, lw=0.5)
vline!([0], color=:gray80, lw=0.5)
point(0, R, " R", :red, :left, :bottom, delta=delta/2)
point(0, R - r1, "甲円:r1,(0,R-r1)", :magenta, :center, delta=-delta/2)
point(x2, r2 - 2r3, "乙円:r2,(x2,r2-2r3)", :green, :center, delta=-delta/2)
point(0, -r3, "丙円:r3,(0,-r3)", :blue, :center, delta=-delta/2)
end
end;