Rumus Rhapson Menggunakan C++
#include
#include
#include
main()
{
float fx,dfx,deltax,xawal,xbaru,c,deltac;
int iterasi;
xawal = 6.0;
fx = pow(xawal,3) - (6.0* pow(xawal,2)) + (9*xawal) - 4.0;
c = 0.0;
deltac = c - fx;
dfx = (3.0*(pow(xawal,2))) - (12.0*xawal) + 9.0;
deltax = deltac/dfx;
xbaru = xawal + deltax;
iterasi = 1;
puts("");
deltax = fabs(deltax);
printf("\nDelta x = %f",deltax);
puts("");
(..............................................................)
Untuk Yang lengkapnya silakan Download Di Sini
#include
#include
main()
{
float fx,dfx,deltax,xawal,xbaru,c,deltac;
int iterasi;
xawal = 6.0;
fx = pow(xawal,3) - (6.0* pow(xawal,2)) + (9*xawal) - 4.0;
c = 0.0;
deltac = c - fx;
dfx = (3.0*(pow(xawal,2))) - (12.0*xawal) + 9.0;
deltax = deltac/dfx;
xbaru = xawal + deltax;
iterasi = 1;
puts("");
deltax = fabs(deltax);
printf("\nDelta x = %f",deltax);
puts("");
(..............................................................)
Untuk Yang lengkapnya silakan Download Di Sini
Comments
Post a Comment