I have a question about adding the number 1 to very small numbers. Right now, I am trying to plot a circular arc in the complex plane centered around the real number 1. My code looks like:
arc = 1 + rho .* exp(1i.*theta);
The value rho
is a very small number, and theta
runs from 0 to pi, so whenever 1 is added to the real part of arc
, MATLAB seems to just round it to 1, so when I type in plot(real(arc),imag(arc))
, all I see is a spike instead of a semicircle around 1. Does anyone know how to remedy this so that MATLAB will not round 1 + real(arc) to 1, and instead conserve the precision?
Thanks