Skip to content

Commit

Permalink
Release 0.4.
Browse files Browse the repository at this point in the history
  • Loading branch information
samhocevar committed Aug 15, 2017
1 parent 215d947 commit 44ae86f
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 7 deletions.
22 changes: 18 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ A tutorial is available [in the wiki section](https://github.com/samhocevar/lolr

## Example

Approximate `atan(sqrt(3+x³)-exp(1+x))` over the range `[sqrt(2),pi²]` with a 5th degree polynomial:
Approximate `atan(sqrt(3+x³)-exp(1+x))` over the range `[sqrt(2),pi²]` with a 5th degree polynomial for `double` floats:

```sh
lolremez -d 5 -r "sqrt(2):pi²" "atan(sqrt(3+x³)-exp(1+x))"
lolremez --double -d 5 -r "sqrt(2):pi²" "atan(sqrt(3+x³)-exp(1+x))"
```

Result:
Expand All @@ -20,12 +20,12 @@ Result:
* with a polynomial of degree 5. */
double f(double x)
{
double u = -3.9557569330471554e-5;
double u = -3.9557569330471555e-5;
u = u * x + 1.2947712130833294e-3;
u = u * x + -1.6541397035559147e-2;
u = u * x + 1.0351664953941214e-1;
u = u * x + -3.2051562487328135e-1;
return u * x + -1.1703528319321960;
return u * x + -1.1703528319321961;
}
```
Expand Down Expand Up @@ -56,8 +56,22 @@ Math functions:
- *asin()*, *acos()*, *atan()*
- *sinh()*, *cosh()*, *tanh()*
Parsing rules:
- *-a^b* is *-(a^b)*
- *a^b^c* is *(a^b)^c*
## Changes
### News for LolRemez 0.4:
- Allow expressions in the range specification: `-r -pi/4:pi/4` is now valid.
- Allow using “pi” and “e” in expressions, as well as “π”.
- Bugfixes in the expression parser.
- Support for hexadecimal floats, *e.g.* `0x1.999999999999999ap-4`.
- New `--float`, `--double` and `--long-double` options to choose precision.
- Trim down DLL dependencies to allow for lighter binaries.
### News for LolRemez 0.3:
- implemented an expression parser so that the user does not have to
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ dnl
dnl Configure script for a Lol Engine project
dnl

AC_INIT(lolremez, 0.3)
AC_INIT(lolremez, 0.4)

dnl
dnl Standard autoconf setup and tools requirements
Expand Down
2 changes: 1 addition & 1 deletion lol
Submodule lol updated 1 files
+1 −1 src/lol/base/features.h
2 changes: 1 addition & 1 deletion src/lolremez.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</ItemGroup>
<ItemDefinitionGroup>
<ClCompile>
<PreprocessorDefinitions>PACKAGE_VERSION="0.3";%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>PACKAGE_VERSION="0.4";%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
</ItemDefinitionGroup>
<ItemGroup>
Expand Down

0 comments on commit 44ae86f

Please sign in to comment.