This wiki is out of date, use the continuation of this wiki instead

Log2

From FenixWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 14:19, 29 July 2008 (edit)
85.144.194.29 (Talk)
(New article: Log.dll: log2())
← Previous diff
Current revision (18:13, 29 July 2008) (edit) (undo)
Sandman (Talk | contribs)
m
 
Line 10: Line 10:
'''FLOAT''' log2 ( <'''FLOAT''' n> ) '''FLOAT''' log2 ( <'''FLOAT''' n> )
-Returns a [http://en.wikipedia.org/wiki/Logarithm logarithm] of number n with base 2.+Returns a [http://en.wikipedia.org/wiki/Logarithm logarithm] of number ''n'' with base 2.
== Parameters == == Parameters ==
Line 18: Line 18:
== Returns == == Returns ==
-'''FLOAT''' : The logarithm of n with base 2.+'''FLOAT''' : The logarithm of ''n'' with base 2.
== Example == == Example ==
Line 26: Line 26:
Global Global
float logarithm=0.0; float logarithm=0.0;
 +End
Process main() Process main()
Line 39: Line 40:
</pre> </pre>
Used in example: [[import]], [[write_float]](), [[key]](), [[log2]]() Used in example: [[import]], [[write_float]](), [[key]](), [[log2]]()
 +
 +{{Logfuncbox}}

Current revision

Up to Log.dll functions



Contents

[edit] Definition

FLOAT log2 ( <FLOAT n> )

Returns a logarithm of number n with base 2.

[edit] Parameters

FLOAT n - The number that will be used for the logarithm.

[edit] Returns

FLOAT : The logarithm of n with base 2.

[edit] Example

Import "log.dll";

Global
    float logarithm=0.0;
End

Process main()
Begin
    write_float(0,160,100,4,&logarithm);
	
    While(not(key(_esc)))
        If (key(_1)) logarithm=log2(1024); End 

        Frame;
    End
End

Used in example: import, write_float(), key(), log2()


Log.DLL Functions
Ln() • Log() • Log2() •
Personal tools