@@ -514,9 +514,28 @@ def evaluate(self, datadict, **kwargs):
514
514
515
515
return eval_points
516
516
517
- def derivatives (self , ** kwargs ):
518
- """ Evaluates the derivative at the given parametric coordinate. """
519
- pass
517
+ def derivatives (self , datadict , parpos , deriv_order = 0 , ** kwargs ):
518
+ """ Evaluates the n-th order derivatives at the input parametric position.
519
+
520
+ :param datadict: data dictionary containing the necessary variables
521
+ :type datadict: dict
522
+ :param parpos: parametric position where the derivatives will be computed
523
+ :type parpos: list, tuple
524
+ :param deriv_order: derivative order; to get the i-th derivative
525
+ :type deriv_order: int
526
+ :return: evaluated derivatives
527
+ :rtype: list
528
+ """
529
+ # Geometry data from datadict
530
+ degree = datadict ['degree' ]
531
+ knotvector = datadict ['knotvector' ]
532
+ ctrlpts = datadict ['control_points' ]
533
+ size = datadict ['size' ]
534
+ dimension = datadict ['dimension' ] + 1 if datadict ['rational' ] else datadict ['dimension' ]
535
+ pdimension = datadict ['pdimension' ]
536
+
537
+ # TO-DO: Complete volume derivatives
538
+ return list ()
520
539
521
540
522
541
@utl .export
@@ -557,9 +576,25 @@ def evaluate(self, datadict, **kwargs):
557
576
558
577
return eval_points
559
578
560
- def derivatives (self , ** kwargs ):
561
- """ Evaluates the derivatives at the input parameter. """
562
- pass
579
+ def derivatives (self , datadict , parpos , deriv_order = 0 , ** kwargs ):
580
+ """ Evaluates the n-th order derivatives at the input parametric position.
581
+
582
+ :param datadict: data dictionary containing the necessary variables
583
+ :type datadict: dict
584
+ :param parpos: parametric position where the derivatives will be computed
585
+ :type parpos: list, tuple
586
+ :param deriv_order: derivative order; to get the i-th derivative
587
+ :type deriv_order: int
588
+ :return: evaluated derivatives
589
+ :rtype: list
590
+ """
591
+ dimension = datadict ['dimension' ] + 1 if datadict ['rational' ] else datadict ['dimension' ]
592
+
593
+ # Call the parent function to evaluate A(u) and w(u) derivatives
594
+ SKLw = super (VolumeEvaluatorRational , self ).derivatives (datadict , parpos , deriv_order , ** kwargs )
595
+
596
+ # TO-DO: Complete rational volume derivatives
597
+ return list ()
563
598
564
599
565
600
# Don't export alternative curve evalutator
0 commit comments