Difference: FloatingPointUnit (40 vs. 41)

Revision 412022-12-01 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 166 to 166
 

Words Using the C Math Library

Changed:
<
<
C mathematical functions @ Wikipedia
>
>
FPU support without trigonometric, hyperbolic and exponential functions is not even half the battle. Fortunately there is the GNU C math library. C mathematical functions @ Wikipedia
 
fsin    ( r1 -- r2 )       r2 is the sine of the radian angle r1

Line: 261 to 262
  RC time constant

Changed:
<
<
2.2n 47k f* fm. 103u ok.
>
>
2.2n 47k f* dup fm. 103u ok. cutoff frequency
2e pi f* f* 1e swap f/ fm. 1.54k  ok.

 
Changed:
<
<
Mecrisp-Cube has the word f. defined as an assembler routine in fpu.s, but the example here is written in Forth. I use a dot for the decimal separator. Terry Porter "because those crazy Europeans use a comma instead of a decimal point". Not all europeans are crazy, at least the Swiss are an exception ;-), they use sometimes decimal points.
>
>
Mecrisp-Cube has the word f. defined as an assembler routine in fpu.s, but the example here is written in Forth. I use a dot for the decimal separator. Terry Porter "because those crazy Europeans use a comma instead of a decimal point". Not all europeans are crazy, at least the Swiss are an exception ;-), they use decimal points (but not always, for details see https://en.wikipedia.org/wiki/Decimal_separator).
 
: f. ( r -- )  \ display, with a trailing space, the floating-point number r in fixed-point notation
  dup  f0< if

 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback