yinyang folding into itself

If you have a design you're proud of, share the cfdg file here. It's also a good place to ask for feedback and collaborate.

Moderators: MtnViewJohn, chris, mtnviewmark

Post Reply
hmny
Posts: 6
Joined: Sun Mar 15, 2009 3:21 pm

yinyang folding into itself

Post by hmny »

Hi everyone!

I'm trying to make a wave whichs "tips over" into itself and continues endlessly. Of course my math sucks so I'm just playing around :)

Code: Select all

startshape circle_path

path round {

   MOVETO{y 1}        // required
    ARCTO{y -1 r 1}
     ARCTO{y 1 r 1}
    STROKE{  width 0.01 }
}

path halfround {
	
	MOVETO {  y 1 }
	ARCTO{y -1 r 1}
	STROKE{  width 0.01 }	
}

rule sinus {
	
	halfround { x 1  y 0} 
	halfround { x 1   y -2   r 180  }


}

rule body_wave {

	round { x 0.5  y 0.5  }
	sinus {  s 0.5 flip 180 }  
}

rule circle_path {

	body_wave { }
	body_wave { s 0.5   flip 90  x 0.75 y -0.25 }
	body_wave { s 0.25 x 0.37 y -0.37 }

}
edit: it seems I cant attach the picture ? I have to put it online somewhere myself ?
Last edited by hmny on Tue Mar 17, 2009 8:24 pm, edited 1 time in total.

hmny
Posts: 6
Joined: Sun Mar 15, 2009 3:21 pm

Post by hmny »

Ok! So I made my folding yinyang circle thingie :)

edit: I'm trying to make the top part smaller so the lower parts will
be more visible. maybe I need to use scaling or something. if someone
has a tip to make the top part say 0.25 and the lower part 0.75 size...
(I'll figure it out eventually though... 8) )


Image

Code: Select all

startshape yinyang

path round {

   MOVETO{ y 1}        // required
    ARCTO{ y -1  r 1}
    STROKE{  width 0.01 }
     ARCTO{ y -3   r 1   p cw }
    STROKE{  width 0.01 }
	ARCTO { y 1 }
    STROKE{  width 0.01 }
	MOVETO {  y -3 }
	ARCTO { y 1 p cw } 
    STROKE{  width 0.01 }
	


}


path circle  {

   MOVETO{y 1}        // required
    ARCTO{y -1 r 1}
     ARCTO{y 1 r 1}
    STROKE{  width 0.01 }
}


rule double {
	
	round {}
	circle { s 0.5 } 

}

rule twoshape {
	7 * { flip 90 s 0.5  y -1.5  } double { }
}

rule yinyang  {

	twoshape {} 

	
}


User avatar
Guigui
Posts: 50
Joined: Sat Aug 05, 2006 5:28 pm
Location: Annecy, France

Post by Guigui »

Hi hmny!

That's funny, I'm also playing with the yinyang on my times. Here's an experiment I've done with Processing. Also there's another yinyang topic in this forum.

Also, what do you think of these modifications:

Code: Select all

startshape twoshape

path round { 
   MOVETO{ y 1}
   ARCTO{ y 0  r .5} 
   ARCTO{ y -3   r 1.5   p cw } 
   ARCTO { y 1 } 
   MOVETO {  y -3 } 
   ARCTO { y 1 p cw } 
   STROKE{width 0.01 }
} 


path circle  { 
   MOVETO{y 1}
   ARCTO{y -1 r 1}
   ARCTO{y 1 r 1}
   STROKE{  width 0.05 }
} 


rule double { 
    
   round {} 
   circle { s 0.2 y .5 } 

} 

rule twoshape { 
   7 * { flip 90 s 0.75  y -.75  } double { } 
} 
8^)

hmny
Posts: 6
Joined: Sun Mar 15, 2009 3:21 pm

Post by hmny »

Hey!

Thanks for your reply! Your modifications do make it look more visible for me :)

I saw your expirement! glad I didnt see it when I was trying to make mine would have kept me from wanting to learn howto do it ;)

cool to see there are so many differnt approaches!!

Post Reply