SVG: Pfadfragment für affine Spirale bestimmen / Determine affine spiral path fragment
Nach Angabe von GET-Parametern wird ein Spiralbogen als SVG-Kurve ermittelt und dargestellt,
nicht angegebene Parameter werden zufällig gesetzt (Ausnahme anz und rnd).
Um die Qualität der Näherung abzuschätzen, wird ein Vergleich mit einer Näherung mit
doppelter Punktzahl durchgeführt, bei größeren Unterschieden ist die Anzahl der Punkte zu
erhöhen.
cx, cy: Zentrum der Spirale
x1, y1: Anfangspunkt
x2, y2: Endpunkt
t: Näherungsweise Anzahl der Runden
theta: Startwinkel von x-Achse aus
delta: Endwinkel = theta + delta
anz: Anzahl der Stützstellen (ohne Angabe wird eine Winkeldifferenz von maximal 30 Grad angenommen
und daraus wird dann anz automatisch bestimmt).
rnd: Anzahl der Rundungsstellen
Due to given GET parameters a spiral arc is determined as SVG curve and painted,
not specified parameters are choosen randomly (exception anz and rnd).
To estimate the quality of the approximation, a comparison is given with another approximation
with twice the number of points, with larger deviations the number of points needs to be
enhanced.
cx, cy: center of the spiral
x1, y1: initial point
x2, y2: final point
t: approximate number of turns
theta: initial angle from x-axis
delta: final angle = theta + delta
anz: Number of curve points (if not specified, the angle difference not larger than 30 degree is choosen
and anz is determined automatically).
rnd: the digits to be rounded in the fractional part of numbers in the output
Zentrum / centre
maximaler Fehler / maximal error
Pfadvergleich doppelte Punktanzahl / path comparsion, twice the number of points
Approximierter Pfad / approximated path
Punkte / points
Anfangspunkt / initial point
Endpunkt / final point
?cx=400&cy=-598&x1=-237.37069333333&y1=10.022749259259&x2=-227&y2=21&t=-1&anz=11&rnd=2
Aktuelle Werte / Current Values
0.15901274266816 | 0.082538560181857
Fehler maximal, mittel / Error maximum, average
cx=400; cy=-598; ra=815.09; rd=65.98; theta=99.46; delta=-324.09
Aktuelle Werte / Current Values
M266 206 C403.48 230.94 547.9 219.83 680.84 173.57 S
934.92 45.99 1028.58 -60.45
1188.19 -298.24
1217.58 -438
1239.71 -725.61 1196.23 -862.72
1073.13 -1125.88 967.08 -1224.57
728.75 -1394.33 586.87
-1428.31
293.8 -1459.08 152.57 -1418.59
-119.62 -1300.38 -223.38 -1194.91
-403.45 -956.44 -442.17
-812.57
-481.9 -514.32 -444.59 -369.02
-331.68 -87.88 -227 21
Kubische Näherung / Cubic Approximation