The realroot command attempts to find a real root of A(X) numerically. If no real root can be found, null is returned.
f = x^2-5*x-2; realroot(f,x); -0.372281323269014 realroot(cos(x)-x,x); 0.739085133215161 digits(50); 50 realroot(cos(x)-x,x); 0.7390851332151606416553120876738734040134117589005