NetLogo banner

 Home
 Download
 Help
 Resources
 Extensions
 FAQ
 References
 Contact Us
 Donate

 Models:
 Library
 Community
 Modeling Commons

 User Manuals:
 Web
 Printable
 Chinese
 Czech
 Japanese

  Donate

NetLogo User Community Models

(back to the NetLogo User Community Models)

machines-2005

by James Steiner (Submitted: 07/06/2005)

[screen shot]

Download machines-2005
If clicking does not initiate a download, try right clicking or control clicking and choosing "Save" or "Download".(The run link is disabled because this model uses extensions.)

WHAT IS IT?

This model is some kind of physics / machine / links simulation.
I don't know what it is. I started with an idea for a surveryors chain simulation, and it got out of hand. It could be the basis for a rag-doll physics simulation.

It has a nifty drag-n-drop interface for positioning the elements on the work surface. The "selected" element is circled, and can be changed with the property buttons.

When I told someone what I was doing, they asked me "what integrator are you using?" I said, "huh?" Then they started talking about integrals and derivitives and other calculus-y stuff. Well, there is no caculus in this. There is math, there is trigonometry. All very simple.

This model is a great example of "emergent" behavior. All of the cool things that the levers do emerged from the simple code that runs them. This code is mostly concerned with each lever trying rather simple-mindedly to keep its attachment points (hooks) attached to its neighbor's attachement points. Swinging, crumpling, pushing and pulling all emerged from that.

I'm not really sure why it works, but it does. Each element (lever) has two hooks. The levers want to be centered bewteen attached levers. Likewise, they want to point to both attached hooks.

There's to0 much sag. I'm not sure how to keep the levers from seperating. That may just be a limitation of this method.

I had some goals in mind when I started. I wanted the elements to exhibit these behaviors.

Design goals:

1. "fixed" nodes spin in response to movement of the chain.
2. the chain "dangles" relisticly.
3. the chain links respond to each other, bunching up or stretching out, as appropriate.
4. When stretched and plucked, the chain will vibrate, like a guitar string.
4a. Stretching can be turned off, ie, be a feature, rather than a bug.
5. Conservation of linear momentum.
6. Conservation of angular momemtum.
7. Pendulum behavior.

Other Stuff:
Levers can have different lengths
Levers can be fixed or free
Levers can be driven (spin? = true)
Spinning Levers are still affected by attached Levers
Bigger levers are heavier

Surprises:
Without trying to, all the behaviors emerged, more or less.

Gravity affects things a great deal.
Also, friction (thought only present in a very small range) can also cause significant behavior changes.

New: based on a modification sent to me by Seth Tisue, I added sound to this version.

(back to the NetLogo User Community Models)