User Tools

Site Tools


opus:spring2012:dschoeff:start

Dave Schoeffler's Spring 2012 Opus

My last semester at CCC

Introduction

Me

Hey all. My name is Dave Schoeffler but most people call me by my nickname Sheffy. I am a Computer Science major at Corning Community College. This is my 6th and final here at semester at CCC. Once I graduate I will either be transferring to Rochester Institute of Technology or SUNY at Binghamton in the fall. My plan is to get a Bachelors in Computer Science with a Minor in Math and possibly go on to get a Master's in Computer Science, but we will see how long I can put up with school :).

Some more stuff about me

I've enjoyed my experience at Corning so far, mainly because of my awesome teachers. Last semester I took Data Structures and I really enjoyed learning about different methods of storing data. I look forward to using that knowledge to be a better programmer. I currently have my own lawn mowing business to pay the bills but I can't wait to be able to get some computer based job. I am not sure what job field I would like to get into yet but I know I wanna work with computers.

I'm excited to have Joe and Matt team teaching this course cause I think we all will be able to learn alot.

Part 1

Entries

February 9th, 2012

Well let me summarize what we have done so far in class. Our big project this semester is a cpu simulator. We have started this out by building the basic logic gates that everything else will be built on. Yesterday we were introduced to flipflops. Flipflops are these crazy things that I have no idea how they work. I am currently trying to get some understanding of them so I can move on to registers. I am excited even now to see how everything we are doing is building on itself.

February 13, 2012

Today I worked on my first keyword for my opus. As I was thinking, I realized this would be my last first keyword. As I held back the tears I started to define me some logic gates which was pretty fun. I'm still pretty excited about this whole cpu simulator thing. I've been reading more in my book about how we are going to be building everything. Peace out yo!

February 24th, 2012

I'm back dating this entry since I forgot to do it on Friday.

Today in Computer Organization we all discussed a Turing machine. A Turing machine is a device that changes symbols on a infinite strip of tape. It changes these symbols by referencing a table of instructions. This machine can simulate logic that is used in computer algorithms. This theoretical device was imagined by Alan Turing in 1936 and is useful for representing a computer..

Other than that, our class is still working on our CPU simulator. The next steps are building a menu and building registers.

February 28th, 2012

Toady had been fairly productive. I finished up my keywords and have started work on my experiments. I'm kinda struggling with what to do for my experiments though. Some of the experiments I can think of just seem trivial to do. I'll keep thinking about it and come up with something.

I also need to do an objective. Looking at the course objectives, most of them have to do with knowing the assembly language. I think that I still can do one of them at this point.

Well have a happy leap day tmrw!

Keywords

asm Keywords

Logic Operations(AND, OR, XOR)

Definition

Logic operations are represented by logic gates in Computer Science. These gates perform Boolean operations, meaning they get input and produce a single output(usually represented as true(1), false(2)).

The AND operation can be represented by the following true table.

p q p AND q
T T T
T F F
F T F
F F F

A True will be returned iff both inputs are true. Otherwise, the returned value is false.

The OR operation can be represented by the following true table.

p q p OR q
T T T
T F T
F T T
F F F

OR returns False if both inputs are false. Otherwise, it returns true.

The XOR operation can be represented by the following true table.

p q p XOR q
T T F
T F T
F T T
F F F

A true is returned if the inputs are not equal. Otherwise a false is returned.

Demonstration

The following code is attributed to the Computer Organization class.

AND gate
#include "and.h"
 
bool AND::getX()
{
   bool tmp = false;
 
   if((A == true) && (B == true))
   {
      tmp = true;
   }
 
    return tmp;
}
OR gate
#include "or.h"
 
bool OR :: getX()
{
   bool tmp = false;
   if((A == true) || (B == true))
   {
      tmp = true;
   }
   return(tmp);
}
XOR gate
bool XOR::getX()
{
   bool tmp = true;
 
   if((A == B))
   {
      tmp = false;
   }
 
    return tmp;
}

Negated Logic Operations(NOT, NAND, NOR, XNOR)

Definition

Like the title says, Negated logic operations simply negate the output from their logic operator cousins. A NOT gate simply negates whatever input it gets. If it gets as input FALSE, it will output TRUE and vice versa. The other three logic operations can be made by sending there logic operator cousin through a NOT gate.

Demonstration

I will not bother demonstrating all the gates because I think that would be a waste of precious opus space but I think if you understand one of them you will understand the rest. I realize as I write this explanation of why I will not be demonstrating all the negated logic gates that I am wasting opus space in this explanation. Now that we've got that settled, I will demonstrate a NAND gate.

Remember that a NAND gate is a negated AND gate.

#include "nand.h"
 
NAND::NAND()
{
   myandgate = new AND();
   mynotgate = new NOT();
}
 
bool NAND::getX()
{
   bool tmp = true;
 
   myandgate -> setA(A);
   myandgate -> setB(B);
 
   tmp = myandgate -> getX();
 
   mynotgate -> setA(tmp);
 
   tmp = mynotgate -> getX();
 
   return(tmp);
}

The code above sends two inputs into an AND gate and gets an output. It then sends that output into a not gate and returns that Boolean value.

The other two negated logic gates work the same way.

Binary and Hexadecimal Number Representation

Definition

When we think of numbers, we think of 0 1 2 3 4 5 6 7 8 and 9. This is called a base 10(Decimal) number system. But what if instead of have 10 different symbols to represent values, we only had 2. This number system is called Binary. These two values are 0 and 1. Hexadecimal (base 16)on the other hand has 16 different symbols ( 0 1 2 3 4 5 6 7 8 9 A B C D E and F) that represent values.

Demonstration

For example, lets take the decimal number 45. Since this is base 10, the 4 is in the 10^1 place and the 5 is in the 10^0 place and can be represented as (4 * 10^1) + (5 * (10^0) = 45. Representing 45 in binary is different now because there is only two symbols to represent the number. In binary the first placeholder from the right is the 2^0 place followed by 2^1 place and so on. Therefore to represent 45 in binary we have to start with the 2^5 (32) place. Since 32 goes into 45 we place a 1 in that position and subtract 32 from 45 giving us 13. Since 13 doesn't go into the next position(2^4 = 16), we place a 0 in that position and move to the next one. Since 13 goes into 8(2^3) we place a 1 in the position and subtract 8 from 13 giving us 5. We move onto the next position which is (2^2) a see if 5 goes into that. Since it does we place a 1 in that position and subtract 4 from 5 giving us 1 left. Now we look at the 2^1 position and see that 1 does not goes into 2, we place a zero in that position and move onto the final position which is 2^0. Since 1 goes evenly into 1 we place a 1 in the 2^0 position and we are done. We get in binary is 101101 which is equal to 45 in decimal.

To represent 45 in hexadecimal we must look at the place holders for base 16. The rightmost place holder is 16^0 followed by 16^1 and so on. For example 10 in hexadecimal is equal to 16 in decimal. This is because ((1 * 10^1) + (0 * 10^0) = 10). Therefore, the hexadecimal equivalent of 45 is 2D( where D represents 13).

von Neumann vs. Harvard architecture

Definition

von Neumann computer architecture is based around a Central Processing Unit, interaction with a memory device that contains both the instructions and data and sending/receiving data through input/output.

Harvard architecture has physically separate storage and signal pathways for instructions and data.

When you compare these two different architectures, the biggest difference is how the CPU functions. With the von Neumann architecture, the CPU “can be either reading an instruction or reading/writing data from/to the memory. Both cannot occur at the same time since the instructions and data use the same bus system. (Wikipedia)”. Whereas a Harvard computer architecture allows for simultaneous instruction/data reading/writing.

Demonstration

The following pictures show diagrams of how these different architectures work.

Harvard architecture

von Neumann architecture where the memory contains both the data and the instructions

Fetch-Execute Cycle

Definition

The fetch-execute cycle “is the basic operation cycle of a computer. It is the process by which a computer retrieves a program instruction from its memory, determines what actions the instruction requires, and carries out those actions. This cycle is repeated continuously by the central processing unit (CPU), from bootup to when the computer is shut down” (Wikipedia).

The fetch-execute cycle is basically how the computer functions. It starts by retrieving instructions, determine what those instructions mean, and then doing whatever those instructions say.

Demonstration

This picture shows the fetch execute cycle.

Storage

Definition

Computers storage refers to the way computers retain data. Storage comes in several different forms but when broken down, there are two main types of storage. The first type is called volatile storage. Volatile storage requires constant power for it to retain the data it stores. Volatile storage is typically seen in the computers Random Access Memory.

The other main type of storage is non-volatile storage. Unlike volatile storage, non-volatile storage does not require constant power to retain its data. The most common types of non-volatile storage are flash memory, optical storage and magnetic storage.

Demonstration

The following diagram shows how storage functions in the operation of a computer.

Subroutines

Definition

A subroutines(also know as functions, methods, etc…) is a block of code that is used to perform a certain task. This task is usually a task that needs to be repeated. This is useful because having to rewrite that portion of code over and aver again would waste time and space. Instead, a subroutine can be written to perform a certain task. Every time that task needs to be done, we say that you call the function. Once you call the function, the program goes to where the function is in memory and performs the task. Once that is done it either returns a value or if it is a void function it does not return anything.

Demonstration
/*
 * This program uses a function to find the avererage of three numbers
*/
#include<stdio.h>
 
int average(int,int,int);
 
int main()
{
   int a = 1;
   int b = 5;
   int c = 10;
   int ave = 0;
 
   ave = average(a,b,c);
 
   printf("The average of the %d, %d, and %d, is = %d\n",a,b,c,ave);
 
   return 0;
}
int average(int x, int y, int z)
{
   return((x + y + z)/3);
}

Writing a function that finds the average would be useful if you need to find alot of averages.

I/O

Definition

Input/Ouput is how the computer communicates with the outside world.

Common input devices are keyboards, mice, scanners, etc. This is how a user can communicate with the computer.

Common output devices are display monitors and printers. This is how the computer communicates with the user.

Computers are also able to communicate back and forth to each other though I/O. They do do this using NIC's and modems.

Demonstration

I'm not sure just how to demonstrate this keyword but I was thinking that even looking a command line would work.

Through the keyboard I can type a set of characters into the command line and hit enter(me communicating with the computer). It then processes that command and outputs it answer(the computer communicating with me).

lab46:~$ whoami
dschoeff
lab46:~$

asm Objective

asm Objective

Familiarity with the organization of a computer system.

Definition

This objective will require a knowledge of how computers function. This includes memory, storage, processing and I/O to name a few.

Method

I will start to gain a familiarity with the organization of a computer system by reading, writing up keywords, performing experiments and more reading.

Measurement

This is an ongoing process through out the semester. Refer to the keywords I have defined and demonstrated above. Also look at the experiments I have tested.

Analysis

Reflect upon your results of the measurement to ascertain your achievement of the particular course objective.

  • How did you do? I would say i am off to a good start. The class CPU simulator is coming along rather nicely and I am up to date with all my keywords
  • Is there room for improvement? Most definitely.
  • Could the measurement process be enhanced to be more effective?Not that I am aware of.
  • Do you think this enhancement would be efficient to employ?
  • Could the course objective be altered to be more applicable? How would you alter it?It seems rather broad at the moment. Possibly if its scope was narrowed a bit it could be more easily understood.

Experiments

Experiment 1

Question

I don't know if this is a particular question but I will playing around with a fairly new feature in C++. This feature is the auto typed variable. What this allows you to do is create a variable with the keyword auto. The compiler will determine what kinda of variable it is based upon its initializing expression.

I guess I will be testing whether this actually works or not.

Resources

Hypothesis

Based upon my reading of this article, I think the feature will work as expected.

Experiment

I will create a test program that declares variable of different types including the auto type. I will the initialize them to the same value and print out the contents of the variables.

Data

The following is the test program that I wrote.

1
#include<iostream>
 
using namespace std;
 
int main()
{
   int intvar1 = 'a';
   char charvar1 = 'a';
   double doublevar1 = 'a';
   auto autovar1 = 'a';
 
   int intvar2 = 65;
   char charvar2 = 65;
   double doublevar2 = 65;
   auto autovar2 = 65;
 
   int intvar3 = 65.51;
   char charvar3 = 65.51;
   double doublevar3 = 65.51;
   auto autovar3 = 65.51;
 
   cout << "intended value 'a'" << endl;
   cout << "intvar1 = " << intvar1 << endl
        << "doublevar1 = " << doublevar1 << endl
        << "charvar1 = " << charvar1 << endl
        << "autovar1 = " << autovar1 << endl
        << endl;
   cout << "intended value 65" << endl;
   cout << "intvar2 = " << intvar2 << endl
        << "doublevar2 = " << doublevar2 << endl
        << "charvar2 = " << charvar2 << endl
        << "autovar2 = " << autovar2 << endl
        << endl;
   cout << "intended value 65.51" << endl;
   cout << "intvar3 = " << intvar3 << endl
        << "doublevar3 = " << doublevar3 << endl
        << "charvar3 = " << charvar3 << endl
        << "autovar3 = " << autovar3 << endl
        << endl;
 
 
 
   return (0);
}

I then tried to compile this code with the following command and got this error message.

lab46:~$ g++ autotest.cc -o autotest
autotest.cc: In function 'int main()':
autotest.cc:10: error: ISO C++ forbids declaration of 'autovar1' with no type
autotest.cc:14: error: ISO C++ forbids declaration of 'autovar2' with no type
autotest.cc:18: error: ISO C++ forbids declaration of 'autovar3' with no type
lab46:~$

I then talked to Matt about why this was happening and he found out that i needed to include the following argument.

lab46:~$ g++ --std=c++0x autotest.cc -o autotest
lab46:~$

I believe this was to tell the compiler to include the right libraries which it wouldn't do by default.

Once the code was compiled I ran the code.

lab46:~$ ./autotest
intended value 'a'
intvar1 = 97
doublevar1 = 97
charvar1 = a
autovar1 = a

intended value 65
intvar2 = 65
doublevar2 = 65
charvar2 = A
autovar2 = 65

intended value 65.51
intvar3 = 65
doublevar3 = 65.51
charvar3 = A
autovar3 = 65.51

lab46:~$

Analysis

Based on the data collected:

  • Was your hypothesis correct? Yes. The variable behaved as expected.
  • Was your hypothesis not applicable?No
  • Is there more going on than you originally thought? There may be but with the level of the experiment that I ran I am happy with the results.
  • What shortcomings might there be in your experiment? None that I am aware of.
  • What shortcomings might there be in your data? None that I am aware of.

Conclusions

The auto typed variable is just as simple to use as any other type of variable. As of now I am not aware of any big advantages this type of variable has besides dumbing down the programming a bit. Maybe as I explore this more some of those advantages will show themselves.

Experiment 2

Question

I guess this will piggy back of the last experiment. The question I am posing is will a auto typed variable once initialized be able to change types.

Resources

Hypothesis

I believe it will not be able to change data types once initialized.

Experiment

I will write a program that declares and initializes an auto typed variable to an int. I will then try to put different data types in it and see what happens.

Data

Here is the short program I wrote to test my hypothesis.

1
#include<iostream>
 
using namespace std;
 
int main()
{
   auto autovar = 'a';//i will be changing this initialization through my testing proccess.
   cout << "value stored in auto typed variable - > " << autovar << endl;
   cout << "enter value to put in auto typed variable: " ;
   cin >> autovar;
   cout << "value stored in auto typed variable - > " << autovar << endl;
 
   return (0);
}

I then compiled and ran my code.

lab46:~$ ./autotest
value stored in auto typed variable - > a
enter value to put in auto typed variable: b
value stored in auto typed variable - > b
lab46:~$ ./autotest
value stored in auto typed variable - > a
enter value to put in auto typed variable: 7
value stored in auto typed variable - > 7
lab46:~$ ./autotest
value stored in auto typed variable - > a
enter value to put in auto typed variable: 6.234
value stored in auto typed variable - > 6
lab46:~$

I then changes the initialized value to 5.

lab46:~$ ./autotest
value stored in auto typed variable - > 5
enter value to put in auto typed variable: 6
value stored in auto typed variable - > 6
lab46:~$ ./autotest
value stored in auto typed variable - > 5
enter value to put in auto typed variable: a
value stored in auto typed variable - > 5
lab46:~$ ./autotest
value stored in auto typed variable - > 5
enter value to put in auto typed variable: 6.34
value stored in auto typed variable - > 6
lab46:~$

Analysis

Based on the data collected:

  • Was your hypothesis correct?Yes. once initialized to a certain type the variable can't change data types.
  • Was your hypothesis not applicable?No.
  • Is there more going on than you originally thought? Not that I am aware of.
  • What shortcomings might there be in your experiment?None that I am aware of.
  • What shortcomings might there be in your data?None that I am aware of.

Conclusions

Just as expected, once an autotyped variable is given a data type it cannot be changed.

Experiment 3

Question

My final experiment will be whether you can declare an auto variable without initializing it and if so how will it respond.

Resources

Hypothesis

I believe you will not be able to declare the auto typed variable without initializing it.

Experiment

I will write a program that declares an auto typed variable without initializing it. If it compiles, I will then try to store data in the variable and print its contents.

Data

Here is my code.

1
#include<iostream>
 
using namespace std;
 
int main()
{
   auto autovar;
   cout << "enter value to put in auto typed variable: " ;
   cin >> autovar;
   cout << "value stored in auto typed variable - > " << autovar << endl;
 
   return (0);
}

I then tried to compile my code and got this error.

lab46:~$ g++ --std=c++0x autotest.cc -o autotest
autotest.cc: In function 'int main()':
autotest.cc:7: error: declaration of 'auto autovar' has no initializer
lab46:~$ 

Analysis

Based on the data collected:

  • Was your hypothesis correct?Yes. You must initialize the auto typed variable.
  • Was your hypothesis not applicable?No.
  • Is there more going on than you originally thought? None that I am aware of.
  • What shortcomings might there be in your experiment?None that i am aware of.
  • What shortcomings might there be in your data?None that i am aware of.

Conclusions

This experiment has furthered my lack of understanding for why there would be a need for this type of declaration.

If the the variable has to be initialized before compile time, you obviously know what type of variable you will need anyways. Ugh!

Part 2

Entries

March 9th, 2012

It's Friiiiiiiiiiiiiiiiiiiiiiiiiiiiidddddddddddddddddddddaaaaaaaaaaaayyyyyyyyyyyyyyyyyyyyyyyyyyyyy!!!!!

WOOHOO! The best way to start a weekend is by spending that time in the lair. So many magical things happen down here it is incredibal. Today I plan on spending some time doing opus and maybe working on the cpu simulator. Check back later for an update……

March 14, 2012

Today in Comp Org I think we have begun the process of making real progress on our CPU simulator. We have decided on simulating the 6502.

We were talking today about instruction sets and how they relate to the simulator. We have decided that each of out instructions will be four bytes in size. We also have narrowed down what different instructions we will have. This coming Friday we should be able to actually begin to write down our instructions. Once we get that down I think we should be able to move at a much faster pace!

March 15th, 2012

From this day forward, I declare March 15th……… OPUS DAY!!!!!

Today I will be working on my opus cranking out keywords and such. I just finished up the interrupts keyword and I feel I have a better understanding of them now but not to the point I would like. This will require some more study on my part. I think I will also attempt to do the Address Bus and Data Bus keywords as well.

March 28th, 2012

Welcome to my final dated entry for the month. Today I will be working on my opus. I have 5 more keywords to do and the objective and experiments. I have been reading through my book a little bit about registers and instruction sets. I wasn't here on friday but from the looks of the board we have decided on what our instruction set will be. Now it will be up to us to write it and implement it in our simulator.

Keywords

asm Keywords

Interrupts

Definition

Interrupts are changes in the flow of the instruction set. These are not caused by the running program but typically are related to some form of I/O. It is important to note that interrupts are asynchronous, meaning that they do not have to occur at a specific point in time but can executed at various different times.

Demonstration

The following is a paraphrased version of a list of how the interrupt process works at a software level.

  1. The interrupt service routine saves all the registers so they may be restored later
  2. Information about the interrupt, such as status codes are read
  3. I/O error can be handled if that occurred
  4. The global ptr and count variables are updated.The ptr is incremented and the count is decremented to indicate that one less byte remains to be output. If count is greater than 0, there are more characters to be output. Copy the one now pointed to by the ptr variable into the buffer register.
  5. If needed, a special code is output to tell the device that the interrupt has been processed.
  6. Restore all saved registers.
  7. Execute the RETURN FROM INTERRUPT instruction which puts everything back to where it was before the interrupt.

Data Bus

Definition

In computer science a data bus is a system that transfers data different parts of the computer.

Demonstration

Modern buses can use both parallel and bit serial connections and can be wired in many different ways. Without buses there would be no way for data to be transferred between two different pieces of hardware.

For a more in depth description of this check out this link → http://en.wikipedia.org/wiki/Bus_%28computing%29

Address Bus

Definition

An Address Bus is an internal channel from the CPU to memory where addresses are transferred.

Demonstration

The number of wires that this bus contains determines the amount of addressable memory there can be.

for a more detailed description check out this link → http://en.wikipedia.org/wiki/Address_bus

Machine Word

Definition

In Computer Science, a word is a unit of data that is used by a particular processor. It usually is a group of bits handled as a unit by the instruction set. The word size will change depending on what processor you have.

Demonstration

In the case of our instruction set, the machine word is 4 bytes. The Motorola 6800 is an 8 bit processor therefore the word size is 8 bits.

Stack Operations

Definition

There are only two main operation that can be perfromed on a stack. The first one is called push. push allows you to add a piece a data to the top of the stack in memory. The second one is called pop. pop allows you to remove a the topmost piece od data from the stack in memory.

Demonstration

A full demonstation of the operations have been performed by me at this link → http://lab46.corning-cc.edu/opus/fall2011/dschoeff/start#stacks

Registers (General Purpose/Integer, Floating Pointer, Accumulator, Data)

Definition
General Pupose/Integer

These type of registers can hold both data and registers and are used for a variety of purposes.

Floating Pointer

This type of register can hold floating point data values.

Accumulator/Data

This type of register can hold numeric data values, as well as characters, small bit arrays and other data.

Demonstration

Registers (Stack Pointer, Program Counter, Flag/Status)

Definition
Stack Pointer

The stack pointer is used to manage the runtime stack which keeps track of the of where the current program should return control when the subroutine stops runnning.

Program Counter

The program counter is a special purpose register used to point to the current instruction that is being executed in the instruction sequence.

Flag/Status

This regester is a collection of flag bits for the processor. This register contains information about process state. It typically contains at least three flags including zero,carry and overflow.

Demonstration

Registers(Index/Pointer)

Definition

An index register is a processor register used for changing the operand addresses during the runtime of the program.

Demonstration

The contents of an index register is added to an immediate address to form the effective address of the actual data.

asm Objective

asm Objective

Understand the impact of number systems

Definition

This will involve not only knowing about number systems suck as binary and hexadecimal, but also understanding how they play a part in the operation of a computer.

Method

I will achieve this goal by studying how number systems are used in the operation of the computer.

Measurement

I will measure my success by how well I know how number systems function in the operation of a computer

Analysis
  • How did you do? I believe I have a good understanding of binary and hexadecimal.
  • Is there room for improvement? There is always room for improvement.
  • Could the measurement process be enhanced to be more effective? Not that I am aware of.
  • Do you think this enhancement would be efficient to employ? If one were to be implemented then yes.
  • Could the course objective be altered to be more applicable? How would you alter it?It could be narrowed to a specific component of the computer giving more direction as to what to study.

Experiments

Experiment 4

Question

What is the question you'd like to pose for experimentation? State it here.

Resources

Collect information and resources (such as URLs of web resources), and comment on knowledge obtained that you think will provide useful background information to aid in performing the experiment.

Hypothesis

Based on what you've read with respect to your original posed question, what do you think will be the result of your experiment (ie an educated guess based on the facts known). This is done before actually performing the experiment.

State your rationale.

Experiment

How are you going to test your hypothesis? What is the structure of your experiment?

Data

Perform your experiment, and collect/document the results here.

Analysis

Based on the data collected:

  • Was your hypothesis correct?
  • Was your hypothesis not applicable?
  • Is there more going on than you originally thought? (shortcomings in hypothesis)
  • What shortcomings might there be in your experiment?
  • What shortcomings might there be in your data?

Conclusions

What can you ascertain based on the experiment performed and data collected? Document your findings here; make a statement as to any discoveries you've made.

Experiment 5

Question

What is the question you'd like to pose for experimentation? State it here.

Resources

Collect information and resources (such as URLs of web resources), and comment on knowledge obtained that you think will provide useful background information to aid in performing the experiment.

Hypothesis

Based on what you've read with respect to your original posed question, what do you think will be the result of your experiment (ie an educated guess based on the facts known). This is done before actually performing the experiment.

State your rationale.

Experiment

How are you going to test your hypothesis? What is the structure of your experiment?

Data

Perform your experiment, and collect/document the results here.

Analysis

Based on the data collected:

  • Was your hypothesis correct?
  • Was your hypothesis not applicable?
  • Is there more going on than you originally thought? (shortcomings in hypothesis)
  • What shortcomings might there be in your experiment?
  • What shortcomings might there be in your data?

Conclusions

What can you ascertain based on the experiment performed and data collected? Document your findings here; make a statement as to any discoveries you've made.

Retest 2

Perform the following steps:

State Experiment

Whose existing experiment are you going to retest? Provide the URL, note the author, and restate their question.

Resources

Evaluate their resources and commentary. Answer the following questions:

  • Do you feel the given resources are adequate in providing sufficient background information?
  • Are there additional resources you've found that you can add to the resources list?
  • Does the original experimenter appear to have obtained a necessary fundamental understanding of the concepts leading up to their stated experiment?
  • If you find a deviation in opinion, state why you think this might exist.

Hypothesis

State their experiment's hypothesis. Answer the following questions:

  • Do you feel their hypothesis is adequate in capturing the essence of what they're trying to discover?
  • What improvements could you make to their hypothesis, if any?

Experiment

Follow the steps given to recreate the original experiment. Answer the following questions:

  • Are the instructions correct in successfully achieving the results?
  • Is there room for improvement in the experiment instructions/description? What suggestions would you make?
  • Would you make any alterations to the structure of the experiment to yield better results? What, and why?

Data

Publish the data you have gained from your performing of the experiment here.

Analysis

Answer the following:

  • Does the data seem in-line with the published data from the original author?
  • Can you explain any deviations?
  • How about any sources of error?
  • Is the stated hypothesis adequate?

Conclusions

Answer the following:

  • What conclusions can you make based on performing the experiment?
  • Do you feel the experiment was adequate in obtaining a further understanding of a concept?
  • Does the original author appear to have gotten some value out of performing the experiment?
  • Any suggestions or observations that could improve this particular process (in general, or specifically you, or specifically for the original author).

Part 3

Entries

April 4th, 2012

Spring is in the air! The birds are chirping the sun is shining… but I'm in the lair so I can't enjoy any of that. I finished everything in my Opus last month except for the experiments. I really could not think of anything having to with class that I could do an experiment on. I know that the experiments don't have to be related to class but it just seems pointless to do an experiment that has nothing to do with this class. I will work this month on getting to my experiments earlier on so I have more time to think about them.

April 19th, 2012

Today I will be working on my Opus and simulator. Got a little catching up to do but I'll get it done.

April 20th, 2012

It is so nice outside today! Yesterday I did some Opus stuff with boolean arithmetic and dated entries while doing some reading up on registers. Today feels like another fun Opus day. I have 7 more keywords to do so I'll get at it…

April 29th, 2012

I have started work on my EoCE and am going to bang out my keywords the next few days. I'm starting to understand exactly what I have to do for the simulator and I think I won't have too many problems getting most of the stuff working.

asm Keywords

Boolean Arithmetic Operations(Addition, Subtraction, Multiplication, Divide)
Definition

In Boolean algebra, there are only two possible values for any quantity or operation that you may be able to perform on them, a 1 and a 0.

Demonstration

Boolean addition works practically the same way that addition with integers works. Consider the following sums.

0 + 1 + 1 = 1
1 + 1 + 1 = 1
0 + 1 + 1 + 1 = 1
1 + 0 + 1 + 1 = 1

Since you can only represent a quantity by either a one or a zero, the answer for these four equations is 1.

The following pictures show how boolean addition is related to an “or” gate.

There is also Boolean multiplication. This follows the same rules as integer multiplcation. Anything multplied by zero is zero and 1 times 1 is 1. The follwing pictures show the relationship between boolean multiplication and the AND gate.

From my understanding both subtraction and division are invalid boolean operations.

Instruction Sets (CISC, RISC)
Definition

An instruction set is a group of commands that allow a computer to do specific things. These may include instructions to add two registers or branch to another location and perform the instructions there. CISC stands for complex instruction set computing. This means a single instruction can execute several different low-level operations. Risc stands for reduced instruction set computing. This strategy is different than a CISC design because there are fewer, more optimized set of instructions.

Demonstration

Examples of CISC architectures are PDP-11, VAX, and the Motorola 68000.

Examples of RISC architectures areDEC Alpha, AMD 29k and ARM processors.

Data Representation (Big Endian, Little Endian, Size, Integer, Floating Point, ASCII)
Definition

Computers are only able to represent data as one's and zero's. The way those 1's and 0's are grouped or ordered determines the way they are interpreted by the computer.

Demonstration
Big Endian

Big Endian means that the given data unit is ordered from left to right as most significant to least significant.

Little Endian

Little Endian means that the given data unit is ordered from left to right as least significant to most significant.

Size
Integer

Integer data representation can vary between computer architectures. In C, an integer represents a grouping of 4 bytes. This means it can represent the values of −2,147,483,648 to 2,147,483,647 signed and 0 to 4,294,967,295 unsigned.

Floating Point

Floating point is a method of representing real numbers that can support a wide variety of values. It can do this because it represents data in the form Significant digits * base^exponent.

ASCII

ASCII is an encoding scheme that is used to represent characters. In ASCII the character 'A' is signified by the binary number 1000001. ASCII can represent a total of 128 different things.

Control/Data Flow
Definition

Wikipedia says “In computer science, control flow (or alternatively, flow of control) refers to the order in which the individual statements, instructions or function calls of an imperative or a declarative program are executed or evaluated.” It is basically they order that stuff is run by the computer.

Demonstration

By default, the flow of a program is linear. Like sequential statements. This however is not the case in a in an if statement because depending on a certain condition the program can branch to different places.

Linking, Object and Machine Code
Definition

A linker takes a bunch of object files and converts them into a single executable file.

Demonstration

The following diagram shows how this happens.

Data Representation(Sign Representation, One's Complement, Two's Complement
Definition

When computers represent positive and negative numbers, it is different than we represent them by slapping a - in front of it. Computers have different ways of doing this. Two of these ways are One's Compliment and Two's Compliment.

Demonstration
One's Compliment

One's compliment form of a negative binary number is simply the bitwise NOT operation. 00000000 represent 0 and 11111111 represents -0. The decimal number 15 is 00001111 and -15 is 11110000.

Two's Compliment

In two's compliment, there is only one 0 and it is represented by 00000000. The negative of a number is found by negating all the bits then adding 1. 15 is 00001111 and -15 is 11110000 + 1 = 11110001.

Processor & Memory Organization
Definition

A CPU has many different parts: Registers, control unit, ALU, etc…

Demonstration

The control unit has the task of fetching, decoding and managing execution and then storing those results.

Registers allow data to be stored in a convenient place for the processor to handle it.

The ALU performs all the arithmetic operations required.

Data Instructions( Data Movement, Address Movement, Data Conversion, Bit Manipulation)
Definition

Data conversion is simply converting data of one format to another format. This is like when using the static_cast operator to convert a variable of type int to type double or converting an .mp3 to a .wmv file.

The smallest form a data computers can manipulate is a bit. They do this by performing logical operations on them such as AND, OR, NOT and so on.

asm Objective

asm Objective

familiarity with the role of the C library

Definition

I believe this objective entails not only knowing what the C library has to offer but implementing that efficiently in a program

Method

State the method you will use for measuring successful academic/intellectual achievement of this objective.

I will become familiar with the C library by using it frequently and reading more about it.

Measurement

Follow your method and obtain a measurement. Document the results here.

By using the C library of functions frequently, I think I have gained a good understanding of most of the basic functions.

Analysis

Reflect upon your results of the measurement to ascertain your achievement of the particular course objective.

  • How did you do? Coming into this course I thought I had a fairly good understanding of how to use the C library. I gained even more knowledge through the time in this course.
  • Is there room for improvement? By far. I know I have only scratched the surface of what is possible to do with it.
  • Could the measurement process be enhanced to be more effective?I'm not sure.
  • Do you think this enhancement would be efficient to employ?
  • Could the course objective be altered to be more applicable? How would you alter it?Possibly be more specific in the objective. What part of the C library should become more familiar with?

Experiments

Experiment 7

Question

What is the question you'd like to pose for experimentation? State it here.

Resources

Collect information and resources (such as URLs of web resources), and comment on knowledge obtained that you think will provide useful background information to aid in performing the experiment.

Hypothesis

Based on what you've read with respect to your original posed question, what do you think will be the result of your experiment (ie an educated guess based on the facts known). This is done before actually performing the experiment.

State your rationale.

Experiment

How are you going to test your hypothesis? What is the structure of your experiment?

Data

Perform your experiment, and collect/document the results here.

Analysis

Based on the data collected:

  • Was your hypothesis correct?
  • Was your hypothesis not applicable?
  • Is there more going on than you originally thought? (shortcomings in hypothesis)
  • What shortcomings might there be in your experiment?
  • What shortcomings might there be in your data?

Conclusions

What can you ascertain based on the experiment performed and data collected? Document your findings here; make a statement as to any discoveries you've made.

Experiment 8

Question

What is the question you'd like to pose for experimentation? State it here.

Resources

Collect information and resources (such as URLs of web resources), and comment on knowledge obtained that you think will provide useful background information to aid in performing the experiment.

Hypothesis

Based on what you've read with respect to your original posed question, what do you think will be the result of your experiment (ie an educated guess based on the facts known). This is done before actually performing the experiment.

State your rationale.

Experiment

How are you going to test your hypothesis? What is the structure of your experiment?

Data

Perform your experiment, and collect/document the results here.

Analysis

Based on the data collected:

  • Was your hypothesis correct?
  • Was your hypothesis not applicable?
  • Is there more going on than you originally thought? (shortcomings in hypothesis)
  • What shortcomings might there be in your experiment?
  • What shortcomings might there be in your data?

Conclusions

What can you ascertain based on the experiment performed and data collected? Document your findings here; make a statement as to any discoveries you've made.

Retest 3

Perform the following steps:

State Experiment

Whose existing experiment are you going to retest? Provide the URL, note the author, and restate their question.

Resources

Evaluate their resources and commentary. Answer the following questions:

  • Do you feel the given resources are adequate in providing sufficient background information?
  • Are there additional resources you've found that you can add to the resources list?
  • Does the original experimenter appear to have obtained a necessary fundamental understanding of the concepts leading up to their stated experiment?
  • If you find a deviation in opinion, state why you think this might exist.

Hypothesis

State their experiment's hypothesis. Answer the following questions:

  • Do you feel their hypothesis is adequate in capturing the essence of what they're trying to discover?
  • What improvements could you make to their hypothesis, if any?

Experiment

Follow the steps given to recreate the original experiment. Answer the following questions:

  • Are the instructions correct in successfully achieving the results?
  • Is there room for improvement in the experiment instructions/description? What suggestions would you make?
  • Would you make any alterations to the structure of the experiment to yield better results? What, and why?

Data

Publish the data you have gained from your performing of the experiment here.

Analysis

Answer the following:

  • Does the data seem in-line with the published data from the original author?
  • Can you explain any deviations?
  • How about any sources of error?
  • Is the stated hypothesis adequate?

Conclusions

Answer the following:

  • What conclusions can you make based on performing the experiment?
  • Do you feel the experiment was adequate in obtaining a further understanding of a concept?
  • Does the original author appear to have gotten some value out of performing the experiment?
  • Any suggestions or observations that could improve this particular process (in general, or specifically you, or specifically for the original author).
opus/spring2012/dschoeff/start.txt · Last modified: 2012/08/19 20:24 by 127.0.0.1