The Tales of TreacherousDog

Yarr.

My Photo
Name:
Location: Mesa, Arizona, United States

Just an ASU student venting the frivelous stuff on Blogger.

Monday, August 29, 2005

My new Blog: Jim Jeffers.com

That's right folks I've moved my blog. As I am the one and only Jim Jeffers I find it only fitting to blog with my own name as the title.

Come visit my new blog at: Jim Jeffers.com

Tuesday, January 04, 2005

Infant Formula Market: A Rough Analysis

As I cannot afford to order a professional analysis of the baby food market at this time, I figured now would be a good time to put together my findings from the web in the form of a short article. I'm going to attempt to answer these questions:

  • How big is the infant food industry?
  • What portion of the infant food industry constitutes infant formula powders and liquid concentrates?
  • Approximately, how many actual end users make up the target market?
  • What are some ethical concerns revolving around this industry that we should attempt to address?

How big is the industry?

According to an article found on European site Nutra Ingredient the infant formula industry is just a portion of the overall US ethical nutrition market which grossed approximately $9.1 billion in 2001. This market is in fact dominated by the infant formula segment which made up 39.1% of total market revenues in 2001. The market for infant formula is expected to grow at a rate of approximately 6% and reach $4.9 billion in yearly revenue by 2006.

US demand is primarily supplied by 3 firms: Ross, Mead Johnson (includes Gerber), Wyeth (includes PBM), and Carnation. As of the year 2000 Mead Johnson holds the majority of market share at 52%. Carnation holds the least market mindshare with only 7%. However, it is important to note that Carnation is relatively new to the US market compared to it's competition.

Tuesday, December 21, 2004

Modular Application Management in PHP.

Ok so a certain somebody has been asking me how to go about structuring an application that contains many applications (i.e. a content management system for a web site.) I'm going to breifly explain how I do it from a programming perspecitve. Keep in mind:

  1. This short blurb is going to be done in php / mysql.
  2. I'm no going to go into much detail outside the overall general concepts.
  3. I'm assuming you have a general idea of what I'm talking about. Otherwise this is just going to be a bunch of jibba-jabba.


Let's start by addressing what we need to know. As far as each application is concerned we need to know the name of the application, the type or category the application will be classified, and an optional description of the application and what it does. This information can all be summed up in one table called apps. The table contains an id, name field, category id (we do not store the actual category name itself here), desription

The second table acts as a directory of categories. All we keep here is an id, category name, category description. The description is optional additional information about the category. I don't use descriptio fields much personally, but they do come in handy if you want to make dynamic documentation for your modules and their categories. This table's id field is linked to the category id field in the apps table.

This figure illustrates the table structures:

example tables


So with these two tables it's easy to see you can just grab what you need. For instance to create the main menu of applications you would just query "SELECT cat_id, category FROM categories". Likewise if you wanted to make a submenu displaying alll of the applications in certain category you would just run "SELECT app_id, app FROM apps WHERE category_id=X". You would replace 'X' with the id of the given category.

Advanced!
Handling permissions to applications. You probably saw I included a third table in the figure. Let's say you have a simple authentication system already in place. In that case we would already have the users id on hand. The permissions table simply stores the user id and the application id along with a boolean value. If this value is not equal to 1 we ignore the application becuase the user isn't allowed to see it. An example of a query that would grab all of the information neededwould look like this:

"SELECT
      a.app,
      a.app_id,
      c.category,
      c.category_id
FROM
      apps a,
      categories c,
      perms p
WHERE
      p.app_id=a.app_id AND
      p.access=1 AND
      p.user_id=$user_id AND
      c.category_id=a.category_id
ORDER BY
      c.category_name asc


This query should give you all of the data you need to build a main menu and sub menus containing applications the user has access to. This method is full proof becuase if the user has access to zero applications in category three then the user would not even know about category three if we built menus off the data from this query. One thing worth mentioning, it works best to sort y the category name or id in your query, this is becuase in your for loop you can detect when the category name / id changes with an embedded if statement and take the necessary actions.

In the end this is a really open ended article but I hope it gives you an essential idea of how to go about structuring the data for an application management system.

Thursday, November 25, 2004

Axio 'Swift' Hardpack: Great product...

I have removed this article at the request of Axio. They did not force me, they just asked and I have agreed to remove it.

Wednesday, November 03, 2004

Four More Years... of being misrepresented.

Yesterday millions of voters cast a blind ballot. Choosing to ignore the corruption, arrogance, hypocrisy, and recklessness so proudly displayed over the past four years, America has chosen Bush. America has chosen to look the other way. Instead of addressing the real problems at hand the majority of our population would rather subscribe to the oversimplified absolutism of president Bush's reasoning: Do terrorists hate us because of our freedom? Are we really winning the war on terror? Will society implode if we allow gay people to have civil unions? Is the UN made up of vile creatures who have no other motive but to unite themselves in opposition to the United States?

We made a mistake four years ago. That election was not as clear cut; nobody really liked either candidate. But now, we have seen a president who has made mistake again and again. He has isolated us in the world. He has segregated us from our allies. I know it sounds repetitive but it's true. Why would we vote for a guy who openly tramples over the world. Who goes to war on a whim. Does that represent America? Is it our way or the highway? Do we have the right to jump to conclusions and invade countries just because we think they might be plotting against us? What about the countries that actually are? Do we believe we are god's gift to the world? Can we just go where ever we please and tell alien societies to adopt our way of thinking, our way of reasoning, our way of life?

We have chosen to take four more years down the road that all other fallen empires have taken. A path of arrogance, ignorance, and greed. We will do whatever we want, go wherever we want, and take whatever we want. But eventually we will fall apart from within just like all of the other great nations. A true superpower needs to work with the world to make change. We can't demand, threat, or force the world to become a safe place. We need to work alongside other nations and lead them. Instead, we choose not to support the ICC. We have turned our backs to the UN. We have avoided countless meetings with other free countries about conserving the environment. Quite frankly we just don't care.

I would say that this attitude only represents a minority of our citizens, but it does not. What has happened to this country? Slightly over half of us support such a harmful administration. The cost of their decision affects us all. I never agreed 100% with Kerry or Bush but one critical difference between the two of them was their stance on foreign policy. Our foreign policy represents our country. I no longer feel our country represents people like myself or my peers. I don't believe we are better than the rest of the world. I don't believe today's America represents me or vice versa.

Thursday, September 23, 2004

Paul Krugman's Lecture

I was recently privileged with an opportunity to attend this lecture by Paul Krugman, the author of "The Great Unraveling" and distinguished economics professor from Princeton, share his views at ASU's Gammage auditorium. Although he was preaching to the choir, there were a few conservatives in the audience. Hearing him cite the tactics used by the Bush administration to se deceptive practices in their tax cuts really shocked me and I feel I should share what he told me.

Basically, in Washington most proposals are analyzed in a 10-year window. Meaning, that the tax cuts proposed back in 2001 were said to cost about $350 billion. However, the trick is that the cost analysis was only done for the first 10 years because the bill was designed to expire in 2011. So in actuality if the bill was a permanent it would cost over $800 billion. The problem now is that the last two years, the Bush administration has continued to say "Why isn't this permanent? We need to make it permanent.". They are not mentioning that the $350 billion tax cut that was passed will actually cost more than twice that. Why? Because it's easier to get it passed that way. Now that it's already in affect people aren't aware of the actual long term cost associated with it. In an essence they have used knowingly deceptive practices to get a bill sneaked passed congress and the American public.

Krugman also touched on the methods used by the Bush administration in promoting their ideas. For instance, the spokesman-ship for the first tax cut was based on the foundation that we had a surplus that needed to be distributed. Half way through the year when it became apparent that our surplus had been spent by out of control government spending, the focus shifted to serving as an economic stimulus to maintain the current economy. Then, after it became apparent that the economy was already taking a dive the focus shifted again... the Bush administration said the tax cut would be a sort of foundation for economic recovery. It's no surprise that they have done the same thing with the Iraq war. First it was about terrorism, then it was the WMD, and now it's about liberating Iraq. The focus remains the same but the reasoning is shifting. The real question is why do we allow ourselves to be fooled.

We're stuck in a war that we entered into under the basis of false presumptions and we have a president who's fiscal policy consists of cutting taxes and increasing spending. This type of out of control leadership coupled with tactfully deceptive marketing practices worry me a lot.

Sunday, September 19, 2004

TreacherousDog on Google

Dang, I don't know why but I think this is really really really super cool. If you do a search for 'TreacherousDog' in google you get 30 results. All of which are me in various forums. How cool is that? I totally own this name! However... this blog doesn't come up at all. This makes me sad and depressed. I will have to ask all of my friends to help with my SEO by writing a post about the username TreacherousDog and linking to this post. That would rock.