[IAEP] using the insert function block in turtle art

Paul Schulz pschulz01 at gmail.com
Sat Feb 7 08:13:18 EST 2009

Hi Everyone..

On Sat, Feb 7, 2009 at 10:27 PM, Bill Kerr <billkerr at gmail.com> wrote:
> http://tonyforster.blogspot.com/2009/02/using-insert-function-block-in.html
> Tony Forster has used Walter's new insert function block in turtle art to
> program an analog clock

I have been playing with TurtleArt with the aim of producing some
physical 2D models of forces on an object (the turtle).

I have had some initial success:
- with x and y velocity being stored in box1 and box2
 ..constant force problems can be done. eg.
  * projectile turtle
  * charged turtle in a constant electic field
 ..1D position related forces
  * bouncing turtle

I would like to model inverse square law motion as well (turtle in
space) but I hit a couple of problems.

1) I need 'braces' or I need to know more about the way that TurtleArt
calculates expressions..

eg. To calculate the new velocity I need something like..

 new_vx = old_vx - constant * xpos / (xpos *xpos + ypos * ypos )

but I don't have braces '(', to delimit the denominator, and I am
already using box1 and box2 to hold the existing velocity components.

2) I though I could get away without it, but I also need the
'sqrt' (square root) function.


As I'm not actually using the turtle to drew... I am using the 'moveto' the new
location, I have to 'wiggle' the turtle (move forward and back) to make a mark.

- Is there another application I could use?
- How do I pull out my 'program' from sugar on my XO, for saving and sharing.

Any help would be appreciated..

paul at mawsonlakes.org
> _______________________________________________
> IAEP -- It's An Education Project (not a laptop project!)
> IAEP at lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/iaep

More information about the IAEP mailing list