More minor documentation tweaks

db4
Slava Pestov 2009-08-30 06:32:20 -05:00
parent 7983b5515f
commit ec70e1d714
5 changed files with 10 additions and 12 deletions

View File

@ -106,10 +106,7 @@ ARTICLE: "numbers" "Numbers"
{ $subsection "complex-numbers" } { $subsection "complex-numbers" }
"Advanced features:" "Advanced features:"
{ $subsection "math-vectors" } { $subsection "math-vectors" }
{ $subsection "math-intervals" } { $subsection "math-intervals" } ;
{ $subsection "math-bitfields" }
"Implementation:"
{ $subsection "math.libm" } ;
USE: io.buffers USE: io.buffers

View File

@ -6,6 +6,7 @@ IN: math.bits
ABOUT: "math.bits" ABOUT: "math.bits"
ARTICLE: "math.bits" "Number bits virtual sequence" ARTICLE: "math.bits" "Number bits virtual sequence"
"The " { $vocab-link "math.bits" } " vocabulary implements a virtual sequence which presents an integer as a sequence of bits, with the first element of the sequence being the least significant bit of the integer."
{ $subsection bits } { $subsection bits }
{ $subsection <bits> } { $subsection <bits> }
{ $subsection make-bits } ; { $subsection make-bits } ;

View File

@ -1,8 +1,7 @@
! Copyright (C) 2006, 2009 Slava Pestov. ! Copyright (C) 2006, 2009 Slava Pestov.
! See http://factorcode.org/license.txt for BSD license. ! See http://factorcode.org/license.txt for BSD license.
USING: accessors kernel kernel.private math math.private USING: accessors kernel kernel.private math math.private
math.libm math.functions arrays math.functions.private sequences math.functions arrays math.functions.private sequences parser ;
parser ;
IN: math.complex.private IN: math.complex.private
M: real real-part ; inline M: real real-part ; inline
@ -26,8 +25,8 @@ M: complex * [ *re - ] [ *im + ] 2bi rect> ; inline
M: complex / [ / ] complex/ ; inline M: complex / [ / ] complex/ ; inline
M: complex /f [ /f ] complex/ ; inline M: complex /f [ /f ] complex/ ; inline
M: complex /i [ /i ] complex/ ; inline M: complex /i [ /i ] complex/ ; inline
M: complex abs absq >float fsqrt ; inline M: complex abs absq sqrt ; inline
M: complex sqrt >polar [ fsqrt ] [ 2.0 / ] bi* polar> ; inline M: complex sqrt >polar [ sqrt ] [ 2.0 / ] bi* polar> ; inline
IN: syntax IN: syntax

View File

@ -3,10 +3,10 @@ IN: math.libm
ARTICLE: "math.libm" "C standard library math functions" ARTICLE: "math.libm" "C standard library math functions"
"The words in the " { $vocab-link "math.libm" } " vocabulary call C standard library math functions. They are used to implement words in the " { $vocab-link "math.functions" } " vocabulary." "The words in the " { $vocab-link "math.libm" } " vocabulary call C standard library math functions. They are used to implement words in the " { $vocab-link "math.functions" } " vocabulary."
$nl { $warning
"They can be called directly, however there is little reason to do so, since they only implement real-valued functions, and in some cases place restrictions on the domain:" "These functions are unsafe. The compiler special-cases them to operate on floats only. They can be called directly, however there is little reason to do so, since they only implement real-valued functions, and in some cases place restrictions on the domain:"
{ $example "USE: math.functions" "2 acos ." "C{ 0.0 1.316957896924817 }" } { $example "USE: math.functions" "2.0 acos ." "C{ 0.0 1.316957896924817 }" }
{ $unchecked-example "USE: math.libm" "2 facos ." "0/0." } { $unchecked-example "USE: math.libm" "2 facos ." "0/0." } }
"Trigonometric functions:" "Trigonometric functions:"
{ $subsection fcos } { $subsection fcos }
{ $subsection fsin } { $subsection fsin }

View File

@ -420,6 +420,7 @@ ARTICLE: "bitwise-arithmetic" "Bitwise arithmetic"
{ $subsection 2/ } { $subsection 2/ }
{ $subsection 2^ } { $subsection 2^ }
{ $subsection bit? } { $subsection bit? }
"Advanced topics:"
{ $subsection "math.bitwise" } { $subsection "math.bitwise" }
{ $subsection "math.bits" } { $subsection "math.bits" }
{ $see-also "booleans" } ; { $see-also "booleans" } ;