
problem c++
i have this problem:your task is to approximate numerically the derivative of a given function f:R>R at some value x .the value for x will be input by the user (and can vary).the function f should be treated as a c++ function,for examble the user should be able to change it by editing the programme.
a) write a c++ computer progrmme to carry out this numerical approximation
b) run your c++ programme to approximate the following derivatives:
1. f(x)=sinxcosx at x= 60 moirai
2. f(x)=ln(x^2 + x^4 ) at x=3

two things...
Post your code, no matter how small so you can show you have attempted to question in hand
Nobody here will write your program for you, read the rules and regulations for more on this or read the homwork sticky thread ot the top of the page.
If you show you have attempted it and are still stuck, we can point out where you have gone wrong and give advise on how to fix it

sin() and cos() are in <cmath>; you use * instead of x for multiplication in C++. (x looks like a variable.)