Implement uniRootJ for one-dimensional root-finding with derivatives