At the version v1.0.8, calling degree_increase or degree_decrease raises a ValueError when the parameter times = 0 is given.
It should do nothing in that case.
Steps to reproduce:
from compmec.nurbs import Curve
knotvector = (0, 0, 0, 1, 1, 1) # degree 2, npts 3
curve = Curve(knotvector)
curve.degree_increase(0) # Raises ValueError
curve.degree_decrease(0) # Raises ValueError
curve.degree = 2 # Does nothing since degree is already 2
At the version
v1.0.8, callingdegree_increaseordegree_decreaseraises aValueErrorwhen the parametertimes = 0is given.It should do nothing in that case.
Steps to reproduce: