! Copyright (C) 2010 Erik Charlebois
! See http://factorcode.org/license.txt for BSD license.
-USING: accessors combinators kernel locals math math.combinatorics
-math.polynomials opengl.gl sequences ui.gadgets ui.gadgets.panes
-ui.render arrays grouping math.vectors assocs
-ui.gestures ;
+USING: arrays combinators grouping kernel math
+math.combinatorics math.polynomials math.vectors sequences ;
IN: math.splines
<PRIVATE
acc ;
:: <cubic-hermite-curve> ( p0 m0 p1 m1 -- polynomials )
- p0 length iota [
+ p0 length <iota> [
{
[ p0 nth ] [ m0 nth ]
[ p1 nth ] [ m1 nth ]