1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-06-20 11:54:07 +03:00
occt/tests/bugs/modalg_5/bug23706_10
aml 4bbaf12b67 0024608: Development of methods of global optimization of multivariable function
math_GlobOptMin - new global optimization minimization algorithm
Extrema_GlobOptFuncCC, Extrema_ExtCC, Extrema_ExtCC2d - implementation of GlobOptMin algorithm to extrema curve / curve
Extrema_CurveCache - deleted as obsolete code
ChFi3d_Builder.cxx  - fixed processing of extrema
math_NewtonMinimum.cxx - fixed step to avoid incorrect behavior
Test cases modification to meet new behavior.
2014-05-15 17:51:44 +04:00

28 lines
879 B
Plaintext
Executable File

puts "============"
puts "OCC23706"
puts "============"
puts ""
#########################################################################
# Cannot project point on curve
#########################################################################
bsplinecurve r3 2 6 1 3 2 1 3 1 4 1 5 1 6 3 2 5 3 1 3 7 3 1 4 8 3 1 4 8 3 1 4 8 3 1 5 9 3 1 9 7 3 1
bsplinecurve r4 2 6 2 3 2.5 1 3 1 3.5 1 4 1 4.5 3 -1 2 3 1 1 11 3 1 3 9 3 1 3 9 3 1 3 9 3 1 5 7 3 1 7 4 3 1
extrema r3 r4
cvalue ext_1 0 x y z
set info [dump x]
regexp "(\[-0-9.+eE\])" $info full xx
set info [dump y]
regexp "(\[-0-9.+eE\])" $info full yy
set info [dump z]
regexp "(\[-0-9.+eE\])" $info full zz
if { sqrt(($xx - 4.0) * ($xx - 4.0) +
($yy - 8.0) * ($yy - 8.0) +
($zz - 3.0) * ($zz - 3.0)) > 1.0e-7} {
puts "Error : Point of extrema is wrong"
} else {
puts "OK: Point of extrema is valid"
}