adding second derivative