Thursday 5 December 2013

FINALS!

December has arrived and so have final exams!
I know some of my posts have been late, but I have enjoyed writing each one of them as well as, making cool pictures and uploading videos for you guys. I hope you readers also enjoy each one of my entries. From learning how to convert base 2 to base 10 to taking pictures of my laptop and creating  images for you guys  I have had a great time making this  BLOG. 
 I will definitely take computer science into consideration for my future career and thank you guys for viewing my BLOG. 
Good Luck on your exams! 
See you next year!
Happy Holidays!
WE GOT THIS!
(J.E.T.C.)



The Issue of Privacy

Share or not to share? 
Internet privacy has become a huge worldwide issue but is it really that important? Over the past few years the internet has become an  indispensable tool for each one of us. It all started from the desire to find effective ways to just make life easier. As I mentioned in one of my earlier posts  this desire is the reason why we designed such highly advanced programs that are currently used  in several fields for different and specific reasons.  Evolution has lead us to an increase in population growth and economy resulting in a high demand to optimize the use of the internet. Now, that we know the internet helps us accomplish several of our tasks at a much faster rate, the question is how much are we willing to share with the world?  How do we set a limit between family, specific friends and the rest of the world? How do we say "enough" when it comes to our financial account, passwords and scientific research? From any type of application form to changing your bank settings to direct deposit almost everything has been or will eventually be connected to the Internet. How can we minimize the risks of lets say identity theft? A few hours ago I read an article from Fox News titled "NSA reportedly collects 5 billion cell phone location records a day". 

Let's be honest, everyone hates to work under pressure or to be supervised twenty-four hours a day as if you were some sort of criminal or if you're aware of the fact that you do a good job why do you need someone constantly staring at you to "make sure the job is done right"? On the other hand, sometimes it just  has   to   be  done. Truth is, these type of articles have caused outrage among mainly, because people think it's simply a lack of respect to their privacy. Some think that if you don't have anything to hind than... Who cares? Humanity has changed over the years and several tragic historical events could have been stopped if they were tracked down. Governmental Institutions have the dutie to keep us secure. 
Secure-Privacy 
As the title of one of my favorite songs says "Desperate Times Desperate Measures". We , as good citizens are desperate to stop daily criminal behavior that have been the cause of the death of several innocent people. In order to put a stop to this desperate measures have to be taken and yes, that includes "invasion of our privacy". In my opinion, I'm more than OK with it. I don't mind if my information or someone else's is being used by the Goverment for the security of our Nation. I would be more than glad to contribute to determine if our national security is at risk or not. I personally, prefer to know that my private information is the hands of the government  than being leaked into the hands of several commercial companies who's goal may not be to "save countless lives".Now, that is another different topic. As we learned in lecture the only information these companies need from you is your gender, postal code and date of birth. Seriously, people always give that information out. Honestly, I have never taken the time to sit down and think about this but try counting the number of times you have given that information out? How mainy companies might be reveleing your information of commercial reasons. I'm not sure about you but this is completely different to the governments purposes. 




Assignment II (Part II)

The second file was fractal.rkt was even better! In this case the purpose was to increase, decrease the size and complexity of an image depending on the arrow key you decided to press. In my opinion the most difficult thing to fix was the conditions as well as matching up all those parenthesis/brackets! Anyways, once you pressed RUN you were able to see a small pop-up window with a small circle blue outline circle.
Once you pressed the "up", "down", "left" or "right" arrow key the the radius of the circle increased or decreased and well as the complexity. By complexity I mean that, depending on how many time you pressed a specific arrow key you added even more "circles" to the original circle (Figure 2).
The actual output is in the center of this image ( second row, second image from left to right). The other images are just  clones of that one. I felt like making this cool image with the help of these beetled-faced circles. Enjoy.. 

Assignment II

Assignment two was quite interesting. 
When I first opened both  files I wasn't quite sure what would the end product look like. Hopefully, during lecture Professor Heap explained the end product. The descriptions or "hints" were a very useful guide to understand what was I suppose to fix. Although it seemed simple I still went to office hours and this was even more helpful! I definitely encourage you guys to go to office hours and ask questions!
The first file I opened was fx.rkt, the purpose of this was to change the color of the chameleon by averaging the intensities of the color that make up the image. The image is made up of red, green, blue and alpha (the opacity). Depending on which key you decided to press the program would average that specific color. If you decided you press all three keys r, g and b which stand for red, green and blue, respectively you would end up with a black and white image (Figure 1). 
Figure 1. The first "row" represents the original image without any color change. The second row displays what occurred when  the red (r), green (g) and blue (b) keys, respectively, were pressed once. As you can see, for the second row each one of the images have different shades depending on which key was pressed. When you pressed the same key twice it jumped back to the original image, this is way the third row has the exact same images as  row 1.  The last row describes the output of pressing all three keys at the same time, since all three colors where extracted the image displays a black and white chameleon.

Magic.

Recursion.
A way of combining different functions to create various patterns.           
Serp. 

As the number increases so does the size and complexity of the image.

Another example of recuersion with just lines...
If you look at the top right-left corner you can see the difference between 
(s 1) 
which is just a single blue line and as the number increases it starts to rotate,
since further functions are being applied to that single to blue line.

Tuesday 3 December 2013

Addition and Multiplication of Binary Representations

This was considered a challenging topic until I actually took time try and solve it by my own. It was probably challenging since I've never had to do this but once you learn it, it's pretty useful.
Do take a minute to watch this video and try the problem on your own if you are struggling through this topic.
Just to summarize the rules
1. Addition: If the column sums to more than one you carry that one on to the other column. Continue this process every time the sum of a column is higher than 1.
2. Multiplication: Multiply digit-by-digit (just as in base 10). When you reach the "addition stage " follow step 1.

 



Monday 2 December 2013

Base 2 vs Base 10 Part II

As my last video mentioned, the following videos continue to talk about the topic of base 2 to base 10 conversion.
This video is on converting base 2 to base 10.

The following video shows a past test example of converting base 10 to binary(base2). Try pausing the video and solving it on your own and then continue watching the video.

My next video will be on the addition and multiplication of binary representations.