function [cr] = cr_bezier(params, u)

    dparams = [params(:,2), 2*params(:,3), 3*params(:,4), [0;0]];
    ddparams = [dparams(:,2), 2*dparams(:,3), 3*dparams(:,4), [0;0]];
    
    dx = dparams(1,:) * [1;u;u^2;u^3];
    dy = dparams(2,:) * [1;u;u^2;u^3];
    ddx = ddparams(1,:) * [1;u;u^2;u^3];
    ddy = ddparams(2,:) * [1;u;u^2;u^3];

    cr = 1/((dx*ddy - dy*ddx) / sqrt(dx^2+dy^2)^3);
end
