Docs: a beginner's page for equation curves, with pictures and examples (#9282)
A new user guide page, Equation curves, under Sketching: the first curve step by step, Explicit and Parametric explained with tables of rules to type (a line, a parabola, a wave, a circle, a spiral), radians, parameters with the involute of a base circle, building a part (a closed flower curve extruded), editing, and common mistakes. The technical details stay in a short section for scripts and agents. Seven pictures, rendered by `cargo xtask book` from new scripts in docs/book/scripts/equation-*.json (gitignored output, attributed in attribution/pending/docs-equation-curves.md). The Sketching page keeps a short summary and links to the new page.
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Circle"}},
|
||||
{"command": "sketch.equation_curve", "params": {"x": "20 * cos(t)", "y": "20 * sin(t)", "start": 0, "end": "2 * pi"}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Flower"}},
|
||||
{"command": "sketch.equation_curve", "params": {"x": "(20 + 4 * cos(6 * t)) * cos(t)", "y": "(20 + 4 * cos(6 * t)) * sin(t)", "start": 0, "end": "2 * pi"}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "solid.extrude", "params": {"sketch": "Flower", "distance": 6, "body_name": "Flower"}}
|
||||
]}
|
||||
@@ -0,0 +1,8 @@
|
||||
{"commands": [
|
||||
{"command": "parameters.add", "params": {"name": "r", "expression": "20 mm"}},
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Involute"}},
|
||||
{"command": "sketch.equation_curve", "params": {"x": "r * (cos(t) + t * sin(t))", "y": "r * (sin(t) - t * cos(t))", "start": 0, "end": 1.5}},
|
||||
{"command": "sketch.circle.center", "params": {"center": [0, 0], "diameter": 40}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Line"}},
|
||||
{"command": "sketch.equation_curve", "params": {"explicit": true, "y": "x / 2", "start": 0, "end": 40}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Parabola"}},
|
||||
{"command": "sketch.equation_curve", "params": {"explicit": true, "y": "x * x / 20", "start": -30, "end": 30}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Spiral"}},
|
||||
{"command": "sketch.equation_curve", "params": {"x": "2 * t * cos(t)", "y": "2 * t * sin(t)", "start": 0, "end": "4 * pi"}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
@@ -0,0 +1,6 @@
|
||||
{"commands": [
|
||||
{"command": "sketch.create", "params": {"plane": "XY", "name": "Wave"}},
|
||||
{"command": "sketch.equation_curve", "params": {"explicit": true, "y": "8 * sin(x / 5)", "start": 0, "end": "20 * pi"}},
|
||||
{"command": "sketch.finish", "params": {}},
|
||||
{"command": "view.apply", "params": {"view": "top"}}
|
||||
]}
|
||||
Reference in New Issue
Block a user