Posts Tagged ‘algorithm’

It’s fairly obvious that the next “advertising” land-rush is in mobile.  Really, it’s been that way for a solid 5 years.   What’s not yet clear is how the marketplace will develop.   Up until the explosion of iphones and android there hasn’t been enough demand (inventory) to put into a marketplace that supports bidding, yield management and the associated structures.   It’s now time.

A couple of clear distinctions between mobile advertising and other mediums is how much more you know about the user and little real estate (display and attention) you can get from the user.   i.e. the targeting has to be GREAT for this to work en masse.

Here are my thoughts on what the basics of the algorithms would be for a great mobile ad marketplace.


Targeting the user isn’t terribly challenging as a great deal of information is available to the advertising engine about a user.   Knowing where someone is and how often they frequent a location and browse certain info reveals pretty much as much as an ad server would need.

Targeting facets:

  • Time of Day
  • Location (lat/long)
  • Demographic (gender, household income, age)
  • Service Provider
  • Phone/Client
  • Connection Speed
  • Segment (business user, soccer mom, etc.)

Yield Management

Targeting only gets you so far.  The most important aspect of “online” advertising isn’t hitting someone right the first go ’round, it’s getting the funnel right.  Can you take someone from initial view/siting/click of an ad through a transaction with the most profit possible?  that is the essential question in advertising.

Yield Management facets:

  • User click history (time of day, location patterns)
  • price per click/action/view
  • advertiser account balance and history
  • Time of Day
  • Location Features (bar district, business, sports complex, etc.)
  • type of advertiser (restaurant, national advertiser, services business, website, application)
  • type of advertisement (offer/coupon, brand ad, registration, etc)

Creative Execution

Beyond getting the math right it’s important to get the creative – the design, content, UI, IA – of an ad correct.  Targeting and yield can only get you so far… if the ad stinks, well, it stinks.  Local ads are of a different type than Super Bowl ads.   What’s good creative in a specific time and location and context isn’t always what wins a CLEO award.

Ad Capabilities:

  • Text only
  • Display
  • Connected to App
  • Click to SMS/private offer
  • Alerts
  • Customized to user info
  • Connected to Inventory Feeds (where it makes sense)


To put the above three in play you need some sense of a bidded marketplace – some way for advertisers to compete for real estate.  Generally that was determined, on older local sites, by very basic algorithms involving who pays the most for the top spot within a category and location (e.g. who pays the top cost per click for Restaurant in NYC gets the top spot).

This approach is no longer sufficient.  The market is there to compete for “top spots.”  However, what’s changed is the concept of top spots.  Owning a keyword on a search engine, even if it’s a “local” search engine doesn’t matter that much and isn’t worth bidding on.   What matters now is are you the ad/sponsor/location/brand that pops up/shows up/is presented when the user passes through a particular latitude+longitude?

Amazingly, the world has been here before.  It’s called a billboard.   Very quickly that’s what local advertising online (in mobile apps) becomes –  a competition for a couple of premium “billboards” in navigation and “check in” apps and social networks.

Bidding algorithm will center on figuring out who pays the most, has the most inventory available and converts the most users over time.  You’ll pay more as advertiser if you are further away, don’t spend enough and/or can’t put buts in seats.  Figuring out how to report those metrics back isn’t that hard as more of our systems (e.g. FB Connect and Open Table and pos systems) become tightly coupled.


If you are still buying online ads based on category and general location keywords or IP location you are wasting your money. And if your ads are still “click” based you are wasting your money.  People don’t click on their mobile phones.  They act.

The Algorithm To Rule Them All (…Locally)

To be published soon!

it goes something like (and this is very much not real math):

show_particular_ad? = category_segment_action_history+historical_action_per_impression*(budget_remaining/cost_per_action) is greater than (other ads values in consideration based on basic relevance of lat/long, keyword, category).

Read Full Post »

[UPDATE  1/10/09:   This post is fairly popular so I assume many people are looking for help on Scramble Squares and potentially hints or solutions.

Sadly, there is no way to shortcut these puzzles.  I suppose if you look at the box, and your box shows you the completed puzzle, you can “cheat” that way.

If you just want to use an already coded “solver”, there are a few out there.  Here’s a good one.

Read the instructions on how to encode your puzzle pieces so the solver can work properly.

Note that puzzles can sometimes have more than 1 solution.

Also note that the algorithmic solvers are not “shortcutting” the puzzle.  They simply try more options than you do much faster.  It’s pretty much just brute force.  A modern computer can run through all 23 billion combinations in 30 seconds (and usually does it faster because it might pick the right center piece early on… which is what the popular algorithm uses as a starting point).

That said, humans can somehow solve these puzzles without “trying” a lot of configurations.  As I discuss below I have some theories how this is possible, but I do not have a definitive answer.]

Here are  some papers, code and blog posts (this is nice one too) on how to algorithmically search for solutions to squzzles/scramble square puzzles.  You might have received one of these puzzles as a holiday gift over the last few years, they were quite popular.

C and Perl Implemenations

General Backtracking Approach

The algorithm is straightforward – just one that searches through solutions.

What’s interesting is that I’ve seen people solve these puzzles, even brand new ones (no prior knowledge), very quickly.  There’s something that happens with a persons vision or something that’s helping them not have to exhaustively search the full solution space.  If I’d seen someone do this once or twice, I’d think it was just lucky picks. (these puzzles have enormous solution spaces (4^8 x 9! = 23,781,703,680 puzzle configurations) )

Is there something in this puzzle that “hints” to a human early in the solution testing that a solution is viable or not.  That is, after 1 or 2 pieces placed, can the human see a promising solution “faster” than the basic algorithm that searches quickly through all piece placements and orientations.  If so, what is that data (“hint”) the human sees and how can we factor it into the algorithm?

Possible hint data:

Rules of thumb on how all these puzzles are printed and cut (do the puzzles all get made with same orientations so exposure to one puzzle provides data on other puzzles?)

Humans can see the whole pattern in parallel even when pieces aren’t lined up so they don’t have to check each piece systematically

Are combinations of pieces eliminated as the humans solve it thus taking them out of future solution attempts, reducing solution space the more the human works on the puzzle

Read Full Post »