Hi!
I'm going to start every lecture with a promise and an artist to reference.
I promise that by the end of this lecture you'll be able to count to over a million using just your fingers and toes.
I was first drawn to her work by a quote: "To progress in life you must give up the things that you do not like. Give up doing the things that you do not like to do. You must find the things that you do like. The things that are acceptable to your mind."
I think alot of Agnes's work is about counting and remembering, which is why she's perfect for today's lecture - which is on exactly those things!
Today's lecture is titled: Counting and Remembering.
By the end of this lecture, you'll know more about:
- More artists that I think are interesting
- Some thoughts on practice and what it is
- Two references on how to help each other as students
- Counting, specifically counting in Binary
- Computer memory
- How JavaScript remembers different kinds of information also known as data types
- Two films - one about the scale of the universe and the other about really really really really big numbers
I'm going to start this lecture series by teaching you about counting, specifically binary numbers, what they are and why computers use them.
Then I'm going to teach you about how computers remember information. Computers store this information in things called constants (if they never change) or variables (if they change). Constants are useful (for things like Pi or the number of days in a week), but we are going to use variables much more.
All that computers do is remember things by storing data (as constants or variables) and change those memories through commands. One thing they are very good at is remembering a number and then adding to it.
But before we get into how they remember numbers, a few more artists for you and some tips on practice.
Anni
Albers said: "Being creative is not so much the desire to do something as the listening to that which wants to be done: the dictation of the materials." Don't forget to listen to your materials.
Nam June Paik said: "Skin has become inadequate in interfacing with reality. Technology has become the body's new membrane of existence." - let's talk about this in the next session after this lecture.
Some thoughts about practice.
What is Practice? When I thought about it, it helped me alot. I like it because the word has many meanings, like many words. What meanings does it have for you? Have you heard it at UAL alot? What is a practice? What is your practice? What is the question that moves you in a direction? Or in no direction?
My presentation about the future (or my practice) that I gave in Oslo last year.
A pair of thoughts on how to help each other.
Getting
rid of value words by
Airea D. Matthews. I have a strict "don't touch other peoples computers" rule. I'm never going to type for you or fix something for you by doing it for you. Please use the
reading
list, please use my links if you buy. The library should be getting them all, cc me in on an email to them if it isn't working. Lets also discuss alternative ways of reading the material.
Why reading is important.
Now, finally, to counting. What is counting?
Counting is using groups of symbols to represent quantities or amounts. Let's count to 100 in
Decimal. When do
we need an extra digit?
Let's count to 10 in
Unary.
Let's count to 20 in
Binary. When
do we need an extra digit?
What's the biggest number you can count to on your fingers in decimal? What about in binary? What about if you use your fingers AND toes?
Tell the binary joke Joel!
I loved this visualisation of a mechanical binary counter:
Computers use binary to represent everything in
memory. Why? Why is binary well suited to digital computers?
- A bit is a Binary digIT.
- A byte is eight bits. (BEight).
- A kilobyte is 1,024 (2^10) bytes, mostly.
- A megabyte is 1,048,576 (2^20) bytes, mostly.
- One megabyte is approximately one minute of 128 kbit/s MP3 compressed music.
- One megabyte is six seconds of uncompressed CD audio.
- One megabyte is a typical English book volume in plain text format (500 pages × 2000
characters per page).
- The human genome consists of DNA representing 800 MB of data. The parts that differentiate one person from another can be compressed to 4 MB!
- There are different ways of storing numbers and words in computers, as a whole these values
are known as Data types. Data types can be variable or constant - as mentioned earlier.
- Whole numbers or Integers are stored as ints. E.g. 0, 5,
-567.
- Numbers which are in between whole numbers are stored as Floating Points or
floats. E.g. 3.142 or -5.66343.
- As these numbers are stored in certain amounts of memory, if they get too big (or negative,
or precise) the computer can run out of memory to store them, or overflow. This is bad. See
the Y2K bug.
- You can also store individual characters of the alphabet as chars.
- However, there are different encodings of characters - ASCII and Unicode for example - which allow
different character sets to be displayed.
- You can store words (multiple characters) in strings - which are actually just lists of
chars.
- Another name for lists are arrays.
- Strings are one dimensional arrays.
We'll be discussing more about arrays or lists in lecture 5.
- Remember: data can be stored as fixed values (constants) or
values that can change (variables).
Let's try out some JavaScript variables by going through the
JavaScript basic's page on the p5.js wiki, all the way up to the
Math (sic) functions section. You are going to encounter "functions" while I go through the page - they are just ways of packaging up several commands in one bigger command - remember that computers only remember things and change those memories with commands.
All lines in JavaScript must finish with a ";" - it's just a way that the computer works out which line is which.
The two really important things I want you to remember from that is that you can use the "let" keyword to make new data (or variables) - e.g. let myName = "Joel"; and that you can do things with data using commands (or functions) - e.g. console.log(myName);, which prints out the value of myName ("Joel") to the JavaScript console.
- Revision: after this lecture, ask yourself: What is a Data type? What kinds of Data types are there?
- What kind is an int?
- What kind is a string?
- What kind is a float?
- What kind is an array (or list)?
- What kind is a vector?
- What kind is a bool?
- What kind is a queue?
- What kind is a char?
Let's finish with two films about the scale of the universe and the scale of numbers.
Artwork: Powers of Ten by the Eames Office