Wednesday 30 March 2011

Mathematical Induction

Mathematical induction is a method of mathematical proof typically used to establish that a given statement is true of all natural numbers (non-negative integers). It is done by proving that the first statement in the infinite sequence of statements is true, and then proving that if any one statement in the infinite sequence of statements is true, then so is the next one.
- Stolen from http://en.wikipedia.org/wiki/Mathematical_induction

In my own words. Mathematical Induction is the concept of having a ladder that goes on to infinite. If you know that you can reach the first rung. Then odds are you are able to reach the next rung. If you can reach the "n-th rung", then you can touch the "n+1-th rung". 

I will show how this can prove various equations to show that they are true for all values of your variable.

Ex.

We will prove by Mathematical Induction that the equation 

1+2+...+n = [n(n+1)]/2   is true for all n > 0.

So to start. Let p(n) be the propostion => 1+2+...+n=[n(n+1)]/2

Our objective is to show that p(1) is true(the first value that n can be), and that the conditional statement p(k) implies p(k+1) also denoted as p(k) -> p(k+1), is true for all k > 0.

So we first need to show that the proposition p(n) is true for the very first value of n. In this case 1.
This step is called the Basis step. 

Basis Step: verifying that p(1) is true. As seen by inspection p(1) is true for

1 = [1(1+1)]/2 = 1(2)/2 = 2/2 = 1

Since the basis step is true we move onto the next step called the Inductive step. This is where all the nitty gritty algebra comes into play.

Inductive step: In this step, we assume that p(k) holds for an arbitrary positive integer k. That is we assume that 

1+2+...+k = k(k+1)/2

under this assumption, it must be shown that p(k+1) is true.

To show that p(k+1) is true we first must find what p(k+1) is. 

p(k+1) => 1+2+...+(k+1) = ((k+1)[(k+1)+1]) / 2 = [(k+1)(k+2) ]/2

(k+1)(k+2) / 2 is the equation that we will need to show for our next step . The next step we call the Inductive Hypothesis.

Inductive Hypothesis: This was the hypothesis that if any value of n is true then n+1 must also be true. To show this we write the proposition p(k) as the following.

1+2+...+k+(k+1) = k(k+1)/2 + (k+1)             (we added (k+1) to both sides of this equation)
                                                                     
The idea in this step is to show that the left side can equal the same answer we determined in the Inductive step. 

So as the following working with the left side of the equation.

=   k(k+1)/2  + (k+1) 
=  [  k(k+1) + 2(k+1) ] / 2   (By adding the fractions, the 2 came from the base difference of 1 and 2)


=  [k^2 + k + 2k + 2 ] / 2  (Textbook feels it's unnecessary to skip this step, i find it confusing without)


= [ k^2 + 3k +2 ] / 2 ( By factoring we get)

= [ (k+1)(k+2) ] / 2  (which hopefully looks familiar)

The answer is the same as the Inductive step. Thus proving the hypothesis correct.

So by Mathematical Induction we know that p(n) is true for all positive integers n. That is we have proven that

1+2+...+n = [ n(n+1) ] / 2   for all n>0.   

Tuesday 29 March 2011

My Halo 3 Dueltage

This a montage that features myself(Annihilate)spelled(AnnihiIate) and my former MLG team mate Beware.
I hope you enjoy.



Sunday 27 March 2011

Limits and Continuity

Limits are fundamental for both differential and integral calculus. The formal definition of a derivative involves a limit as does the definition of a definite integral.

The limit of a function(if it exists) for some x-value, a is the height  the function gets closer and closer to as x gets closer and closer to a from the left and the right. Lets take a look at what that even means.

The limit of the function f(x) = 3x + 1 as x approaches 2. When writing a limit we denote this as the following equation.

lim f(x) = lim 3x+1.
x->2         x->2

Now for such an easy limit we can plug in the number 2 and solve this limit. Plugging in the 2 we see.


lim f(x) = lim 3(2)+1  = 7
x->2         x->2


 That the limit is 7. So as x approaches 2 from the left and right side. The limit of this function is 7.

 Now your probably think well that's silly. Any function that's continuous you just plug in and solve for x. Now limits are important for functions with holes.

Definition of a Limit:

lim f(x) exists if and only if

x -> a

1. lim f(x) exists
     x->a- (a from the left side)

2. lim f(x) exists, and
    x->a+(a from the right side)

3. lim f(x) = lim f(x)
    x -> a-      x->a+

Number three is the most important.


A function with an infinite limit and vertical asymptotes.

f(x)  = (x+2)(x-5) / (x-3)(x+1) This function has a VA at x = 3, x = -1

So the lim f(x) = lim (3+2)(3-5) / (3-3)(3+1) =  infinity as x will never reach 0 thus it heads closer to 0
           x-> 3-      x->3-

for infinity.

From the right side the limit will be negative infinity. Thus we know by the limit definition that the limit does not exist for x approaches 3.


Definition of Continuity:

A function is continuous at a point x  = a if the following three conditions are satsified.

1.f(a) is defined
2.limf(x) exists and,
    x-> a
3. f(a) = lim f(x)
              x->a

Limits to Memorize:

lim c = c
x->a

lim 1/x = infinity
x-> 0+

lim 1/x = negative infinity
x-> 0-

lim 1/x = 0
x -> infinity(same for both - and + infinity)

lim sin x/x = 1
x->0

lim cos x - 1/x =0
x->0

lim (1+1/x)^x = e
x -> infinity


Plugging and Chugging Limits:

Any limit where it's continuous and straight forward.

lim (x^2 - 10) = -1
x-> 3

lim 10/x-5= 10/0  if you get an answer that has any numerator thats not zero divided by zero. The limit
x - > 5

does not exist.

Now in the below case if you get 0/0 you have a real limit problem.

lim (x^2 - 25) / (x - 5) = 0/0 which is undefined
x-> 5

undefined is not the limit. This is not the answer we are looking for. Four things we can do to find a limit that is undefined. Calculator, algebra, limit sandwhich, L'Hopitals rule.

I will only show the algebra and L'Hopitals rule. I will not explain L'Hopitals Rule though.

Using algebra to solve for 
lim (x^2-25)/(x-5) we can rewrite this by factoring (x^2 - 5) = (x-5)(x+5) knowing this we can
x-> 5

divide out the (x-5) which leaves us with the equation lim x+5 = 10
                                                                                       x->5

Using L'Hoptials Rule

lim (x^2-25)/(x-5) = lim d/dx(x^2 - 25) / d/dx(x-5) = lim 2x = 10.
x-> 5                        x->5                                             x->5




      





             

Friday 25 March 2011

Boolean Operations

In computer science a Boolean is a primitive data type. This data type consists of whether something is True or False. In this blog 1 or 0.
//section (11.1) personal note

Definitions:
                                                                                                        
The Boolean compliment: 
                                                                 __   __
The negation of  a Boolean. Denoted as  1 or 0.  Spoken as 1(bar) and 0(bar).

 0(bar) = 1
1(bar) = 0

Boolean Addition:

This works exactly like the logical operator OR.

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

Boolean Multiplication:

This works exactly like the logical operator AND.

0*0 = 0
0*1 = 0
1*0 = 0
1*1 = 1

As you can see zeros dominate in any multiplication

Example:
__
 1  *(0+1) = 0 * 1 = 0
(1+1)+(1+0) = 1 + 1 = 1

Wednesday 23 March 2011

Silly itunes

Ever have one of those itune moments where after closing your itune's. The silly program loads back up. So what do you do. You decide to close it because your done with it. But now it becomes even  more persistent and reloads more rapidly. If anyone has experienced this problem with itunes. You know how ridiculously annoying this is. For those who have not had any experience with this problem. You may read, or choose not to. But for those who have this problem. This is a must read blog.

My hypothesis to this problem. Is that the process may have been initially closed, but a linked process related to the itunes process is still running. Then it realizes hey the itunes process was terminated. But i need it to keep running. So i think i'm going to reload it, to make both myself and the itunes process happy.

From my experience with itunes i noticed one of two things. The process itunes.exe, and ituneshelper.exe are closely related to my hypothesis. It seems that these two processes keep wanting to start up if at least one of them is running. Now you can open up task manager and close the processes right from there. Now i have done this with some success, but not always. It seems to be a hit and miss for myself. So i decided well there has to be a solution or atleast a quick fix. So i don't have to keep closing it every 30 seconds it decides to pop up again.

The solution i call a batch file i named SillyItunes. This batch file forcefully ends the processes from the command line and from my experience with this batch that i just wrote. It stops the random reload of itunes to keep popping up with no hope of ever ending it's cycle.

so copy the below source code into a text file. Then save the text file as a .bat instead of a .txt.

Source Code:

-----------------------------------------------------------------------------------------



@ echo off
echo "SillyItunes" a program made by DisposedCheese

echo.
echo.
taskkill /F /T /IM  itunes.exe
taskkill /F /IM ituneshelper.exe
echo.
echo.
echo I hope that solved the problem
echo.
set /p M="Press any key to continue..."



-----------------------------------------------------------------------------------------




Suggestions can be left as a comment. If you think this program is useless. Well so do i. But i still find it to be an easy solution to an annoying problem. A very handy file to keep on the desktop for your itunes mishaps.


Also i am not responsible if your computer takes a random dump on you after using said program.





Tuesday 22 March 2011

Propositional logic and De Morgan's Law

Starting from now till April 6th. I will most likely be posting blogs relating to what i am doing in school. Using writing my blogs as one of the many forms i will use to study for my final exams. Now i have three final exams. One for my major(computer science), and two relating to my math classes. Discrete, and Calculus.
 //Covering (Sec 1.1 - 1.2). personal note
Propositional Logic:

what is a proposition?

A proposition is a statement that is either true or false.
Ex. This is a propositional statement.

Now that we got that covered you can do logic with propostions using logical operators.

Logical Operators:
 ~,->,^,v,⊕,<->.

where NOT is denoted by ~, implication is denoted by ->, AND is denoted by ^, OR is denoted by V,
 Exclusive OR denoted by ⊕, biconditional denoted by <->.

NOT works as a negation. If the propostion p was true. The negation of p denoted ~p would  be false.
 Implication  works as the following. If p then q. Now what this means is if p is true then q is true. Now this also works for if q is true then p must also be true. This is helpful if you have the propostional statement.

If p then dogs can bark. Well we know nothing about the statement p, but since p implies q. We know that q is true therefore p must also be true.

AND works as the following. P^Q. P is true and Q is false then the statement is not true.  P and Q are false the statement is not true. P is false and Q is true the statement is false. The only way a statement with the AND operator is true is if both P and Q are true.

OR works similar to AND. P V Q is true if either P or Q is true. The only time the statement can be false is if both P and Q are false.

Exclusive OR works a bit differently then OR. P V Q is true if only one of P or Q is true. So this proposition can only be false by having both of P and Q false, or both P and Q being true.

 Biconditional works as the opposite of the Exclusive OR. P<-> Q is only true. If both P and Q are true, or both P and Q are false.

Some examples:

Let p, q, r be the propositions:
p: you have the flu
q: you miss the final exam
r: you pass the course

Express P->Q (p implies q).

If you have the flu, then you miss the final exam.

Express Q-> ~R (Q implies the negation of R)

If you miss the final exam, then you do not pass the course.

Express (P-> ~R) V (Q -> ~R) (p implies the negation of R) or (Q implies the negation of R)

If you have the flu, then you do not pass the course or if you miss the final exam, then you do not pass the course.

Now what is the logical operator equation of:

If dogs can fly, then grass is green.

If you answered P -> Q, you were correct. 

Truth Tables:

A truth table is a nice way of keeping track of how a logical operator equation outcomes.

To create a truth table for an equation. You take the propositions.  Denote them by a letter, usually P, Q,R,....Z

Then you create a column on the far left as the following exmaple shows.

 P  ||  Q| Passing each different outcome for P and Q or how every many propositions used.
--------| These outcomes T and False are called Truth Values.
T  ||   T |
T  ||   F |
F  ||   T |
F  ||   F |

So lets make a truth table for  [(P->Q)^(~P)]

 P  ||  Q| ( P -> Q) | ~P  | [ (P -> Q) ^ (~P) ] 
--------|----------------|---------------------
T  ||   T |      T        |   F  |               F
T  ||   F |      F        |   F  |               F
F  ||   T |      T        |   T  |               T

F  ||   F |      F        |   T  |               F

So that is how a truth table works it is great for when you are trying to show that two logical equations are logically equivalent.

 Such as by looking at ( P -> Q) ^ ( P -> R) is equivalent to P -> (Q ^ R)

Now by looking at these two equations you may be able to see that they are equivalent. But for the most part creating a truth table can show and prove that these two are equivalent.


Definitions:

Tautology: A compound proposition that is always true for all truth values.
Contradiction: A compound proposition that is always false for all truth values.

De Morgans Law:
is the way in which the negation of a compound proposition can be rewritten as another equivalent compound proposition.

Examples:

p -> Q equivalent ~P V Q
P -> Q equivalent  ~P - > ~Q
P V Q equivalent ~P -> Q

~(PVQ) equivalent ~P ^ ~Q



 

Saturday 19 March 2011

Your first program in C

Well for anyone who actually reads these, and has an interest for programming. But was never quite sure how to begin. I will go step by step and show you how to begin. Most tutorials on the internet you read shows you the coding. But never shows you anything past that in terms of how to compile(build it), and where to write it(environment).

So first off go and download any version of Visual Studio(the environment i will get you to use). This should be free off many sites.  I am using Visual Studio C++ 2008 express edition if any cares. Now once everything is installed and what not. You should run the program and come to a nice menu. Mine looks like...


Okay from here go to :

1. File/New/Project.
 
2. There will be a column project types. Click on Win32.
     Now in the Templates section. Click on Win32 Console Application.
     Now name your project anything. Lets say "First Program" .

3. It will now ask you questions. Click Next. On this screen make sure the bubble. Application type is
clicked  on Console Application. Also make sure that you click Empty project. The click Finish.

4. You should now be brought to the original menu. But now in your recent projects shows your project name. Now glance to the far right of the menu. There should be a folder named Source Files. Right click this and add new item. Under the categories select Code. In the templates body select the file that has an extension .cp or .cpp. Should be named C file or C++ file.

5. Name this file. I usually just name it the name of my project in most cases. If everything went right you should be looking at a screen similiar to this.

 6. Now to start coding. In that blank white area is where you type your code. So time to write are first program.

# include <stdio.h>

void main()
{
      printf("Hello World\n");
}

There's your first program.

7. Now it's time to build it and run it. At the top there should be a menu build. Click this and build solution. At the bottom will have a bunch of crazy writing appear and then will tell you if the build succeeded. The above code should be error free so it will say succeeded: 1 or something along those lines.

8. Now to run it go to Debug next to build. Then click start without debugging. Enjoy you now have just created a program.


Any questions or you get lost comment.

Friday 18 March 2011

More Minecraft...sadly

Well seeing as the pyramid went well for a post. I figured this post will get similar results hopefully.
This is like a hourglass, but with lava. Behind that you can see a tower that overlooks my surrounding area. There is a floating smiley face above a barely visible roller coaster track made of sponge. Appropriately named the sponge bob express. Random igloo with a small little lookout on it. In the background you can see a wall. This is a castle wall that surrounds the perimeter of my home.

 Here is a structure i made of my guitar. Now i couldn't finish the neck all the way because i hit the sky. But the body is still similar. Behind that is a blue building that needs a logical gate combination to open the doors to get in. Those small blocks and red lines in the background are just a bunch of logic gates.

Thursday 17 March 2011

My Minecraft Pyramid(Math Edition)

So seeing as i just can't go to bed at 4 am like a normal person and wake up for early for a class at 9:30. I figure hey i wonder how many blocks it took me to make that huge pyramid. So i determined a summation for it. First i needed to know how big the pyramid was in height measure by blocks. So starting from the base and all the way up to the top. It was 58 blocks high. Now as far as the width goes. The pyramid is not solid, but instead made of ring layers.The width is always changing by 8 blocks each time starting at the first drop down from the very top block. So as an ACII drawing.



 Layer 0                                  x  = 1
 Layer 1                                xxx = 8 ----aerial view of layer->   xxx As seen 8 blocks to make this ring layer
 Layer 2                              xxxxx = 16                                      x  x
 Layer 3                            xxxxxxx = 24                                     xxx

So starting from the top each layer below the top is 8 blocks or more. We will denote the very top of the pyramid as layer 0.  Now we know each layer is 8 blocks more than the previous layer except in the case that the previous layer is layer 0. So we can create a summation for layers  1 - 58.

 58
Σ      8n              This summation will account for all blocks below layer 0. But what about layer 0. 
n = 1

For layer 0 just add 1 to the summation equation.


       58
1 + Σ      8n     = 1 + 8+16+24+32+40+48+....+ 464        
       n = 1


Well this doesn't exactly give us our answer of how many blocks it took to make the pyramid. But at least it shows how big the base of the pyramid is. A whole 464 blocks. WOW.

Using a graphic calculator. Assuming i know how to use the summation function properly on the calculator. It accumulated a total of 13688 blocks  + 1 block for layer 0. So a grand total of 13689 blocks. KOOL.

There you go bloggers. If you want to create a crazy big pyramid of a height of 58 that reaches the sky limit. You need to have at least 13689 blocks of sandstone.

Wednesday 16 March 2011

My Minecraft Pyramid

Now i have accomplished all kinds of huge structures that for some reason i have not posted or shown to anyone. But at the moment i am currently constructing a massive pyramid that reaches the sky boundary. Now at the moment i have the pyramid built all the way to the sky limit. But as far as the inside goes. This is where i get all hot, sweaty, and excited. I will keep you updated when i am done building the inside full of rooms and traps. Like any good Egyptian movie like the mummy. A pyramid just isn't a pyramid without traps and treasures.

Screen shot of my pyramid(made with the help of flying mods)

Tuesday 15 March 2011

Newtons Method of Square Roots

Today i will be talking about Newtons method for finding square roots. This is somewhat important in the computing world if while programming you have no access to a direct built in function that allows you to calculate the square root of a number. This should never be the case for almost any language will have this function built into some sort of header/library for use. In my case an assignment for my computer science class wanted me to compute a square root using this method. So to start off we first need to know what Newtons Method is.

Newtons method needs your radian(the number you want to take the square root of) and an approximation of what you think the square root is. Now of course your radian has to be a non negative real number as well as your approximation. Your approximation should also logically be less than your radian. This should be a no brainer.

So now we set the equation Newton laid out for use nicely in his method.
Okay i lied to you. I will not use Newtons Method completely for i find for computing the square root we can skip some math steps if we are programming. Anyhow here is my layout.

Let a  = your approximation , x = your radian, epsilon = nothing at the moment.

1. If   a*a-x = 0 then a is obviously your square root.

2.  else  (a*a+x)/(2*a)  = e

Now a  = e. Then go back to the first step and plug away to see if you get a root. 

As an example lets try and find the square root of 5. Our approximation will be 2.

1. 2*2-5  = -1 which does not equal 0.

2. 2*2+5/(2*2) = 9/4 = 2.25. Let a  = 2.25.

 Now back to 1.

1. 2.25*2.25 - 5 = 5.0625 - 5 = .0625 which does not equal 0.

2. 2.25*2.25 +5/(2*2.25) = 10.0625/4.5 = 2.2361111.

Now we can keep doing this as many times as possible until we feel we have a close enough number to the square root of 5. As i pull out the calculator, as this was an on the spot example. The square root of 5 is 2.236067977 which rounded is 2.2361. So our answer suffices for this equation. Hooray for Newton.

Programming applications. Here is a function i wrote that will display this in terms of C++ code for viewing pleasure.


 root = squareRoot(20,radian,1); //function call
/*Function call passing the number of times i would like the formula to simplify answer or try and find it,
The radian(number we want the square root of), and just a basic approx of 1. Doesn't really matter for this.

double squareRoot(int n,double radian,double approx)
{
    if((approx*approx-25)==0)//if our root is a then we will return the root.
    {
        return approx;
    }
    else
    {
        if(n==0)
        {
            return approx;
        }
//if the root was not found above gets a new approximation to work with.
        approx = (approx*approx+radian)/(2*approx);

        return squareRoot(n-1,radian,approx);
    }
}


Now this code example is using recursion, but upon inspection we can see the formula i laid out for you in action. Now using my program that i created for my assignment with the above code being apart of it. Lets calculate some ridiculous large square root.

Lets say 696969696. My program says 26400.2.
Using a calculator we get 26400.18364. Which is just not a simplified answer. 
Thus you can see how accurate you can find the square root of a number using Newtons Method and programming.

Hope you enjoyed this.

DisposedCheese

Monday 14 March 2011

Beat Hazard

I was reading up on my fellow followers blogs. When i read about a certain game my fellow follower was reviewing. This game was Beat Hazard. Now i must say at first glance i thought this game was just a knock off of Geometry Wars.  But no this game is awesomely unique in its own way. The game being a hybrid of geometry wars, any space shooter type game, and asteroids. The catch being. It's flashy and confusing as hell while playing making you really need to focus. But....



The whole game is played and dependent on what music. Music?! you say.Yes music. When you start up the game. The game will ask for a song track. Now a song track can be any music file on your computer or that of one already in game. Once you have selected a song. You can now play that song level. Each song level will be different of course. Now while your playing the game depending on the song. You will be armed with awesome weapons straight from the start or weak guns that leave you vulnerable, depending on how fast the tempo of the song and beat is. Other important things to take note of is the game is scored.



Whilst playing the game you will notice floating circles that you can assume are important to run over. So far upon my run through of the game. I have noticed 3 pick ups. a red on that says pow is to upgrade your weapons to something more powerful. A yellow one that says vol, is to increase the volume of your song(amplifies it). A green one increase your multiplier.Now the object is to kill as much things as possible. Get a great score, and survive the duration of your song. Which is not always easy to do. 



After each game over or survival. The above image is shown with how far you progressed on your song, and the amount of points you got on it. Now this review and explanation was done horribly for this game. But if you looked at the pictures and thought it was good enough for your next acid trip. You can buy the game off, well anything on Google. If you feel like not paying well I'm sure you know what to do. Anyhow it's a great game and everyone should try it out. EDIT: This game is available for PC, and XBLA.

Saturday 12 March 2011

How to create a menu driven DOS program

For those who are wondering how to make some sort of DOS(command prompt) program that continues to allow the user to make commands until they want to quit. We can create a menu driven DOS program. At the end of this tutorial i have a an example of what one can look like.




First lets go to the environment you will make such a program in. Such an environment is simply any text editor. So open up a text editor. Notepad will suffice if you have it. This is where you will type your commands.

Commands:
 The "CLS" command. This command clears the screen of writing. Very important if you want to clear up and make your program more readable or look neater.

The "ECHO" command. This command will allow you to write to the screen. As an example(Ex).

Ex.
ECHO Hello World. Will print Hello World to the screen.
A helpful tip is ECHO. <---period after echo just prints a newline.

The "GOTO" command. This command is most important in this example of the menu driven program. This command is also good if you don't want your program to close as soon as it runs like a DOS program would.

The GOTO can be used to as it says GOTO a certain tag in the program. A tag being lets say :start, and :end.
 To create a tag in your program just put a ":" before the name of the tag.

Ex.
:start
ECHO Hello World
GOTO start
 :end 

This program will go into an infinite loop. For the program will read the line :start, the print Hello World, then GOTO the tag start,from here it will print Hello World, then GOTO the start tag again. You get the idea.

Problem for you. How you would you have this program skip the lines ECHO Hello World, and GOTO start?

If you said put GOTO end, before the echo statement. You are correct!

The "IF" command. This command will allow you to execute statements/commands depending on if a certain condition you set in your IF command is true. We will touch on this after i show you the set command.

The "SET" command. This command will allow you to SET a variable to equal something. For our case we want to use it to create a variable and allow the user to enter a value at choice. For this we use the " /p" statement with SET. As an example

Ex.
SET /p M=

The above example will wait until the user enters a value for the newly created variable M.
 Variables are created and used as data to hold and store values.
You can also have info for your user after the SET command.

Ex.
 SET /p M=Enter a value for some variable M then press Enter:

Now back to the IF command. An example of this command can be seen in the below example.

Ex.
 SET /P=M

IF %M% ==  69 GOTO :start

This example shows the use of how to access a variable and how to write a condition. The condition in the example is shown by %M% == 69. Lets explain whats going on here. The %M% code is how we access the variable M and use it in our condition. The == code is to see if there is an equivalence to the variable M and the number 69. So as the example is stating. IF the variable M is equal to 69 THEN GOTO :start.

These commands are all you will need to use to make a menu driven DOS program.
Before i show my final DOS program for this blog. I will now explain the use of two more commands.

The "START" command. This command is used to well START a file. Now in order to do this we need to be in the same working directory as the file(this is a little more complicated for this tutorial).

Ex. START Minecraft.exe

The "CD" command. This command stands for change directory. Lets say your working directory is
C:\user\somename\, and you want to move to just the D drive. Then you would type:

Ex.
CD D:

Now after learning about all these commands and writing crazy code into a text file . How to we get this program to run. Because honestly DisposedCheese i think your crazy because when i click on the program it just opens the text editor again  to edit.

Well now what we do is we want to change the extension of our text file to a .bat. This convert the  text file into a batch file. A batch file will run using command prompt and execute your lines of code accordingly from top to bottom.

As a result the final menu driven DOS program. Feel free to copy and change things accordingly to make your own. You might want to take the START and CD command out. Also you may want to read the code and see if you can make sense of what is going on. As well as what happens when you enter certain values at the prompts.

Ex Menu Driven DOS Program


CLS
:MENU
ECHO.
ECHO DisposedCheese's Menu
ECHO.
ECHO.
ECHO Entering 0 continues.
ECHO Entering 1 quits.
ECHO Entering 2 starts minecraft.
SET /P M=Type 0, 1 or 2, and enter:
CLS
IF %M%==0 GOTO ZERO
IF %M%==1 GOTO ONE
IF %m%==2 GOTO TWO
IF %M%==9 GOTO END
:ZERO
CLS
ECHO i am glad you wanted to continue.
GOTO MENU
:ONE
CLS
ECHO Why you want to end the batch, too bad.
ECHO if you want to quit type 9 at the prompt.
GOTO MENU
:TWO
CLS
CD C:\some directory\desktop
START Minecraft.exe
GOTO MENU
:END

I hope you enjoy this.

Black Russian Big Muff Pi

Today while browsing kijiji(a site that is like Ebay). I was browsing through the musical instruments sections in look for something i could add to my pedal board. For those who are not quite sure what a pedal board is or another term "pedal". I will begin with what a "pedal" is. A pedal is device that allows you to when stepped on(turn it on) allows the sound of your guitar or bass to change its tone and create a desired sound depending on the pedal. A pedal board is just a collection of all these pedals wired together in a loop or circuit. So you can add multiple effects created from the pedals to your guitar sound. Now of course this is a very basic description of what is actually happening. But for the mean time it will suffice. So today while browsing i found a fuzz (pedal) box. I have never experimented with one of these types of pedals. So i decided hey ill offer on this. The asking price was $80 and being a cheap-o i offered $40.

After a few minutes of bargaining i ended up with $50 for  this pedal. The pedal seeing as i have yet to introduce it, other then in the title. Was a discontinued Black Russian Big Muff Pi made by Electro-Harmonix. Now after i went and picked it up and rushed home to shred with it. The first thing i noticed was the input and output jacks on the back were in reverse order compared to most pedals. Which was kinda fresh and odd for me. So i plugged it in and messed with the knobs. OMG what a great pedal. I have no ways of explaining how soft and heavy the tone can be and how great it sounds regardless of how you turn the knobs. Juts mess around and you will find anything pleasing to the ear. For those that do not have this on their pedal board get it.







The only downside is its a beast in size. But gets the job down in pleasing your ear p*%%y.

Friday 11 March 2011

Calculus Midterm

On March 4th, I wrote a calculus midterm. This midterm was in my terms the only way i was going to pass the class, and take the stress off of what i needed to get on the final exam to pass. Now lets go back another week.I found myself  frantically studying derivatives and integrals and other crazy things i am sure i will never fully comprehend. Knowing damn well at the time that i will most likely fail this midterm and doom my success at being a Jedi knight...The pressure was really on for passing this midterm. But not only passing this midterm, but to achieve at least a 70% on it to make life way easier in the calculus department. Sitting already at 50% coming out of the first semester of calculus, now looking back at how easy it was. The pressure was really on.

I had to sacrifice doing anything social, even playing video games. Even studying for another midterm that was conveniently on the same date.  Thank you math department. All in all i fought hard past the dangerous derivative and illusive integrals to find myself, in a dark place known as RB 2003. Now furiously spewing out as much information as possible onto a calculus midterm. All in all i found myself actually being able to remember how to do the questions. Maybe studying actually pays off (P.S Never really studied before). I felt like i got at least a 70% on this midterm when i went to hand it in. So i know leave the RB 2003, and rejoice out in the hallways as i compare my answers with fellow peers and students. To find out that majority of my answers don't match up with theirs. I now begin to doubt myself and my ability to write math tests. As these people were doing great in the course and knew how to do the material as soon as they looked at it.

I know felt like all my studying was wasted, and that i would be doomed to not be taught the ways of Yoda.



 Until today when i finally got the results. 73%!. Everything went according to plan. I will now most likely pass Calculus. Moral to story for anyone who actually read the whole wall of text. Study hard and never give up. Even if the things you are doing makes no sense. Just keep at it and eventually you will reach your goal.

Thursday 10 March 2011

3rd Prestige in Call of Duty: Black ops

So at the pinnacle of my late night gaming. I finally hit the long fought out 3rd prestige. After slaying countless amount of noobs or people afc(away from controller)....the only way i can get kills. I was now able to restart at level 1 and pull out the M16 as a starter and do the same repetitive cycle of fragging. This is the first time out of all of the COD(call of duty) series i have played the game long enough to reach the 3rd prestige. Be it that i may have not been as distracted by other great games that came out while i was playing the other Call of Duty's. *cough* Halo 3, Gears of War, Gears of War 2, General love for Halo 2 that demanded its play rather than modern warfare. Now it is done and i am happy.


Got to love having that picture next to your gamer tag.

DisposedCheese

First time blogging

Hi world,

I am DisposedCheese. Yes all one word. I like to program, and i like to play video games. This is the majority of what i will be posting about on my blog. I generally play Xbox 360 games and the occasional PC games. If eventually i get followers. Would you kindly post and recommend a certain game you would like myself to talk about. I have played majority of games that have been out for some time and more recent games. At the moment games i am playing our Call of Duty: Black ops (working on 3rd prestige) and Minecraft.Each day i would like to talk about something i may have accomplished in the programming or video game department.

DisposedCheese