Posts
 
Reputation
Joined
Last Seen
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
50% Quality Score
Upvotes Received
1
Posts with Upvotes
1
Upvoting Members
1
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
1 Commented Post
0 Endorsements
~726 People Reached
Favorite Forums
Favorite Tags
c++ x 10
Member Avatar for callister

[code]#include <iostream> #include <cmath> double f1(double); double f2(double,double); using namespace std; int main() { double dx, dy,x=1.0, y=1.0,xnew,ynew,eps=0.0000001,err=1.0,m=1; while ( fabs(err) > eps ) { dx= -f1(x)/(3.0*sin(x)+cos(x)); dy= (f1(x)*sin(x)+f2(x,y)*(cos(x)-3*sin(x)))/3*sin(x)*(cos(y)+cos(x)*cos(y)); xnew= x+dx; ynew= y+dy; m = (xnew*xnew)+(ynew*ynew); err=sqrt(m); } if ( fabs(err) < eps ) cout<< "dx= " <<dx<<endl; cout<< "dy= …

Member Avatar for nezachem
0
287
Member Avatar for callister

Guys..Can anyone help me to explain what really happened in the while loop and both of the if else loop that makes this coding can find the root using bisection method.Thank you...[code]#include "stdafx.h" #include <iostream> #include <cmath> #include <iomanip> using namespace std; double f( double); int main ( int argc, …

Member Avatar for StuXYZ
1
123
Member Avatar for callister

Guys..I'm trying to understand this coding and I can't understand the for loop. Can someone please explain it to me what happened there. Thank you[code]#include <iostream> using namespace std; int main() { long long int number; cout << "Enter number to test: "; cin >> number; for(int x=2; x<(number/2); x++) …

Member Avatar for WaltP
-1
98
Member Avatar for callister

Hey everybody.. I have some problem here. This is the question: Find a root of the equation on the interval [4,5] by using the bisection method. What happens on the interval [ 1 , 2] ? I wrote the code and everything seems fine with the interval [4,5] but for …

Member Avatar for callister
0
218