How do I create an offset shape that is a specific distance from a given circle, in the direction of the origin?

459 Views Asked by At

I'm an amateur engineer, working on a CAD design - but sadly, I'm not a mathematician.
In other words, this question might sound like homework, but it's not, I promise.

I have an existing circle, which has a radius of $23.5$ with the center point being $(0,15)$

I need to write an equation ($s$) which I can input into my CAD software (i.e. no calculus, but algebra is OK), which will draw a continuous shape that is smaller than the existing circle, but is always the EXACT same distance ($d$) away from the circle, when measured across ANY line that passes through the origin $(0,0)$

I think the resulting shape ($s$) should NOT be a smaller circle. It should be an odd shape of some kind, maybe an ellipse or egg or some other type of squished circle?

But that's as much as I know.
I have no idea where to even begin solving this, my trigonometry is way too rusty ...

enter image description here

3

There are 3 best solutions below

1
On BEST ANSWER

I hope your software can accept equation in polar coordinates.

Equation of the circle is $x^{2}+(y-15)^{2}=23.5^{2}$ or $r^{2}\cos^{2}{\theta}+(r\sin{\theta}-15)^{2}=23.5^{2}$ in polar coordinates. From your sketch, the shape is closer to origin by $d$. Therefore we apply transformation $r’=r+d$.

$$ (r+d)^{2}\cos^{2}{\theta}+\left((r+d)\sin{\theta}-15\right)^{2}=23.5^{2} $$

0
On

If we parametrise the shape as $r(\varphi)$, i.e. $$\left\lbrace ~ \begin{aligned} x(\varphi) &= r(\varphi) \cos\varphi \\ y(\varphi) &= r(\varphi) \sin\varphi \\ \end{aligned} ~ \right.$$ or in polar coordinates, $\bigr(\varphi, r(\varphi)\bigr)$, then we know that points $$\left\lbrace ~ \begin{aligned} x^\prime(\varphi) &= \bigr(r(\varphi) + d\bigr) \cos\varphi \\ y^\prime(\varphi) &= \bigr(r(\varphi) + d\bigr) \sin\varphi \\ \end{aligned} ~ \right.$$ must be on the bigger circle. If the radius of the bigger circle is $R$, and it is centered at $(x_o, y_o)$, then $$(x^\prime - x_o)^2 + (y^\prime - y_o)^2 = R^2$$ In other words, $$\biggr(\Bigr(r(\varphi) + d\Bigr)\cos\varphi - x_o\biggr)^2 + \biggr(\Bigr(r(\varphi) + d\Bigr)\sin\varphi - y_o\biggr)^2 = R^2$$ If we solve this for $0 \lt r(\varphi) \in \mathbb{R}$, we get $$r(\varphi) = x_o \cos\varphi + y_o \sin\varphi - d \pm \sqrt{R^2 - (x_o \sin\varphi - y_o \cos\varphi)^2}$$ where you can choose either sign in $\pm$, as long as $r(\varphi) \ge 0$.

Note that most software allows you to draw curves with negative $r$; here, you need to limit to only parts where $r(\varphi) \ge 0$. If your software has a max() function, then you can use

r(a) = max(0, x0*cos(a)+y0*sin(a)-d+sqrt(R*R-(x0*sin(a)-y0*sin(a))*(x0*sin(a)-y0*sin(a))),
              x0*cos(a)+y0*sin(a)-d-sqrt(R*R-(x0*sin(a)-y0*sin(a))*(x0*sin(a)-y0*sin(a))))

If you use Gnuplot, you can use the following to visualize:

set parametric
set size ratio -1
set samples 2000
max3(a,b,c) = (a>=b&&a>=c)?a:(b>=a&&b>=c)?b:c;
r1(t) = cos(t)*x0 + sin(t)*y0 - d + sqrt(R*R - (x0*sin(t) - y0*cos(t))**2);
r2(t) = cos(t)*x0 + sin(t)*y0 - d - sqrt(R*R - (x0*sin(t) - y0*cos(t))**2);
r(t) = max3(0, r1(t), r2(t))

x0=0; y0=1; R=2; d=0.5;
plot x0+R*cos(t),y0+R*sin(t) notitle w lines lc rgb '#000000', \
     x0+(R-d)*cos(t),y0+(R-d)*sin(t) notitle w lines lc rgb '#cccccc', \
     r(t)*cos(t),r(t)*sin(t) notitle w lines lc rgb '#ff0000', \
     0,0 notitle w point lc rgb '#000000' pt 1 

and you can easily test other parameters by putting the last part on a single line, e.g.

x0=0; y0=6; R=7; d=2; plot x0+R*cos(t),y0+R*sin(t) notitle w lines lc rgb '#000000', x0+(R-d)*cos(t),y0+(R-d)*sin(t) notitle w lines lc rgb '#cccccc', r(t)*cos(t),r(t)*sin(t) notitle w lines lc rgb '#ff0000', 0,0 notitle w point lc rgb '#000000' pt 1 

To me, these look like upside-down peaches for small $d$, with the stem towards origin. Or rounded hearts, if you will.

When $d$ gets close to $R$, they look like almonds, with the sharp end towards origin.

x0=0; y0=6; R=7; d=6; plot x0+R*cos(t),y0+R*sin(t) notitle w lines lc rgb '#000000', x0+(R-d)*cos(t),y0+(R-d)*sin(t) notitle w lines lc rgb '#cccccc', r(t)*cos(t),r(t)*sin(t) notitle w lines lc rgb '#ff0000', 0,0 notitle w point lc rgb '#000000' pt 1 
3
On

The equation of the circle is $(x,y)=(r\cos\theta,a+r\sin\theta)$. The question is for the curve $s(x,y)$ such that $(1-s)|(x,y)|=d$. Solving this gives $s=1-\frac{d}{\sqrt{x^2+y^2}}$.

Hence the curve is given by the pseudo-code:

r=23.5; a=15;
x(t):=r*cos(t);
y(t):=a+r*sin(t);
s(t):=1-d/sqrt(x(t)^2+y(t)^2);
plot((s(t)*x(t),s(t)*y(t)),(t,0:2*PI))