2 puts "0030645: Modeling Algorithms - B-spline segmentation produces wrong parametrization"
6 bsplinecurve result 3 4 \
7 2.0 4 2.5 2 2.9 2 3.0 4 \
19 segment result 2.5 2.900000001 $tolerance
23 regexp {Knots +:\n(.*)} $crv full knots
24 set is_different_knots 1
26 while { "$knots" != "\n" && $is_different_knots } {
27 regexp { +([0-9]+) +: +([-0-9.+eE]+) *([0-9]+)\n(.*)} $knots full index knot weight rest
28 foreach k $knots_list {
29 if { [expr abs($k - $knot)] < $tolerance } {
30 set is_different_knots 0
34 lappend knots_list $knot
38 if { $is_different_knots } {
39 puts "OK: all knots are different"
41 puts "ERROR: segment has knots too close"