mo...@deepbondi.net wrote:
How embarrassing, I managed to get this simple math wrong. That's what I
get for trying to think in the morning without either my notes or my
coffee, I suppose.
I _said_ it was tricky, didn't I? ;-)
___
Haskell-Cafe mailin
mo...@deepbondi.net wrote:
> It took me a while to get the intuition right on those, but here's a quick
> sketch. Let n = number of control points, m = number of knots, and p =
> degree. For p = 0 (constant segments), each control point corresponds to
> one span of the knot vector, so n = m - 1.
On Aug 5, 2010, at 4:31 PM, Andrew Coppin wrote:
> mo...@deepbondi.net wrote:
>> Andrew Coppin wrote:
>>
>>> Given a suitable definition for Vector2 (i.e., a 2D vector with the
>>> appropriate classes), it is delightfully trivial to implement de
>>> Casteljau's algorithm:
>>>
>>> de_Casteljau :
mo...@deepbondi.net wrote:
Andrew Coppin wrote:
Given a suitable definition for Vector2 (i.e., a 2D vector with the
appropriate classes), it is delightfully trivial to implement de
Casteljau's algorithm:
de_Casteljau :: Scalar -> [Vector2] -> [[Vector2]]
de_Casteljau t [p] = [[p]]
de_Castelj
Andrew Coppin wrote:
> Given a suitable definition for Vector2 (i.e., a 2D vector with the
> appropriate classes), it is delightfully trivial to implement de
> Casteljau's algorithm:
>
> de_Casteljau :: Scalar -> [Vector2] -> [[Vector2]]
> de_Casteljau t [p] = [[p]]
> de_Casteljau t ps = ps : de_Ca
Given a suitable definition for Vector2 (i.e., a 2D vector with the
appropriate classes), it is delightfully trivial to implement de
Casteljau's algorithm:
de_Casteljau :: Scalar -> [Vector2] -> [[Vector2]]
de_Casteljau t [p] = [[p]]
de_Casteljau t ps = ps : de_Casteljau t (zipWith (line t) ps