CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 10 of 10

Threaded View

  1. #8
    Join Date
    May 2009
    Posts
    2,413

    Re: General Programming Question - Self Enumerating Pangrams

    Quote Originally Posted by nuzzle View Post
    If it's NP-complete which I suspect
    It is indeed. In fact it's quite easily reducible to SAT (Satisfiablility) the first of Karp's 21 original NP complete problems.

    http://en.wikipedia.org/wiki/Karp's_...plete_problems

    The equality in my previous post #6 can be implemented using a logic network consisting of Boolean high-level elements such a ROM memories, adders and comparators which all in their turn can be implemented with simple NAND and NOR gates. This means the logic network constitutes a big Boolean expression. Presented with a Variate input (the 26 letter frequencies in binary form) this network will churn out a single Boolean output telling whether the equality is true or false.

    Finding which inputs to a Boolean expression will yield true is a Satisfiability problem. It's known to be NP complete so the Self-Enumerating Pangram problem should be NP complete too. This means it's a hard problem but also that efficient solution strategies can be sought among general SAT-solvers. But that's a project for another weekend.

    By the way if you're interested in the foundation of computing I can recommend The Golden Ticket by Lance Fortnow. It's a popular science book but it's written by an insider (and not some journalist who's trying to explain what he doesn't understand). It's by far the most accessible still deep book in this category I've ever seen.
    Last edited by nuzzle; April 23rd, 2013 at 10:43 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured