// Secant method #include #include #include // Define your function here float f(float x) { return(2*x-log10(x)-6); } // Start of main program main() { float x, x1, a, b, err=0.00005; int itr=1, n; printf("Enter values of a, b and maximum iterations \n"); scanf("%f%f%d", &a, &b, &n); x = b-(((b-a)/(f(b)-f(a)))*f(b)); printf("iteration no. %d\tx=%f\n", itr, x); itr++; while(itr < n) { a = b; b = x; x = b-(((b-a)/(f(b)-f(a)))*f(b)); printf("iteration no. %d\tx=%f\n",itr,x); if(fabs(x1-x)