MasLiang:

Do they just work like the mathematical formula says?


Yes, they should be implemented using the right mathematical derivatives.
You can find the implementations in derivatives.yaml 5, where these methods are either directly defined or are pointing to the name of the implementation.