Showing posts with label Circle. Show all posts
Showing posts with label Circle. Show all posts

Wednesday, December 14, 2016

Five Interlaced Moons

Five Interlaced Crescents


Generalization:

Let A and B be two disks with radii a and b.
The set difference A\B is used to plot the moons 
in the following animations.


Animation parameter: the position of B


Animation parameter: b (the radius of B)


Animation parameter: the position of A


Animation parameter: a (the radius of A)


( Mathematical softwares used: gnuplot, GeoGebra )

Four Interlaced Crescents



A cross pattée!







( Mathematical softwares used: Graph, gnuplot )


Related posts:

Triple Crescent Moon

Triple Crescent Moon Symbol
(Boundary curves: circles)


Boundary curves: superellipses with exponent 2.5


Boundary curves: superellipses with exponent 4


A monster face!


Hi!


Exponents: 1.5, 2, 2.5, 3, 3.5, 4


( Mathematical software used: gnuplot )

Sunday, August 7, 2016

How to Draw the Olympic Rings Mathematically?


Inequalities (Relations) for the Olympic Rings:

  1. (Blue Ring)  min(max(R1(x,y), -y), max(R1(x,y), y, -R4(x,y))) < 0
  2. (Black Ring)  min(max(R2(x,y), -y, -R4(x,y)), max(R2(x,y), y, -R5(x,y))) < 0
  3. (Red Ring)  min(max(R3(x,y), -y, -R5(x,y)), max(R3(x,y), y)) < 0
  4. (Yellow Ring)  min(max(R4(x,y), -y, -R1(x,y)), max(R4(x,y), y, -R2(x,y))) < 0
  5. (Green Ring)  min(max(R5(x,y), -y, -R2(x,y)), max(R5(x,y), y, -R3(x,y))) < 0

Functions:
  • R1(x,y) = (sqrt((x+2d)² + (y-h)²) - a)² - b²
  • R2(x,y) = (sqrt(x² + (y-h)²) - a)² - b²
  • R3(x,y) = (sqrt((x-2d)² + (y-h)²) - a)² - b²
  • R4(x,y) = (sqrt((x+d)² + (y+h)²) - a)² - b²
  • R5(x,y) = (sqrt((x-d)² + (y+h)²) - a)² - b²

Constants:
  • a = 49.25
  • b = 4.75
  • d = 58.5
  • h = 25

Download Examples:


( Mathematical softwares used: Graph, gnuplot )

Sunday, June 29, 2014

Sinusoidal Strings - made from a ring of circles

Sinusoidal Strings of Pebbles (r=0.1, n=32)

(r=0.15, n=42)

(r=0.4, n=60)

A ring of circles can be expressed as follows:
x = cos(t-mod(t,s)) + r*cos(n*mod(t,s))
y = sin(t-mod(t,s)) + r*sin(n*mod(t,s))
r=0.1, n=32, s=2*pi/n, t=0...2*pi.

Note that mod(t,s) = t - s*floor(t/s).

gnuplot Examples:


Method 1:
r = 0.1
n = 32
s = 2*pi/n
f(t) = cos(s*floor(t/s)) + r*cos(n*(t-s*floor(t/s)))
g(t) = sin(s*floor(t/s)) + r*sin(n*(t-s*floor(t/s)))
theta(t) = atan2(g(t), f(t))
set terminal wxt enhanced font "Arial, 10"
set xtics ('-2π' -2*pi, '-π' -pi, '0' 0, 'π' pi, '2π' 2*pi)
set xrange [-2*pi-0.4:2*pi+0.4]
set yrange [-pi-0.2:pi+0.2]
set size ratio -1
set samples 10000
set multiplot
set parametric
unset key
do for [k=-2:2:2]{
  plot [-pi:pi] theta(t) + k*pi, f(t) w p pt 0.5 lc rgb "#0099cc"
}
do for [k=-2:2:2]{
  plot [-pi:pi] theta(t) + k*pi, g(t) w p pt 0.5 lc rgb "#ff00ff"
}
unset multiplot


Method 2:
r = 0.1
n = 32
s = 2*pi/n
f(t) = cos(s*floor(t/s)) + r*cos(n*(t-s*floor(t/s)))
g(t) = sin(s*floor(t/s)) + r*sin(n*(t-s*floor(t/s)))
angle(t) = atan2(g(t), f(t))
theta(t) = angle(t - 2*pi*floor((t+pi)/(2*pi))) + 2*pi*floor((t+pi)/(2*pi))
set terminal wxt enhanced font "Arial, 10"
set xtics ('-2π' -2*pi, '-π' -pi, '0' 0, 'π' pi, '2π' 2*pi)
set xrange [-2*pi-0.4:2*pi+0.4]
set yrange [-pi-0.2:pi+0.2]
set size ratio -1
set samples 10000
set parametric
unset key
plot [-4*pi:4*pi] theta(t), f(t) w p pt 0.5 lc rgb "#0099cc", \
                      theta(t), g(t) w p pt 0.5 lc rgb "#ff00ff"


The result plot:

Graph Examples:

  • Method 1 ( sinusoidal_strings_01.grf )
  • Method 2 ( sinusoidal_strings_02.grf )


( Mathematical softwares used: Graph, gnuplot )

Friday, December 6, 2013

Infinite Families of Tangent Circles (3) (無限相切圓系 3)

Type 1.



Equations of the Circles:
(x + a(1 - p^ceil(k/2)))² + (y + b(1 - p^floor(k/2)))² = d^k
a = (1 - r)/(1 + r²)
b = r(1 - r)/(1 + r²)
d = r²
p = -r²
0 < r < 1
k = 0, 1, 2, 3, ....




Type 2.



Equations of the Circles:
(x + a(1 - p^floor(k/2)))² + (y + b(1 - p^ceil(k/2)))² = d(1 - r^(k+1))²
a = r²/(1 + r²)
b = r/(1 + r²)
d = (1/(1-r))²
p = -r²
0 < r < 1
k = 0, 1, 2, 3, ....




Type 3.



Equations of the Circles:
(See the equations for Type 1 and Type 2.)




( Mathematical software used: Graph )

Related posts:

Wednesday, November 27, 2013

Infinite Families of Tangent Circles (2) (無限相切圓系 2)

Type 1.

r = common ratio = 3/4
h = displacement = 0

r = 3/4, h = 1

r = 3/4, h = 0.5

Type 2.

r = 3/4, h = 0

r = 3/4, h = 4

r = 4/5, h = 0.5

Type 3.

r1 = 4/7, r2 = 3/4, h = 0

r1 = 4/7, r2 = 3/4, h = 4

r1 = 4/7, r2 = 3/4, h = 3

r1 = 4/7, r2 = 3/4, h = 3.2

r1 = 5/9, r2 = 4/5, h = 0.5

r1 = 4/7, r2 = 3/4, h = 0.8 ~ 3.2


( Mathematical software used: gnuplot )

Related posts: