Added larem and jacobi symbol.