03015 岩手県一関市釣山 八幡神社 天保9年(1838)
今有如図
https://w.atwiki.jp/sangaku/pages/199.html
岩手県一関市 八幡神社 天保9年(1838)
和算の館
http://www.wasan.jp/iwate/itinosekiyahata2.html
キーワード:円10個,外円
#Julia #SymPy #算額 #和算 #数学
円の中に 4 種類の円が収まっている。各円の径を求めよ。

include("julia-source.txt"); # julia-source.txt ソース
using SymPy
@syms r1::positive, r2::positive, r3::positive, r4::positive, x4::positive;
eq1 = x4^2 + r4^2 - (r3 + r4)^2;
eq2 = x4^2 + (r4 - r1 - r3)^2 - (r1 + r4)^2;
eq3 = r3 + 2r1 + 2r2 - 1;
eq4 = 1 - 2r4 - r3;
eq5 = r2 - r3;
solve([eq1, eq2, eq3, eq4, eq5], (r1, r2, r3, r4, x4))[1]
(1/8, 1/4, 1/4, 3/8, 1/2)
描画関数プログラムのソースを見る
function draw(more=false)
pyplot(size=(500, 500), grid=false, aspectratio=1, label="", fontfamily="IPAMincho")
r1, r2, r3, r4, x4 = (1/8, 1/4, 1/4, 3/8, 1/2)
plot()
circle(0, 0, r3, :green)
circle22(0, r1+r3, r1, :blue)
circle22(0, r3 + 2r1 + r2, r2, :red)
circle4(x4, r4, r4, :magenta)
if more
point(0, 0, "0 ", :black, :right)
point(0, r3, "r3 ", :black, :right)
point(0, r3+r1, "r3+r1 ", :blue, :right)
point(0, 1-r2, "1-r2 ", :red, :right)
point(x4, r4, "(x4,r4)", :magenta, :center)
vline!([0], color=:black, linewidth=0.25)
hline!([0], color=:black, linewidth=0.25)
end
circle(0, 0, 1, :black)
end;
以下のアイコンをクリックして応援してください