| | @@ -1,18 +1,61 @@ |
| 1 | | -"""Tapered roller bearing, 302 and 303 series, bore up to 50 mm: envelope for assemblies. The cone (inner ring side) of width B and the cup |
| 2 | | -(outer ring side) of width C share the overall width T: drawn as one solid ring d x D x T. Rollers and cage are not modelled. Axis along Z, centred.""" |
| 1 | +"""Tapered roller bearing, 302 and 303 series, bore up to 50 mm. Bore d, outside diameter D, overall width T, cone width B, cup width C and chamfers r (cone back) and r1 (cup back) are sourced and make the fit. detail = "full": the cone with its back rib, the cup and the tapered rollers at an angle between them. The 14 degree angle, roller size, rib and roller count are proportions for looks, not for design, and never change the fit dimensions; the cage is not drawn. detail = "simple": one solid ring d x D x T. Axis along Z, centred on the origin; cone back face at z = -T/2, cup back face at z = +T/2.""" |
| 2 | +import math |
| 3 | + |
| 3 | 4 | from steve import Model |
| 4 | 5 | |
| 5 | 6 | designation = "30204" # Bearing number |
| 7 | +detail = "full" # full: rings and rolling elements; simple: one solid |
| 6 | 8 | |
| 7 | | -# number: (d, D, T, B, C). NTN Ball and Roller Bearings CAT. No. 2203-3/E (2024), PDF pages 165-167, boundary dimensions. |
| 8 | | -BEARINGS = {"30203": (17, 40, 13.25, 12, 11), "30204": (20, 47, 15.25, 14, 12), "30205": (25, 52, 16.25, 15, 13), "30206": (30, 62, 17.25, 16, 14), "30207": (35, 72, 18.25, 17, 15), "30208": (40, 80, 19.75, 18, 16), "30209": (45, 85, 20.75, 19, 16), "30210": (50, 90, 21.75, 20, 17), "30302": (15, 42, 14.25, 13, 11), "30303": (17, 47, 15.25, 14, 12), "30304": (20, 52, 16.25, 16, 13), "30305": (25, 62, 18.25, 17, 15), "30306": (30, 72, 20.75, 19, 16), "30307": (35, 80, 22.75, 21, 18), "30308": (40, 90, 25.25, 23, 20), "30309": (45, 100, 27.25, 25, 22), "30310": (50, 110, 29.25, 27, 23)} |
| 9 | +# number: (d, D, T, B, C, r, r1). NTN Ball and Roller Bearings CAT. No. 2203-3/E (2024), PDF pages 165-167, https://www.ntnglobal.com/en/products/catalog/pdf/2203E.pdf |
| 10 | +BEARINGS = {"30203": (17, 40, 13.25, 12, 11, 1, 1), "30204": (20, 47, 15.25, 14, 12, 1, 1), "30205": (25, 52, 16.25, 15, 13, 1, 1), "30206": (30, 62, 17.25, 16, 14, 1, 1), "30207": (35, 72, 18.25, 17, 15, 1.5, 1.5), "30208": (40, 80, 19.75, 18, 16, 1.5, 1.5), "30209": (45, 85, 20.75, 19, 16, 1.5, 1.5), "30210": (50, 90, 21.75, 20, 17, 1.5, 1.5), "30302": (15, 42, 14.25, 13, 11, 1, 1), "30303": (17, 47, 15.25, 14, 12, 1, 1), "30304": (20, 52, 16.25, 16, 13, 1.5, 1.5), "30305": (25, 62, 18.25, 17, 15, 1.5, 1.5), "30306": (30, 72, 20.75, 19, 16, 1.5, 1.5), "30307": (35, 80, 22.75, 21, 18, 2, 1.5), "30308": (40, 90, 25.25, 23, 20, 2, 1.5), "30309": (45, 100, 27.25, 25, 22, 2, 1.5), "30310": (50, 110, 29.25, 27, 23, 2.5, 2)} |
| 9 | 11 | |
| 10 | | -d, D, T, B, C = BEARINGS[designation] |
| 12 | +d, D, T, B, C, r, r1 = BEARINGS[designation] |
| 13 | +W = T |
| 11 | 14 | model = Model() |
| 12 | | -with model.sketch("rings", on="XY", name="Rings") as sk: |
| 13 | | - sk.circle("outer", (0, 0), D / 2) |
| 14 | | - sk.circle("bore", (0, 0), d / 2) |
| 15 | | -model.extrude("body", "rings", distance=T, both=True, name="Bearing") |
| 16 | | -model.material("steel-generic", color="#b9bdc2") |
| 15 | +if detail == "simple": |
| 16 | + outline = [(d / 2 + r, -W / 2), (D / 2 - r, -W / 2), (D / 2, -W / 2 + r), (D / 2, W / 2 - r), (D / 2 - r, W / 2), (d / 2 + r, W / 2), |
| 17 | + (d / 2, W / 2 - r), (d / 2, -W / 2 + r)] |
| 18 | + with model.sketch("section", on="XZ", name="Section") as sk: |
| 19 | + sk.polyline("ring", outline, closed=True) |
| 20 | + model.revolve("inner", "section", axis="Z", name="Bearing") |
| 21 | +else: |
| 22 | + angle = math.radians(14) |
| 23 | + section = (D - d) / 2 |
| 24 | + mean_r = (D + d) / 4 |
| 25 | + roller = 0.2 * section # mean roller radius |
| 26 | + roller_length = 0.72 * C |
| 27 | + slope = math.tan(angle) |
| 28 | + offset = (roller * 1.04) / math.cos(angle) |
| 29 | + |
| 30 | + def cone_race(z): |
| 31 | + return mean_r - offset - z * slope |
| 32 | + |
| 33 | + def cup_race(z): |
| 34 | + return mean_r + offset - z * slope |
| 35 | + |
| 36 | + cone_top = -T / 2 + B |
| 37 | + cup_low = T / 2 - C |
| 38 | + rib = 0.35 * roller |
| 39 | + rib_z = -T / 2 + 0.16 * B |
| 40 | + cone = [(d / 2 + r, -T / 2), (cone_race(rib_z) + rib, -T / 2), (cone_race(rib_z) + rib, rib_z), (cone_race(rib_z), rib_z), (cone_race(cone_top), cone_top), (d / 2 + 0.3 * r, cone_top), (d / 2, cone_top - 0.3 * r), (d / 2, -T / 2 + r)] |
| 41 | + cup = [(cup_race(cup_low), cup_low), (D / 2 - 0.3 * r1, cup_low), (D / 2, cup_low + 0.3 * r1), (D / 2, T / 2 - r1), (D / 2 - r1, T / 2), (cup_race(T / 2), T / 2)] |
| 42 | + with model.sketch("cone_section", on="XZ", name="Cone section") as sk: |
| 43 | + sk.polyline("cone_ring", cone, closed=True) |
| 44 | + model.revolve("cone", "cone_section", axis="Z", op="new", body="cone_body", name="Cone") |
| 45 | + with model.sketch("cup_section", on="XZ", name="Cup section") as sk: |
| 46 | + sk.polyline("cup_ring", cup, closed=True) |
| 47 | + model.revolve("cup", "cup_section", axis="Z", op="new", body="cup_body", name="Cup") |
| 48 | + ux, uz = -math.sin(angle), math.cos(angle) |
| 49 | + nx, nz = math.cos(angle), math.sin(angle) |
| 50 | + r_big, r_small = roller * 1.12, roller * 0.88 |
| 51 | + a = (mean_r - ux * roller_length / 2, -uz * roller_length / 2) |
| 52 | + b = (mean_r + ux * roller_length / 2, uz * roller_length / 2) |
| 53 | + with model.sketch("roller_section", on="XZ", name="Roller section") as sk: |
| 54 | + sk.polyline("roller_half", [a, b, (b[0] + nx * r_small, b[1] + nz * r_small), (a[0] + nx * r_big, a[1] + nz * r_big)], closed=True) |
| 55 | + model.revolve("roller", "roller_section", axis=((mean_r, 0, 0), (ux, 0, uz)), op="new", body="roller_body", name="Roller") |
| 56 | + rollers = max(6, int(2 * math.pi * mean_r / (2.5 * r_big))) |
| 57 | + model.circular_pattern("rollers", axis="Z", count=rollers, bodies=["roller_body"], name="Rollers") |
| 58 | +model.material("steel-generic") |
| 59 | +model.appearance(color="#b9bdc2") |
| 17 | 60 | result = model.result() |
| 18 | 61 | |