Potentiometer

Arduino Code

void setup(){
Serial.begin(9600);
}

void loop(){
Serial.print("Value: ");
Serial.print(analogRead(0));
delay(100);
}

Arduino + Unipolar Stepper Motor




Arduino Code (Back & Forth)

#include <Stepper.h>
#define STEPS 400 //360° divided by step angle

Stepper stepper(STEPS, 8, 9);

void setup(){
stepper.setSpeed(30); //RPMs
}

void loop(){
stepper.step(100);
delay(100);
stepper.step(-100);
delay(100);
}


Arduino Code (Back & Forth)

#include <Stepper.h>
#define STEPS 400 //360° divided by step angle
Stepper stepper(STEPS, 8, 9, 10, 11);

void setup(){
stepper.setSpeed(30); //RPMs
}

void loop(){
stepper.step(100);
delay(100);
stepper.step(-100);
delay(100);
}

Arduino + Bipolar Stepper Motor





Arduino Code (Back & Forth)


#include <Stepper.h>
#define STEPS 200 //360° divided by step angle
Stepper stepper(STEPS, 9, 10, 11, 12);

void setup(){
stepper.setSpeed(30); //RPMs
}

void loop(){
stepper.step(100);
delay(100);
stepper.step(-100);
delay(100);
}




L293DNE Dual H-Bridge


Supplier (Jameco)
Datasheet

PNP Transistor

NPN Transistor

Emitter Base Collector

ping))) Ultrasonic Sensor




const int pingPin = 7;

void setup(){
  Serial.begin(9600);
}

void loop(){
  long duration, inches, cm;

  pinMode(pingPin, OUTPUT);
  digitalWrite(pingPin, LOW);
  delayMicroseconds(2);
  digitalWrite(pingPin, HIGH);
  delayMicroseconds(5);
  digitalWrite(pingPin, LOW);
  pinMode(pingPin, INPUT);
  duration = pulseIn(pingPin, HIGH);
  inches = microsecondsToInches(duration);
  cm = microsecondsToCentimeters(duration);
  
  Serial.print(inches);
  Serial.print("in, ");
  Serial.print(cm);
  Serial.print("cm");
  Serial.println();
  
  delay(100);
}

long microsecondsToInches(long microseconds){
  return microseconds / 74 / 2;
}

long microsecondsToCentimeters(long microseconds){
  return microseconds / 29 / 2;
}


Supplier (Jameco)

47Ω Resistor

Supplier (Maplin)

3V DPDT Relay

Supplier (Radio Shack)

7-Segment LED

LED (Light Emitting Diode)

Jumper Wires

Supplier (Sparkfun)

Diode

Electricity can pass from silver to black, but not black to silver.

Breadboard

Supplier (Carnegie Mellon University's Fun With Robots Club)

The input pins on a breadboard are connected row-wise, divided by the gutter; i.e. 1A-1E are connected.

The power pins are connected column wise: canonically the blue column is ground and the red, source.

AA Battery Holder

9V Battery Holder

Arduino Duemilanove

Supplier (Sparkfun)
Developers' Site

Accelerometer ADXL335

Supplier (Sparkfun)

Atomic Number

Symbol is Z.

Equals the number of protons in a given atom.

Each unique atomic number corresponds with an element on the periodic table.

Proton

Symbol is p+.

Subatomic particle with electric charge of +1e.

Mass is 1.672621637(83) * 10-27kg.

Exists as a nucleon in all atoms.

Exists independently as the hydrogen atom, H+.

Number in each atom (atomic number, Z) determines its element.

Composed of two up quarks and one down quark.

Quarks

Symbol is q.

From James Joyce, Finnegans Wake
“Three quarks for Muster Mark!”
Three being a natural organizational number for quarks,
color is also employed as a metaphor.

Elementary particle.

Never exist independently.


Up Quark

Symbol is u.

Elementary particle with electric charge of +2⁄3e.

Have gravitational, electromagnetic, weak, and strong interactions.

Stable quarks.



Down Quark

Symbol is d.

Elementary particle with electric charge of -1⁄3e.

Have gravitational, electromagnetic, weak, and strong interactions.

Stable quarks.

The Four Known Fundamental Interactions


Electromagentism

Causes interaction between electrically charged particles
in areas called electromagnetic fields

And binds (negative) electrons to (positive) protons
which together form atoms
which together form molecules
which are categorized as elements
which together form chemicals
which together form everything we see

A changing electric field generates a magnetic field
and vice-versa
in a process called electromagnetic induction



Strong Interaction

Causes the (netural) neutrons to bind to the (positive) protons and form the nucleus
and quarks to bind to gluons and form nucleons, etc
overriding electromagnetism
The strongest of the Interactions



Weak Interaction

Causes radioactivity through beta decay
(the emission of electrons by neutrons or positrons by the protons in atomic nuclei)

And is due to the exchange of the heavy W and Z bosons



Gravitation

Causes dispersed matter to coalesce

And is due to the curvature of spacetime which governs the motion of inertial objects

Newton's simpler, still reliable theory states:
I deduced that the forces which keep the planets in their orbs must [be] reciprocally as the squares of their distances from the centers about which they revolve: and thereby compared the force requisite to keep the Moon in her Orb with the force of gravity at the surface of the Earth; and found them answer pretty nearly.

MCMC (Markov Chain Monte Carlo)

A class of algorithms used to find the probability distribution of an event given the probabilities of causally linked events.

Random walks are taken through the causal chain,
the results of these walks eventually converging on a stationary distribution within an acceptable margin of error.

Combinatorics

nCr : "from n choose r"

n = length of possibility set (ex. 5 letters)
r = length of combination set (ex. pick 2)



Permutation with Repetition

Order matters and elements of the possibility set can be repeated.

nr

abcde
aaaabacadae
bbabbbcbdbe
ccacbcccdce
ddadbdcddde
eeaebecedee


Permutation without Repetition

Order still matters, but elements cannot be repeated.

n!
(n-r)!

abcde
aabacadae
bbabcbdbe
ccacbcdce
ddadbdcde
eeaebeced


Combination without Repetition

Order does not matter, and elements cannot be repeated.

n!
r!(n-r)!

abcde
aabacadae
bbcbdbe
ccdce
dde
e


Combination with Repetition

Order does not matter, but elements can be repeated.

(n+r-1)!
r!(n-1)!

abcde
aaaabacadae
bbbbcbdbe
ccccdce
dddde
eee