Skip to content
ForCADDocumentation

geometry_derivative Subroutine

public pure subroutine geometry_derivative(Xt1, nc, degree, knot1, Xc, Wc, order, wrap, Xg, knot2, knot3, Xt2, Xt3, side, row_power)

One positive-order geometry derivative, with local span coordinates. Bernstein extraction normalizes each axis before the rational recurrence. Anchored contractions remove translations; one combined width scale restores the original parameter units, including arbitrary mixed orders. With row_power, the derivative in native units is Xg(row,:)2*row_power(row). Any unrepresentable required workspace returns an empty result. Callers validate owned geometry, matching finite parameter axes, rank 1:3, and a nonnegative derivative multi-index with positive total order.

Arguments

Type IntentOptional Attributes Name
real(kind=rk), intent(in) :: Xt1(:)
integer, intent(in) :: nc(:)
integer, intent(in) :: degree(:)
real(kind=rk), intent(in), contiguous :: knot1(:)
real(kind=rk), intent(in), contiguous :: Xc(:,:)
real(kind=rk), intent(in), optional, contiguous :: Wc(:)
integer, intent(in) :: order(:)
logical, intent(in) :: wrap(:)
real(kind=rk), intent(out), allocatable :: Xg(:,:)
real(kind=rk), intent(in), optional, contiguous :: knot2(:)
real(kind=rk), intent(in), optional, contiguous :: knot3(:)
real(kind=rk), intent(in), optional :: Xt2(:)
real(kind=rk), intent(in), optional :: Xt3(:)
integer, intent(in), optional :: side(:)
integer, intent(out), optional, allocatable :: row_power(:)