SCAD (5 lines)
// 50mm 角の立方体の中央に、直径20mmの貫通穴をz軸方向に開ける
difference() {
cube([50, 50, 50], center=true);
cylinder(d=20, h=100, center=true, $fn=100);
} gpt-5.4-nano-2026-03-17 7 run / 累計 10.9s / 累計 $0.0015
difference() {
cube([50, 50, 50], center=true);
cylinder(h=60, d=20, center=true, $fn=100);
} OpenSCAD で、50mm 角の立方体の中央に、直径 20mm の貫通穴を z 軸方向に開けたモデルを作成してください。 完成したコード全体を ```openscad ... ``` のフェンスで囲んで出力してください。コードのみで、追加の説明は不要です。
effort
// 50mm 角の立方体の中央に、直径20mmの貫通穴をz軸方向に開ける
difference() {
cube([50, 50, 50], center=true);
cylinder(d=20, h=100, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=60, d=20, center=true, $fn=100);
}
// 50mm cube with a through hole (diameter 20mm) along Z axis
difference() {
cube([50, 50, 50], center=true);
cylinder(h=60, d=20, center=true, $fn=100);
} iter-png
difference() {
cube([50, 50, 50], center=true);
- cylinder(h=60, d=20, center=true, $fn=100);
+ cylinder(h=50.1, d=20, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=50.1, d=20, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=50.1, d=20, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=50.1, d=20, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=50.1, d=20, center=true, $fn=100);
}
difference() {
cube([50, 50, 50], center=true);
cylinder(h=50.1, d=20, center=true, $fn=100);
}