p=sym('5744092954902128823202697');randi([2,p-2])
So I've defined p and tried to compute randi([2,p-2]), Matlab returns: 'Size and range inputs must be numeric.'.
I know it's something to do with the symbolic variable but I do not know why this is happening, nor the solution. Is there a way to do this without converting p to numeric because I don't want to lose precision
THANK YOU!
Best Answer