I have received this from my instructor. I am aware of how to create a function, but I'm not exactly sure what they are asking. I am also unsure on how to set up the actual calculations. Any suggestions?
Here is the problem:
Implement as a function the secant root-finding method described in section 10.1. If function secant does not converge to a root (successive approximations differ by less than 0.0001) in 25 iterations, have it display an error message and return 0. Call function secant from a function you define named nthRoot that should approximate the nth root of any constant c(squareroot of c to nth), given c and n. If xn = c, then xn -c= 0 and the nth root of c is zeor of the second queation. As your initial guesses, use X0=c and x1= c/n.
Hi littlemissb,
If you're not clear on the assignment it would be much more appropriate to talk to your instructor. If you get stuck coding the solution, you can come here for some hints.