Bu CATIA API fonksiyonu ne işe yarar?
Fonksiyon: CAAKniOptimization.CATScript
Cevap:
COPYRIGHT DASSAULT SYSTEMES 2001
 ***********************************************************************
   Purpose:    This macro shows how to create and run an optimization feature.
               It shows the follwing steps.
               - Creates two parameters and a formula
               - Creates and sets up the optimization feature
               - Runs the optimization.

   The optimization problem consists in finding the value of x that minimizes fx.
   knowing that fx = x*x + 8.
   The objective is fx and the free parameter is x.

   Assumption: This macro is intended to be run on a newly created part document.
   Languages:    VBScript
   Locales:      English (United States)
   CATIA Level:  V5R7
 ***********************************************************************
 Set the CATIA popup file alerts to False
 It prevents to stop the macro at each alert during its execution
 Retrieve your active document - CATIA is your application
 You get the active document by using the ActiveDocument property
 on your application object
 Check whether the document is a CATPart
 Retrieve the collection object which contains
 all the document relations.
 The statements below are only valid when the active
 document is a CATPart
 Retrieve the collection object which contains
 all the document parameters.
 Create Real type parameter as objective to be optimized.
 Create Real type parameter as free parameter.
 Create a formula to be optimized.
 Retrieve the collection object which contains
 all the document optimizations.
 Create the optimization feature.
Set up the optimization feature attributes.
2 minutes.
Set up the free parameters of the optimization and their steps (this is optional).
The step helps the algorithm to get an order of magnitude of the changes of values
acceptable for each free parameters.
The following is optional, but usually reducing the range of input parameters helps to
solve the problem faster. In this case there only is one free parameter but optimizations
 can be run with multiple free parameters.
Set the parameter that must be optimized.
Running the optimization without the progress bar dialog box (False).
 Update the document