Re: Power arithmetic function to C#
- From: "Tom de Neef" <tdeneef@xxxxxxxx>
- Date: Wed, 29 Mar 2006 09:59:17 +0200
"SunYour" <sunyour@xxxxxxxxxxx> schreef in bericht
news:1143584822.163480.194610@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hello,
Does anyone know how the Power arithmetic function works? I need to
define my own Power function in c# and need to know how to implement
it.
z = x ** y
ln(z) = y * ln(x)
z = exp(ln(z)) = exp(y * ln(x))
function Power(const Base, Exponent: Extended): Extended;
// base ** exponent for base >0
begin
if base>0
then result:=exp(exponent*ln(base))
else error
end;
Tom
.
- Follow-Ups:
- Re: Power arithmetic function to C#
- From: Hanford Carr
- Re: Power arithmetic function to C#
- References:
- Power arithmetic function to C#
- From: SunYour
- Power arithmetic function to C#
- Prev by Date: Re: Power arithmetic function to C#
- Next by Date: Re: TreeView with checkboxes
- Previous by thread: Re: Power arithmetic function to C#
- Next by thread: Re: Power arithmetic function to C#
- Index(es):