Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 956 Categories, Downloaded 50.194.921 Times

Number Grid Search 1.0

  Date Added: May 26, 2013  |  Visits: 332

Number Grid Search

Report Broken Link
Printer Friendly Version


Product Homepage
Download (39 downloads)



Anyone who is interested in puzzle solving using Matlab might appreciate this simple code. It stems from a need to solve a grid puzzle posed by a fellow geocacher here in Australia. (Look to GC2YWE1 Minimax on the geocaching website for further details, or if you don't know what geocaching is :-) The puzzle asks you to find the maximum and minimum values of the sum of elements picked from a 10 x 10 grid of numbers. The rule is that every element must be chosen from a unique row and column. After some head scratching I decided this is a computationally irreducible problem. I am not sure I am correct in this assumption but proceeded on that basis anyway. To solve it you need to calculate all 10! (3,638,800) possible sums and find the limits.The idea struck me that what was required was calculations of the grid trace. Something that Matlab is adept at with the 'trace' function. The sum of the diagonal of the square matrix automatically picks elements with unique rows and columns, and so complies with the geocaching rule. All that was needed was to generate all possible 10! matrices made from the original grid by switching the columns (or the rows), and compute their tracesI found you can generate these matrices using recursion. Working this out how to do this might be a nice exercise for a computer science student :-) I thought I would publish the solution I devised here.Start by calculating the trace of the original matrix setting this as the first value of the maximum (or minimum). The matrix is then circularly rotated column-wise by one, bringing the next column is in the left-most position (column 1). Again Matlab is great to use since there is a versatile circular shift function 'circshift'. The trace is re-calculated and compared to the current maximum (or minimum). A sub-matrix is identified by ignoring the first row and column then the algorithm recursively called until you reach the smallest, bottom right-most 2X2 matrix.This algorithm is undoubtedly not as fast as a nested loop, but quite concise and arguably more fun!

Requirements: No special requirements
Platforms: Matlab
Keyword: Calculating Columnwise Devised Publish Rotated Solution Start Student Thought
Users rating: 0/10

License: Shareware Size: 10 KB
USER REVIEWS
More Reviews or Write Review


NUMBER GRID SEARCH RELATED
Audio Encoders & Decoders  -  SAM Cast Pro 2023.1.0
SAM Cast - Start streaming live audio content with SAM Cast - The #1 live streaming encoder solution. Features built-in advanced audio processor: equalizer, gated AGC, stereo expander, bass EQ, 5-band processor, 2-band processor and clipper....
10.07 MB  
Audio Recorders  -  ePodcast Producer 2.0
ePodcast Producer makes professional podcasting easy even for first-timers. Easy to use, completely integrated professional podcast software system. Record, edit, create RSS feed, upload your podcast,record Skype, customize your interface, all...
7.1 MB  
File Cataloguers  -  Ainvo Disk Cleaner 2.4.3.570
Thank you for using our product. This popular application perfectly removes unnecessary files from computer disks. Thanks to it, thousands of people save to their disks even more of those things that they really need and value. Lots of things can...
2.92 MB  
Utilities  -  Ainvo Duplicate File Finder 2.3.1.271
Thank you for using our product. This popular free application perfectly finds duplicate files. Thanks to it, thousands of people save to their disks even more of those things that they really need and value. Copies of files often just occupy...
3.05 MB  
Utilities  -  Ainvo Disk Cleaner Portable 2.3.2.351
Thank you for using our product. This popular free application perfectly removes unnecessary files from computer disks. Thanks to it, thousands of people save to their disks even more of those things that they really need and value. Lots of things...
3.08 MB  
Multimedia & Graphics  -  packVol Lite 2.8.0
packVol is an Optimization Software for Load Planning, designed to plan the best space utilization inside containers and trucks, to help you reduce your transportation costs. It is an innovative software for MS Windows™, which has some unique...
4.65 MB  
Multimedia & Graphics  -  packVol Standard 2.8.0
packVol is an Optimization Software for Load Planning, designed to plan the best space utilization inside containers and trucks, to help you reduce your transportation costs. It is an innovative software for MS Windows™, which has some unique...
4.8 MB  
Utilities  -  Ainvo Startup Manager 2.3.2.351
Thank you for using our product. This popular free application perfectly edits the startup list. Thanks to it, thousands of people devote more time to what they really like. A long startup list is one of those things that slow down the computer....
3 MB  
Server Tools  -  Webcam 1-2-3 v 3.0
Webcam 1-2-3 is a powerful yet easy to use software to broadcast live video on the web. After installation, you can simply hit a "Publish" button to start the live broadcast on the Internet. Webcam 1-2-3 also supports instant messengers like...
5.84 MB  
Book Collection Managers  -  Ainvo Disk Cleaner Special Edition 2.4.3.570
Thank you for using our product. This popular application perfectly removes unnecessary files from computer disks. Thanks to it, thousands of people save to their disks even more of those things that they really need and value. Lots of things can...
2.94 MB  
NEW DOWNLOADS IN SCRIPTS, DEVELOPMENT TOOLS
Scripts  -  Freelancer Script 5.05
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Post projects. Featured projects. Private projects. Sealed projects. Edit/delete projects. Select freelancers....
5.49 MB  
Scripts  -  B2B Script 4.20
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Sign-up Account (Registration of account). Lead generation tools (for the sellers). Email verification to...
5.49 MB  
Scripts  -  B2C Script 5.06
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). The script comes with totally editable site colors, icons and graphics Multilevel categories allows extensive browsing Admin can change Category ordering or...
5.49 MB  
Scripts  -  Social Networking Script 2.86
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Registration with name, email, password, date of birth etc. User can add multiple school, college, university with start...
5.49 MB  
Scripts  -  Business Networking Script 8.04
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Ajax based interface. Profile creation. Different types of profile. Profile for jobseekers, employers and employed...
5.49 MB  
Development Tools  -  Aml2CHM 3.50
Those who use the popular Aml Pages text editor might be looking out for a way of generating help files from their text and notes. Aml2CHM is a plug-in that was developed to offer people a quick and efficient way of converting Aml Pages documents...
549.99 KB  
Development Tools  -  VMP Viewer 1.0
This is a very rudimentary tool to visualize the VMP files generated by BrainVoyager. Useful to share files with people who do not have BV.
10 KB  
Development Tools  -  Sending reports and timestamped file by emailing 1.0
main executing reference usage:[1] usage_send_mail.mIllustrates email sending with multiple separate files or single timestamped tar file. Attachment failure is properly handled, with continuation of report emailing without the attachment.[2]...
768 KB  
Development Tools  -  IrisMVC 2.0 rc1
IrisMVC is an OOP PHP framework that developers can use as a strong and secure foundation to build on various web applications following the Model-View-Controller (MVC) pattern. It provides the basic functionality developers need, without...
51.2 KB  
Development Tools  -  7-Zip for Script 4.42
7-Zip is a file archiver with a high compression ratio.Features:- High compression ratio in new 7z format with LZMA compression- Supported formats:- Packing / unpacking: 7z, ZIP, GZIP, BZIP2 and TAR- Unpacking only: RAR, CAB, ISO, ARJ, LZH, CHM,...
624.64 KB