how can I get a root of some number

Please support our C# advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Oct 2008
Posts: 63
Reputation: polo_coins is an unknown quantity at this point 
Solved Threads: 0
polo_coins polo_coins is offline Offline
Junior Poster in Training

how can I get a root of some number

 
0
  #1
Sep 5th, 2009
I want get a root of number in C#
what library i must to insert and what command solve it
Reply With Quote Quick reply to this message  
Join Date: Feb 2009
Posts: 3,341
Reputation: sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of sknake has much to be proud of 
Solved Threads: 602
Sponsor
sknake's Avatar
sknake sknake is online now Online
.NET Enthusiast

Re: how can I get a root of some number

 
0
  #2
Sep 5th, 2009
  1. System.Math.Sqrt();
Scott Knake
Custom Software Development
Apex Software, Inc.
Reply With Quote Quick reply to this message  
Join Date: Oct 2008
Posts: 63
Reputation: polo_coins is an unknown quantity at this point 
Solved Threads: 0
polo_coins polo_coins is offline Offline
Junior Poster in Training

Re: how can I get a root of some number

 
0
  #3
Sep 5th, 2009
thanks a lot
Reply With Quote Quick reply to this message  
Join Date: Oct 2008
Posts: 1,996
Reputation: ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of 
Solved Threads: 294
ddanbe's Avatar
ddanbe ddanbe is offline Offline
Posting Virtuoso

Re: how can I get a root of some number

 
2
  #4
Sep 5th, 2009
In addition to that : a root of a number cannot only refer to the square root, but also the cube root,... Nth root.
To do this in C# you can do something like:
  1. double num = 8.0;
  2. double power = 1.0 / 3;
  3. Console.WriteLine("Cube root of {0} is {1}.", num, Math.Pow(num, power));
Today is a gift, that's why it is called "The Present".
Make love, no war. Cave ab homine unius libri.
Danny
Reply With Quote Quick reply to this message  
Reply

Tags
math, mathematics

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



Tag cloud for math, mathematics
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC