crmf 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.yardopts +10 -0
- data/LICENSE +674 -0
- data/README.md +35 -0
- data/crmf.gemspec +29 -0
- data/ext/crlibm-1.0beta4.tar.gz +0 -0
- data/ext/crmf/crmf.c +1966 -0
- data/ext/crmf/crmf.h +29 -0
- data/ext/crmf/crmf.map +7 -0
- data/ext/crmf/extconf.rb +68 -0
- data/lib/crmf/version.rb +4 -0
- data/lib/crmf.rb +19 -0
- data/tests/perf.rb +354 -0
- metadata +57 -0
data/README.md
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
|
2
|
+
Correctly Rounded Math Functions for Ruby floats
|
3
|
+
================================================
|
4
|
+
|
5
|
+
CRMF is a Ruby C extension which provides correctly rounded math functions
|
6
|
+
for Ruby floats. CRMF is using [MPFR](https://www.mpfr.org/), and
|
7
|
+
[CRlibm](https://hal-ens-lyon.archives-ouvertes.fr/ensl-01529804/file/crlibm.pdf)
|
8
|
+
when possible.
|
9
|
+
Provided rounding modes are:
|
10
|
+
|
11
|
+
- toward zero,
|
12
|
+
- toward +infinity,
|
13
|
+
- toward -infinity,
|
14
|
+
- to nearest even.
|
15
|
+
|
16
|
+
Documentation
|
17
|
+
-------------
|
18
|
+
|
19
|
+
Documentation is available at <https://www.rubydoc.info/gems/crmf>.
|
20
|
+
|
21
|
+
Building from sources
|
22
|
+
---------------------
|
23
|
+
|
24
|
+
```bash
|
25
|
+
# Clone this repository, build the gem then install it
|
26
|
+
git clone https://gitlab.ensta-bretagne.fr/bollenth/crmf.git
|
27
|
+
cd crmf
|
28
|
+
gem build crmf.gemspec
|
29
|
+
gem install --local crmf-0.1.1.gem
|
30
|
+
# Generate the documentation and open it
|
31
|
+
gem install yard redcarpet coderay
|
32
|
+
yard
|
33
|
+
firefox doc/index.html
|
34
|
+
```
|
35
|
+
|
data/crmf.gemspec
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
require File.expand_path('../lib/crmf/version.rb', __FILE__)
|
2
|
+
|
3
|
+
Gem::Specification.new do |s|
|
4
|
+
s.name = 'crmf'
|
5
|
+
s.version = CRMF::VERSION
|
6
|
+
s.date = Time.now.strftime '%Y-%m-%d'
|
7
|
+
s.summary = 'Correctly rounded math functions for Ruby floats'
|
8
|
+
s.description = 'CRMF is a Ruby C extension which provides correctly rounded math functions for Ruby floats, using MPFR and CRlibm. Provided rounding modes are toward zero, +infinity, -infinity a to nearest even.'
|
9
|
+
s.license = 'GPL-3.0+'
|
10
|
+
s.authors = ['Théotime Bollengier']
|
11
|
+
s.email = 'theotime.bollengier@ensta-bretagne.fr'
|
12
|
+
s.homepage = 'https://gitlab.ensta-bretagne.fr/bollenth/crmf'
|
13
|
+
s.extensions = ['ext/crmf/extconf.rb']
|
14
|
+
s.files = [
|
15
|
+
'LICENSE',
|
16
|
+
'README.md',
|
17
|
+
'crmf.gemspec',
|
18
|
+
'.yardopts',
|
19
|
+
'lib/crmf.rb',
|
20
|
+
'lib/crmf/version.rb',
|
21
|
+
'ext/crmf/extconf.rb',
|
22
|
+
'ext/crmf/crmf.c',
|
23
|
+
'ext/crmf/crmf.h',
|
24
|
+
'ext/crmf/crmf.map',
|
25
|
+
'ext/crlibm-1.0beta4.tar.gz',
|
26
|
+
'tests/perf.rb'
|
27
|
+
]
|
28
|
+
end
|
29
|
+
|
Binary file
|