>>925
#include <iostream>
#include <cmath>
int main()
{
  std::cout << "x = " << newton_raphson(1, f, fprime) << std::endl;
  return 0;
}

っていうか実はCで書けって話だった?
その場合は
#include <stdio.h>
#include <math.h>
int main() { printf("x = %f\n", newton_raphson(1, f, fprime)); return 0; }
あとは std:: を全て削除で。