(self, datadict, parpos, deriv_order=0, **kwargs)
return CK
Evaluates the n-th order derivatives at the input parametric position.

        :param datadict: data dictionary containing the necessary variables
        :type datadict: dict
        :param parpos: parametric position where the derivatives will be computed
        :type parpos: list, tuple
        :param deriv_order: derivative order; to get the i-th derivative
        :type deriv_order: int
        :return: evaluated derivatives
        :rtype: list
Evaluates the n-th order derivatives at the input parametric position.
Evaluates the n - th order derivatives at the input parametric position .
def derivatives(self, datadict, parpos, deriv_order=0, **kwargs):
        """ Evaluates the n-th order derivatives at the input parametric position.

        :param datadict: data dictionary containing the necessary variables
        :type datadict: dict
        :param parpos: parametric position where the derivatives will be computed
        :type parpos: list, tuple
        :param deriv_order: derivative order; to get the i-th derivative
        :type deriv_order: int
        :return: evaluated derivatives
        :rtype: list
        """
        # Geometry data from datadict
        degree = datadict['degree'][0]
        knotvector = datadict['knotvector'][0]
        ctrlpts = datadict['control_points']
        size = datadict['size'][0]
        dimension = datadict['dimension'] + 1 if datadict['rational'] else datadict['dimension']

        # Algorithm A3.4
        du = min(degree, deriv_order)

        CK = [[0.0 for _ in range(dimension)] for _ in range(deriv_order + 1)]

        span = self._span_func(degree, knotvector, size, parpos)
        bfuns = helpers.basis_function_all(degree, knotvector, span, parpos)

        # Algorithm A3.3
        PK = helpers.curve_deriv_cpts(dimension, degree, knotvector, ctrlpts,
                                      rs=((span - degree), span), deriv_order=du)

        for k in range(0, du + 1):
            for j in range(0, degree - k + 1):
                CK[k][:] = [elem + (bfuns[j][degree - k] * drv_ctl_p) for elem, drv_ctl_p in
                            zip(CK[k], PK[k][j])]

        # Return the derivatives
        return CK
def derivatives ( self , datadict , parpos , deriv_order = 0 , * * kwargs ) : # Geometry data from datadict degree = datadict [ 'degree' ] [ 0 ] knotvector = datadict [ 'knotvector' ] [ 0 ] ctrlpts = datadict [ 'control_points' ] size = datadict [ 'size' ] [ 0 ] dimension = datadict [ 'dimension' ] + 1 if datadict [ 'rational' ] else datadict [ 'dimension' ] # Algorithm A3.4 du = min ( degree , deriv_order ) CK = [ [ 0.0 for _ in range ( dimension ) ] for _ in range ( deriv_order + 1 ) ] span = self . _span_func ( degree , knotvector , size , parpos ) bfuns = helpers . basis_function_all ( degree , knotvector , span , parpos ) # Algorithm A3.3 PK = helpers . curve_deriv_cpts ( dimension , degree , knotvector , ctrlpts , rs = ( ( span - degree ) , span ) , deriv_order = du ) for k in range ( 0 , du + 1 ) : for j in range ( 0 , degree - k + 1 ) : CK [ k ] [ : ] = [ elem + ( bfuns [ j ] [ degree - k ] * drv_ctl_p ) for elem , drv_ctl_p in zip ( CK [ k ] , PK [ k ] [ j ] ) ] # Return the derivatives return CK