https://github.com/muellan/numeric_map
header-only library of numeric maps for C++14
https://github.com/muellan/numeric_map
cpp cpp14 header-only interpolation map numeric
Last synced: about 1 year ago
JSON representation
header-only library of numeric maps for C++14
- Host: GitHub
- URL: https://github.com/muellan/numeric_map
- Owner: muellan
- License: mit
- Created: 2017-11-10T16:37:35.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-11-10T16:37:59.000Z (over 8 years ago)
- Last Synced: 2025-01-27T11:49:57.036Z (about 1 year ago)
- Topics: cpp, cpp14, header-only, interpolation, map, numeric
- Language: C++
- Size: 38.1 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
AM numeric maps
==============
Header-only library of numeric maps for C++14.
## Quick Overview
### Interpolating Maps
#### ```interpolating_map```
Interpolation function with a ```std::map``` like interface. Each ```{key,value}``` pair is a node (in the mathematical sense) of ```{domain,co-domain}``` values.
Differences to ```std::map```:
- nodes are stored in a sorted, contiguous array (```vector_map```)
- ```operator [] (size_t)``` allows indexed access to the nodes
- ```operator () (const Key& x)``` returns the (interpolated co-domain) value at (domain) point ```x```
### Interpolators
- ```piecewise_constant```
- ```piecewise_linear```
- ```piecewise_log_linear```: piece-wise linear interpolation at position log(x)
### Gradients
Gradients are polymorphic interpolating functions; think "gradient" as in "color gradient".
- ```gradient```: polymorphic base class "interface"
- ```interpolating_gradient```: gradient based on ```interpolating_map```
## Requirements
- requires C++14 conforming compiler
- tested with g++ 6.1