Commits

Shlomi Fish committed 4e5e248

Change comments containing "A*" to "BeFS".

git-svn-id: file:///home/shlomif/Backup/svn-dumps/google-code/svnsync-repos/fc-solve/trunk@2862 e7e8a897-7ba4-4ee7-b36f-f4c66519b19a

Comments (0)

Files changed (5)

fc-solve/source/USAGE.txt

 
 This option (assuming the -s and -i options are specified) will also
 display the iteration index of the state from which the current state
-was derived. This is especially useful for A* or BFS scans.
+was derived. This is especially useful for BeFS (so-called +a-star+) or
+BFS scans.
 
 -o [filename] , --output [filename]
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 that do not belong to any group, are processed in a non-random manner.
 
 
--asw [A* Weights] , --a-star-weight [A* Weights]
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+-asw [BeFS Weights] , --a-star-weight [BeFS Weights]
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 Specify weights for the +a-star+ (= "Best-First Search") scan, assuming it is 
 used. The parameter should be a comma-separated list of numbers, each one is 
 $ fc-solve --method a-star -nst --method soft-dfs -to 0123467 myboard.txt
 ----------------------
 
-will run an A* scan and a Soft-DFS scan with a tests order of 0123467 on
+will run an BeFS scan and a Soft-DFS scan with a tests order of 0123467 on
 myboard.txt.
 
 -step [Step] , --soft-thread-step [Step]

fc-solve/source/instance.c

     fc_solve_soft_thread_t * soft_thread
     )
 {
-    /* Normalize the A* Weights, so the sum of all of them would be 1. */
+    /* Normalize the Best-First-Search Weights, so the sum of all of them would be 1. */
     double sum;
     int a;
     sum = 0;

fc-solve/source/instance.h

     /*
      * The debug_iter_output variables provide a programmer programmable way
      * to debug the algorithm while it is running. This works well for DFS
-     * and Soft-DFS scans but at present support for A* and BFS is not
+     * and Soft-DFS scans but at present support for BeFS and BFS is not
      * too good, as its hard to tell which state came from which parent state.
      *
      * debug_iter_output_func is a pointer to the function that performs the
 
 
     /*
-     * The method (i.e: DFS, Soft-DFS, BFS or A*) that is used by this
+     * The method (i.e: DFS, Soft-DFS, BFS or BeFS) that is used by this
      * instance.
      *
      * */
                 struct
                 {
                     /*
-                     * The priority queue of the A* scan */
+                     * The priority queue of the BeFS scan 
+                     * */
                     PQUEUE pqueue;
                     double initial_cards_under_sequences_value;
 
                     /*
-                     * The A* weights of the different A* tests. Those weights
-                     * determine the commulative weight of the state.
-                     *
+                     * The BeFS weights of the different BeFS tests. Those
+                     * weights determine the commulative priority of the state.
                      * */
                     double befs_weights[5];
                 } befs;
     )
 
 /*
- * An enum that specifies the meaning of each A* weight.
+ * An enum that specifies the meaning of each BeFS weight.
  * */
 #define FCS_BEFS_WEIGHT_CARDS_OUT 0
 #define FCS_BEFS_WEIGHT_MAX_SEQUENCE_MOVE 1

fc-solve/source/main.c

 "\n"
 "-me [solving_method]   --method [solving_method]\n"
 "     Specify a solving method. Available methods are:\n"
-"        \"a-star\" - A*\n"
+"        \"a-star\" - Best-First-Search\n"
 "        \"bfs\" - Breadth-First Search\n"
 "        \"dfs\" - Depth-First Search (default)\n"
 "        \"random-dfs\" - A randomized DFS\n"
 "        \"soft-dfs\" - \"Soft\" DFS\n"
 "\n"
-"-asw [A* Weights]   --a-star-weight [A* Weights]\n"
-"     Specify weights for the A* scan, assuming it is used. The parameter\n"
-"     should be a comma-separated list of numbers, each one is proportional\n"
-"     to the weight of its corresponding test.\n"
+"-asw [BeFS Weights]   --a-star-weight [BeFS Weights]\n"
+"     Specify weights for the Best-first-search scan, assuming it is used.\n"
+"     The parameter should be a comma-separated list of numbers, each one is\n"
+"     proportional to the weight of its corresponding test.\n"
 "\n"
 "     The numbers are, in order:\n"
 "     1. The number of cards out.\n"

fc-solve/source/scans.c

  */
 /*
  * scans.c - The code that relates to the various scans.
- * Currently Hard DFS, Soft-DFS, Random-DFS, A* and BFS are implemented.
+ * Currently Hard DFS, Soft-DFS, Random-DFS, BeFS and BFS are implemented.
  *
  */
 
 
 /*
     fc_solve_befs_or_bfs_do_solve() is the main event
-    loop of the A* And BFS scans. It is quite simple as all it does is
+    loop of the BeFS And BFS scans. It is quite simple as all it does is
     extract elements out of the queue or priority queue and run all the test
     of them.
 
     fc_solve_soft_thread_t * soft_thread
     )
 {
-    /* Normalize the A* Weights, so the sum of all of them would be 1. */
+    /* Normalize the BeFS Weights, so the sum of all of them would be 1. */
     double sum;
     int a;
     sum = 0;
 
     if (soft_thread->method == FCS_METHOD_A_STAR)
     {
-        /* Initialize the priotity queue of the A* scan */
+        /* Initialize the priotity queue of the BeFS scan */
         fc_solve_PQueueInitialise(
             &(soft_thread->method_specific.befs.meth.befs.pqueue),
             1024
         }
 
         TRACE0("perform_tests");
-        /* Do all the tests at one go, because that is the way it should be
-           done for BFS and A*
+        /* 
+         * Do all the tests at one go, because that is the way it should be
+         * done for BFS and BeFS.
         */
         derived.num_states = 0;
         for(next_test = tests_list;
         {
 
 #ifdef DEBUG
-        dump_pqueue(soft_thread, "before_pop", scan_specific.pqueue);
+            dump_pqueue(soft_thread, "before_pop", scan_specific.pqueue);
 #endif
-            /* It is an A* scan */
+            /* It is an BeFS scan */
             fc_solve_PQueuePop(
                 scan_specific.pqueue,
                 &ptr_state_val
             ptr_state_val->key, 
             ptr_state_val
     );
-    /* Some A* and BFS parameters that need to be initialized in
+    /* Some BeFS and BFS parameters that need to be initialized in
      * the derived state.
      * */
     ptr_new_state_val->parent_val = ptr_state_val;