Sunday, December 15, 2013

Scientific Computing

When I first saw the words “Scientific Computing,” (which was last week, for this blog topic) I thought, “hmm, sounds like a wordy way to say Computer Science”.  Naturally, I google it.  Hmm, not much besides Wikipedia.  I specify, “scientific computing definition.”  Google gives me the ‘web definition’... straight from wikipedia.  After some digging around, I think I understand the term.  Turns out, Scientific Computing (or more commonly, computational science) is not the same as Computer Science.  Computational Science (usually paired with engineering for “CSE”) is a new field that deals with using mathematical models and simulations run by computers to analyze and solve scientific problems (Shodor.org).  Some examples are: 
  • simulating air around a wing to predict which shape will get the most lift
  • performing simulated stress-tests on different “materials” to choose what to make a bicycle frame out of
  • using big data from past weather to create a model to predict future weather
  • simulating blood flow through an aneurysm to quantify how dangerous it will be in the future

Simulated Fluid
I was fortunate to experience the last one in person this summer.  I visited a lab that worked with computational science, and an MRI machine to try to find a better way to deal with aneurysms (an aneurysm is a balloon-like bulge in a blood vessel that can cause a burst and be deadly, especially in the brain).  The head scientist working there showed me how he could use an MRI scan of someone’s brain to create a 3D model of the aneurysm on a computer screen.  He then started a simulation where lines representing blood would rush through.  I could easily observe where stress was on the vessel, and where blood would get collected.  He could simulate years of stress on the the aneurysm in just a few minutes, and assess the severity of the situation.  With computational science, hopefully we can turn something deadly and hard to detect into something that we can find and assess without even a stitch.

Computer Graphics: “How can it get better than THIS?”

Check out this picture from the late 90s.  “Yes, this is an actual PC screenshot.”  This didn’t seem ridiculous when that magazine was published.  “That’s SO real.”  It makes you wonder if we’ll be laughing about the graphics we have now in another 15 years.  “I can’t believe we thought that was good in 2013, HA.”  I certainly hope so.  I always make the joke, “this is higher-res than real life,” or, “the frame-rate's faster than the universe refreshes.”  Well, with some new technology, we’re getting scarily close to being in a second world when we game.

I’m talking about the Oculus Rift.  It’s a virtual-reality headset in development, with over $75 million in funding (digitaltrends).  It has a 7-inch screen that wraps around to provide a field of view more than 90 degrees (basically everything your eye can see).  The screen shows one image for each eye, for stereoscopic 3D.  They don’t completely overlap, however, just like the images our eyes generate in real life.  The outside world is completely blocked out.  

This thing scares me a little, though.  At what point are video games TOO real?  If playing games feels just like real life, except cooler, why would I ever want to not be in the game?  I’m picturing a “Wall-e” type world where we’re all just sitting back with our VR headsets on, with intravenous feeding, blissfully unaware of what’s going on outside.  Still, the new technology is exciting.  I can’t wait to be laughing at what seems amazing right now.

Sunday, December 1, 2013

Communications and Security: What’s Really Important in a Password

Most of us have had an account of ours hijacked.  Maybe it was a friend playing a prank on our facebook page, or maybe it was a malicious hacker using software to crack our online bank account.  We know the importance of a good password.  We know not to make it “qwerty”, or anything on this list.  So how do we make a good password?

Two things: make it hard for a human to guess, and make it hard for a computer to guess.  The first is pretty easy to deal with.  The suggestions we usually hear are: MORE SPECIAL CHARACTERS! MORE RANDOM UPPER CASE! MORE NUMBERS!  That’s great and all, but is it really necessary to make it unguessable by a human (or a computer programmed to check the obvious passwords)?  What are the chances of someone guessing “magentallama”?  Making a password something completely unrelated to your life is just as good as having a bunch of confusing characters (and its less annoying for you!).  

What about the second part of a secure password: making it hard for a computer to guess.  Well, most password cracking software uses brute-force:  “aaaaa”, nope, “aaaab”, nope....  So, yea, maybe some caps and and exclamation point will stall that computer a little.  But what really matters is length.  “af!7#” (5 chars) will be guessed long before “zzzzz” (5 chars) even though we know “zzzzz” seems like a worse password.  Adding 2 characters would make it take 100 times longer; 6 more, a million times longer (actually much more, this would be assuming you only use numbers).  Image a password like, “dogfridgecaropera.”  A program has to go through trillions of combinations before it reaches that.  No caps, no special characters, no numbers, and I seriously doubt any human could ever guess it.  Add in a hyphen, or replace a letter with a number, and even advanced password-guessers that use dictionaries would be stumped for a long time.


The point is, LENGTH is what makes a good password.  So stop with these bogus number, case, and special character requirements, and just up the minimum length of passwords.

Sunday, November 24, 2013

Artificial Intelligence: Cars

I’ve driven i-280 far too many times in my days as a commuter.  The beautiful scenery on that 23 mile stretch is no longer interesting to me.  The drive has become a blur.  It’s almost scary, I’ll get to school, or back home, and think, “how did I get here?”  But sometimes something memorable happens (hopefully not an accident).  One of the coolest things I’ve encountered was this white SUV with this funny-looking contraption that spun a camera overhead.  It had “Google self-driving car” on its side.

Whoa... is that legal?  I stuck with it for a bit.  Its speed was perfectly steady, and it stayed exactly in the middle of the lane.  I got the urge to tailgate it or cut it off to see how it’d react (obviously I didn’t do anything of the sort, drive your death-boxes safely, people!).

I spent the rest of the drive pondering: are autonomous cars the future?  Should we really put our lives directly in the hands of computers?

Yes.  And yes.

The idea is scary at first, but when you look at the data, there’s no question that cars controlled by AI is the way to go.  Google’s self-driving cars record how sharply they break and accelerate.  They also keep track of following-distance.  Based on this data, at a robotics conference in Santa Clara (RoboBusiness 2013), Chris Urmson said, “We’re spending less time in near-collision states.  Our car is driving more smoothly and more safely than our trained professional drivers.”  (MIT Technology Review).  This article from the Tampa Bay Times says that one of Google’s cars has already driven 300,000 miles with no incidents.  The Wall Street Journal says, “At this month's Frankfurt auto show, mega-auto supplier Continental announced a partnership with IBM to help bring autonomous vehicles to market, with "zero accidents" as a possible result. Volvo has promised to injury-proof its cars by 2020.”

I’m looking forward to it.

Sunday, November 17, 2013

The History of Computer Science: C

Out of all the CS classes I’ve taken, the one that I’ve learned most about the history of programming from is my class in C.  Unlike Java, the low-level nature of C allows you to understand what’s happening behind the scenes (memory allocation, etc).  Coding in C is a little bit of a blast from the past, where you can just imagine typing away at a tiny, old, green and black screen.  Today, the language is the most widely used in the world, which is amazing since it was developed in 1972 (yes, that’s almost 41 years ago).

Dennis Ritchie developed C as part of Bell Laboratories in New Jersey.  Many of the key principles C were originated from the BCPL, an earlier language by Martin Richards.  C was also heavily influenced by B (by Ken Thomson in 1970), hence the name.  (A Brief History of C)   However, C improved on B by providing data types (where B was a typeless language). (Ritchie, The Development of the C Language)

In 1978, Brian Kernighan joined Ritchie to write a book called “The C Programming Language,” but programmers know it simply as “K&R.”  To this day, it is the unofficial specification of C.  It was my required text for my C class last semester.

C is so popular because it is portable and has simple syntax, but it still gives the user access to low-level information. (The C Programming Language)  This makes it a great teaching tool.  Everyone should learn some C, as most of the languages we use today borrow from it, including C#, Java, JavaScript, Objective-C, Perl, Python, and obviously C++.


C is the most influential programing language ever.  Even with its usage declining, it is likely to be around for a long time, and its descendants will be around forever.

Sunday, November 10, 2013

File Sharing: How to Fight it?

Since file sharing blew up with Napster in ’99, industries who lose sales of copyrighted material have been in a battle with P2P networks, and their users.  Suddenly, stealing an album or a video-game became easy, and guilt-free.  Why would someone buy anything ever again?

There have been lawsuits about the digital theft of copyrighted material, but it is still everywhere.  You hear of people getting sued for everything they have because of the music they downloaded, but these seem rare an far between.  It’s easy to have the “it’ll never happen to ME” attitude.


Well, some media producers have been fighting file-sharing in other ways, besides litigation.  The amount of copyrighted music illegally downloaded has actually been declining since 2012 (NPD Group).  This is because of new services that have adjusted to the the changes in technology.  The biggest example is Spotify.  Spotify changed the way we consume and pay for music.  It works because they’ve made a service that’s actually MORE convenient than stealing.  You just hop on the app, and you can listen to anything you want, instantly.  For free... well, kind-of free.  Occasionally you are forced to listen to ads between songs.  But you can get rid of them for a small monthly fee, that seems reasonable to a lot of people.  And ta-da!  Music can produce revenue again, and the listeners are happy too.

To combat piracy, industries need to step up their game to make services that are more appealing than breaking the law (with seemingly-low consequences).

Saturday, November 2, 2013

Data Structures: Good for more than just Big Data

Trees, B-trees, AVL trees, lists, queues, stacks, heaps, leftists-heaps...  Merge sort, bubble sort, insertion sort, quicksort...  Good times.  Learning all these in my CS 146 class (Data Structures and Algorithms) was the most fun part of my programming career so far.  But when I was finished with the class, I just couldn’t see where I’d actually be using the knowledge in every-day coding.  I mean, of course it would help me decide between using a language’s library version of a linked list, or a hashmap, or a tree in different scenarios.  But we could have learned that in a week or two, without going in depth.  Why learn exactly how quicksort works?

Van Gogh's "Starry Night"
It’s the same reason an aspiring painter studies Van Gogh.  A programmer today will never have to implement the genius structures and algorithms that are out there (...it’s already done).  Understanding how they work, however, helps you become a better thinker.  We analyze the work of the most clever problem-solvers out there in hopes of becoming better solvers ourselves.


If that’s not good enough, there’s more pressing motivation to learn data structures.  Employers want to know that you understand how your tools work.  Interviewees will almost certainly face questions about data structures.  This link has some of the most popular data structure-related interview questions.  Keep sorting!

Sunday, October 27, 2013

Hacking: The Right Word for SJSU CS?


Any CS major at SJSU will be spending time in MacQuarrie Hall.  A sign caught my eye the first time I set foot on the second floor: “Silicon Valley’s Hacker-Hatchery.”  “Wait, Hacker? Isn’t that a bad thing?”

What the word “hacker” meant to me was pretty close to webster’s definition: “a person who illegally gains access to and sometimes tampers with information in a computer system.”  This is the definition Hollywood prefers.

It turns out the word is much more complicated than that.  There are various classifications of “hackers.”  The stereotypical, criminal, basement-dwelling, hacker who is stealing your credit card informations is a “black hat” hacker.  But there are also “white hat” hackers.  These are people who breach security for good reasons, mainly to try breach before a black hat hacker does, so the vulnerability can be fixed.

The sign at MQH is referring to the word as the programming community (and especially GNU developers) see it: “The use of “hacker” to mean “security breaker” is a confusion on the part of the mass media. We hackers refuse to recognize that meaning, and continue using the word to mean someone who loves to program, someone who enjoys playful cleverness, or the combination of the two.” (About the GNU Project, Richard Stallman)


In the end, I think “hacker” is a great term for what we’re all striving to become in the SJSU CS program.  Unfortunately, it’s easy to be misinformed on the meaning of it, and likely that many people are put off by it because of what they’ve learned from mass media.  Maybe eventually “cracker” will catch on in the mainstream, so that “hacker”’s negative connotation can be completely abolished.



Fun side note: check out this site http://hackertyper.com/ (try spamming capslock and alt)

Sunday, October 13, 2013

Open Source: Collective Effort Leads to Quality

I was fourteen.  I gave in.  I finally downloaded the first episode of that ridiculously popular anime show (Naruto).  Excited to see what all the hype my friends were giving it was about, I double clicked the file.  “QuickTime cannot open files of the type ‘.mov’”.  *Sigh* google-ti
me: “.mov with QuickTime.”  I fiddled with plugins for a while, sifting through over-priced legit ones, and sketchy free ones.  Eventually, I was able to watch the show that I would end up spending an amount of time on that I don’t like to admit.

A year later, a forum recommended VLC media player.  This was my first experience with open source software.  It had me thinking, “How could this possibly be free?”  Everything just worked.  To this day it is some of my favorite software I’ve ever used.

Once someone explained to me what open source was, it all made sense.  Katherine Noyes puts it simply in her article, 10 Reasons Open Source Is Good for Business.  She says, “Which is more likely to be better: a software package created by a handful of developers, or a software package created by thousands of developers?”  With open source, many of the developers are also the users.  They have incentive to make the software great, and not just for profit.


Open source is the way of the future in terms of quality and cost.  It’s a true example of “The Wisdom of the Crowds.”  I can’t wait to contribute to open source projects as I progress as a programmer.

Sunday, October 6, 2013

AGILE: Keeping a Team Productive

“Agile” software development is a group of methodologies that are meant to keep a project running smoothly.  These methodologies include “test driven development”, “extreme programming”, and the “scrum.”

Surveys (such as this one from Shine Technologies) have shown that agile works in “increasing productivity, quality, and business satisfaction,” while lowering cost.  In fact, nearly half of respondents stated that costs were reduced or significantly reduced by agile processes.  A whopping 93% stated that productivity was better or significantly better.

The same survey showed that by far the most used of the Agile processes is “extreme programming”.  Surely, this technique is one of the most important of Agile’s methods.

Extreme programming is a style of development that encourages frequent releases, with a short development cycle for each one (as described by this article).  This means that instead of the entire project being done with all of its feature some time in the (not-so-near) future, the team can release working versions of the most important features right away.  Then they can build upon what they have each cycle (adding features, improving functionality, etc), until the customer is completely satisfied.  The article says, “Extreme Programming emphasizes teamwork. Managers, customers, and developers are all equal partners in a collaborative team. Extreme Programming implements a simple, yet effective environment enabling teams to become highly productive.”


My experience with agile so far has been a positive one, and I’m excited to learn about the other methodologies throughout my programming career.

Friday, September 20, 2013

LinkedIn and Branding: Employer’s are Watching

Branding yourself effectively is essential in today’s labor market.  It’s important to “sell yourself,” and market your skills to land a career that you’re after.  And a huge part of selling yourself to employers is how you appear online.

In 2003, the social networking site, “LinkedIn”  was founded, with the intention of being a place for professionals to connect with ease.  Today, the site has over 238 million registered users with over 3 million business pages [links].  Now that’s some serious opportunity to connect... right?

Well, sort-of.  In What Color is Your Parachute by Richard Boles (2012 edition), Boles says that research has shown that only 4 out of 100 job-seekers who use only the internet to job-hunt are successful.  He does note, however, “If you are seeking a technical or computer-related job... the success rate rises, to somewhere around 10 percent.” (sweet for us CS majors)

I suspect these numbers will go up as services like linkedin improve, and employers get more comfortable with them.  But for now, linkedin is less about job-hunting and more about professional image.  Two of Boles’ “best ways to hunt for a job” are: asking for leads from family members and friends (33% success rate), and knocking on the door of any employer that interests you (47% success rate).  Once you’ve gotten in contact with those employers, then linkedin comes into play.  An employer who is interested and is worth their salt will look you up (especially in computer-related industry), and having a good online impression is key.
The incredibly simple to use Skills section of linkedin


Linkedin continues to make soliciting your value as an employee easier and easier.  It currently functions as a great tool for employers to evaluate prospect employees.  Hopefully soon it’ll become the main place employers look to fill positions in the first place.



Friday, September 13, 2013

QR Codes: Ruined by Poor Usage

When QR codes started popping up everywhere a few years ago, I couldn’t have been more disinterested.  Nothing could convince me to go through the steps to scan a QR code.  “So... it’ll just direct me to a website that I could probably get to anyway with a 2 word google search and a click? No thanks.”  My phone already felt crowded with underused apps, and I didn’t see myself using the QR app frequently enough to justify having it take up space in my menus.

My first QR Code Scan
A few months ago, though, a video game (Guacamelee!) had a secret area with a QR code on the wall.  I caved.  After a minute or two, I finally was able to scan it.  What came up was just text: “Congratulations!  You successfully identified and scanned a QR code! Great Job!”  (A practical joke by the developers of the game).  Needless to say, it took a lot to get me to scan my first QR code, and doing so was a huge let-down.

Since having the app, I’ve scanned a few more QR codes (on product packaging mostly), and all of them have left me thinking, “well, that was a waste.”  Usually it directs me to a generic website (pepsi.com... cool) that’s not optimized for a phone.  QR codes with this function only serve as an annoyance, and leave me wondering why companies bother with them at all.

I tell the story of my experience with QR codes, because I feel like it is just about typical:
check them out once, have a disappointing experience, and almost never scan again.

According to this study by comScore, 50 percent of mobile phone users have scanned a QR code before at least once in their life.  However, the study showed that in the month of June, 2011, only 6.2% of mobile users scanned a code.  So clearly most people who have tried it did not become frequent scanners (or even monthly scanners).  My guess is that many of those 6.2% were first or second-time scanners.

This week I’ve asked a couple dozen friends how many QR codes they’ve scanned before.  Everyone said they’ve scanned once, but the highest count I got was, “about 5.”  No one I asked is a regular scanner.

QR Code for this Blog
Why don’t people become regular scanners?  Companies are using QR codes improperly.  This column on MarketingLand.com sums it up nicely with its list of “5 Reasons for the Death of QR Codes.”  But to me the best point made is, “In many cases, the mobile experience sitting behind the QR code is a disappointment.”  Companies are shelling out QR codes that are conditioning us to be annoyed by them.

So are QR codes useless?  No.  They can awesome when used correctly.  I saw a cool use of them just recently.  In a building at Stanford University, the conference rooms had QR codes on the doors with, “scan for room availability” written under them.  This is actually practical, because that information would be otherwise somewhat tedious to attain.

A comment on the aforementioned column suggests some other uses for QR codes, like one that instantly adds an event to a calendar, or one on a take out menu that initiates a call to the restaurant.  Unfortunately, clever uses like these are rare to find in today’s QR codes.


All in all, the public’s perception of QR codes has been demolished because of their overuse in places where they only make things more difficult.  Often times they feel like a scam; taking advantage of peoples curiosity for some cheap advertising.  QR codes should be used sparingly, and only in situation that truly save the user time.  In my opinion, they’re most useful (and least disappointing) when the user knows what to expect once the scan goes through.

Friday, September 6, 2013

Social Networking Security or Lack of When Promoting Your Brand



I always thought facebook security was simple: don’t be an idiot, and nothing bad will happen.  It seems obvious to me to have a good password that gets changed often, never leave my facebook open where someone else could get to it, etc.  Anyone who isn’t completely computer-illiterate or careless will be fine, right?

This summer I worked for a summer camp (DaVinci Camp) and a huge portion of my job was to update and maintain the facebook page of the camp.  I found it surprisingly difficult, as every single thing I posted must be carefully thought out.  One wrong move can completely change the image of a whole organization in the blink of an eye.  I found myself second-guessing all the time, and taking a long time to make any posts at all.  “What will people think of this?”  “Is this really worth posting?”  I stayed away from liking things entirely.  What if a potential customer doesn’t agree with the page I’m liking?  Still, I thought as long as I was careful, nothing could go wrong.

After reading “A Guide To Facebook Security,” (McCarthy, Watson, Weldon-Siviy) though, I realized just how careful I need to be.  The article talked about one thing that really caught my attention, something I’d never heard of or even thought about before: “likejacking.”  McCarthy says, “One form of clickjacking is to hide a LIKE button underneath a dummy button.  That’s called Likejacking.”  This tricky tactic makes me nervous, as one false step could shift the my whole image, or worse, that of DaVinci Camp, and I wouldn’t even know it.

The solution I suppose would be to log out of the important facebook account unless you’re actively using the page.  McCarthy also says having up-to-date browsers can help prevent clickjacking.  After reading this, I’ve checked my own facebook wall everyday just to make sure that I haven’t “liked” something that I didn’t actually mean to.  The length that sites are willing to go through for a like is sad, and frightening.


Friday, August 30, 2013

Welcome


Welcome to my blog for the Computer Science technical writing course I'm taking at San Jose State this semester.

My name is Andres, and I've been serious about programming since the Spring of 2012.  I love programming because it gives you that sense of creating something that is almost alive.  The "creature" you create is as predictable as anything can get, if you know what you're doing.  It will act EXACTLY as you instruct it to… perfectly.  It will crash and burn perfectly each and every time you tell it to.  And it’s easy to mistakenly ask it to crash and burn.  But once you figure out how to instruct it to do something useful, it is incredibly satisfying.  Soon, your creation is performing its task faster, and more accurately than any human could.  And then, it becomes one giving you instructions.  “Turn left in... one- hundred.. yards”


Most of my experience programming is in Java.  It was the first language I learned, and two of my deeper courses (Data Structures and Algorithms and Object-Oriented Programming) were taught in Java.  However, I’ve also taken a course in C, and I’m in an Advanced C++ Programming class this semester.  I’ve also programmed in Objective C, and Python on my own.