Initial commit from local sources. The C implementation is functional. The C++ implementation needs to be updated