(* Content-type: application/vnd.wolfram.mathematica *)

(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)

(* CreatedBy='Wolfram 15.0' *)

(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[       154,          7]
NotebookDataLength[     51263,       1332]
NotebookOptionsPosition[     42009,       1162]
NotebookOutlinePosition[     44646,       1220]
CellTagsIndexPosition[     44568,       1215]
WindowTitle->OracleBenchmark
WindowFrame->Normal*)

(* Beginning of Notebook Content *)
Notebook[{
Cell[BoxData[GridBox[{
   {GridBox[{
      {
       ItemBox[Cell[BoxData[
         RowBox[{
          TemplateBox[{12},
           "Spacer1"], Cell[
          "WOLFRAM INSTITUTE/ PUZZLES SYMBOL", "PacletNameCell",
           TextAlignment->Center,ExpressionUUID->
           "85dbba06-5add-473f-adf2-1ac8085c95ff"], 
          TemplateBox[{8},
           "Spacer1"]}]],
         TextAlignment->Center,ExpressionUUID->
         "1c8d58e9-bc62-42bf-9d94-3df2f02c4637"],
        Background->LightDarkSwitched[
          RGBColor[0.490196, 0.576471, 0.690196]],
        ItemSize->Full], ""}
     },
     GridBoxAlignment->{"Rows" -> {{Center}}},
     GridBoxItemSize->{"Columns" -> {Full, 
         Scaled[0.02]}, "Rows" -> {{2.5}}}], Cell[TextData[{
     Cell[BoxData[
      TagBox[
       ActionMenuBox[
        FrameBox[Cell[TextData[{
          "See Also",
          " ",
          Cell[BoxData[
           GraphicsBox[
            {GrayLevel[0.66667], Thickness[0.13], 
             LineBox[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]},
            AspectRatio->1,
            ImageSize->20,
            PlotRange->{{-3, 4}, {-1, 1}}]],ExpressionUUID->
           "2116fde6-1af8-463f-b555-af7bfda36f92"]
         }],ExpressionUUID->"5176f40f-034a-4778-bb68-9e66d10edbbb"],
         StripOnInput->False],{
        StyleBox[
          "\"AbsoluteTiming\"", "SeeAlsoRelated", StripOnInput -> False] :> 
         Documentation`HelpLookup["paclet:ref/AbsoluteTiming"], Delimiter, 
         StyleBox[
          "\"Functions\"", "SeeAlsoSection", FontSize -> 14, FontSlant -> 
           "Italic", StripOnInput -> False] :> 
         NotebookFind[EvaluationNotebook[], "SeeAlsoSection", All, CellStyle],
          StyleBox[
          StyleBox["\"OracleScan\"", "SeeAlsoRelated", StripOnInput -> False],
            "SeeAlsoRelated", StripOnInput -> False] :> 
         Documentation`HelpLookup[
          "paclet:WolframInstitute/Puzzles/ref/OracleScan"], 
         StyleBox[
          StyleBox[
           "\"PuzzleOracle\"", "SeeAlsoRelated", StripOnInput -> False], 
           "SeeAlsoRelated", StripOnInput -> False] :> 
         Documentation`HelpLookup[
          "paclet:WolframInstitute/Puzzles/ref/PuzzleOracle"], 
         StyleBox[
          StyleBox[
           "\"$OracleCompiledDigests\"", "SeeAlsoRelated", StripOnInput -> 
            False], "SeeAlsoRelated", StripOnInput -> False] :> 
         Documentation`HelpLookup[
          "paclet:WolframInstitute/Puzzles/ref/$OracleCompiledDigests"], 
         StyleBox[
          StyleBox["\"HashChain\"", "SeeAlsoRelated", StripOnInput -> False], 
           "SeeAlsoRelated", StripOnInput -> False] :> 
         Documentation`HelpLookup[
          "paclet:WolframInstitute/Puzzles/ref/HashChain"]},
        Appearance->None,
        MenuAppearance->Automatic,
        MenuStyle->"SeeAlso"],
       MouseAppearanceTag["LinkHand"]]],
      LineSpacing->{1.4, 0},ExpressionUUID->
      "91ebf175-f9b6-48d0-ac9d-d3b44d9bcda1"],
     "\[ThickSpace]\[ThickSpace]\[ThickSpace]\[ThickSpace]\[ThickSpace]\
\[ThickSpace]",
     Cell[BoxData[
      TagBox[
       ActionMenuBox[
        FrameBox[Cell[TextData[{
          "Related Guides",
          " ",
          Cell[BoxData[
           GraphicsBox[
            {GrayLevel[0.66667], Thickness[0.13], 
             LineBox[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]},
            AspectRatio->1,
            ImageSize->20,
            PlotRange->{{-3, 4}, {-1, 1}}]],ExpressionUUID->
           "4bdd357c-2032-4672-85c9-75ab742be983"]
         }],ExpressionUUID->"bc17d2ea-c90c-4a56-96f6-675a8c41bebe"],
         StripOnInput->False],{
        "\"Oracles\"" :> 
         Documentation`HelpLookup[
          "paclet:WolframInstitute/Puzzles/guide/Oracles"]},
        Appearance->None,
        MenuAppearance->Automatic,
        MenuStyle->"MoreAbout"],
       MouseAppearanceTag["LinkHand"]]],
      LineSpacing->{1.4, 0},ExpressionUUID->
      "df20fd64-a863-49d1-99b0-fc52354a3d53"],
     "\[ThickSpace]\[ThickSpace]\[ThickSpace]\[ThickSpace]\[ThickSpace]\
\[ThickSpace]",
     Cell[BoxData[
      TagBox[
       ActionMenuBox[
        FrameBox[Cell[TextData[{
          "URL",
          " ",
          Cell[BoxData[
           GraphicsBox[
            {GrayLevel[0.66667], Thickness[0.13], 
             LineBox[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]},
            AspectRatio->1,
            ImageSize->20,
            PlotRange->{{-3, 4}, {-1, 1}}]],ExpressionUUID->
           "575085d8-ec1a-46eb-a0b3-de90ee89cd65"]
         }],ExpressionUUID->"89a524c6-e4c8-49e9-b1c1-309b3f97d4e1"],
         StripOnInput->False],{
        "\"WolframInstitute/Puzzles/ref/OracleBenchmark\"" :> None, 
         "\"Copy Wolfram Documentation Center URL\"" :> 
         CopyToClipboard["WolframInstitute/Puzzles/ref/OracleBenchmark"], 
         Delimiter, "\"Copy web URL\"" :> 
         Module[{DocumentationSearch`Private`nb$}, 
           DocumentationSearch`Private`nb$ = 
            NotebookPut[
             Notebook[{
               Cell[BoxData[
                 MakeBoxes[
                  Hyperlink[
                   "http://reference.wolfram.com/language/WolframInstitute/\
Puzzles/ref/OracleBenchmark.html"], StandardForm]], "Input", 
                 TextClipboardType -> "PlainText"]}, Visible -> False]]; 
           SelectionMove[DocumentationSearch`Private`nb$, All, Notebook]; 
           FrontEndTokenExecute[DocumentationSearch`Private`nb$, "Copy"]; 
           NotebookClose[DocumentationSearch`Private`nb$]; Null], 
         "\"Go to web URL\"" :> 
         FrontEndExecute[{
           NotebookLocate[{
             URL[If[TrueQ[False], 
                 "http://reference.wolfram.com/system-modeler/", 
                 "http://reference.wolfram.com/language/"] <> 
               "WolframInstitute/Puzzles/ref/OracleBenchmark" <> ".html"], 
              None}]}]},
        Appearance->None,
        MenuAppearance->Automatic,
        MenuStyle->"URLMenu"],
       MouseAppearanceTag["LinkHand"]]],
      LineSpacing->{1.4, 0},ExpressionUUID->
      "1c68a4d1-c5ae-4267-94b6-0bf049d6f386"]
    }], "AnchorBar",
     CacheGraphics->False,ExpressionUUID->
     "18c3139a-7b0c-4e6d-a6bc-22308b586e50"]}
  }]], "AnchorBarGrid",
 CellID->1,ExpressionUUID->"c25bd172-ef03-4e83-8c6a-c93e6ff3e056"],

Cell["WolframInstitute`Puzzles`", "ContextNameCell",ExpressionUUID->"a40659b7-f451-4d55-be3d-461b268b94fc"],

Cell[CellGroupData[{

Cell[BoxData[GridBox[{
   {Cell[TextData[{
     Cell[
     "OracleBenchmark", "ObjectName",ExpressionUUID->
      "dc66f065-dd58-4d26-afdf-36f0ac1b52a4"],
     Cell[BoxData[
      TemplateBox[{8},
       "Spacer1"]],ExpressionUUID->"6bec3753-c760-47f9-9b1d-13ef309ef67a"],
     Cell[BoxData[
     ""], "ObjectNameTranslation",ExpressionUUID->
      "f0664f1f-32d3-4e27-be69-88aca4a27968"]
    }],ExpressionUUID->"3cd9ed7a-da79-4d0f-ba8a-e93144f71b36"], 
    "\[SpanFromLeft]"}
  }]], "ObjectNameGrid",ExpressionUUID->"3e767076-4c5b-492e-9dc2-\
d14cfff283d8"],

Cell[BoxData[GridBox[{
   {"", Cell[TextData[{
     Cell[BoxData[
      RowBox[{
       TemplateBox[{
         Cell[
          TextData["OracleBenchmark"]], 
         "paclet:WolframInstitute/Puzzles/ref/OracleBenchmark", 
         "WolframInstitute/Puzzles Package Symbol"},
        "PackageLink",
        BaseStyle->"InlineFormula"], "[", 
       StyleBox["oracle", "TI"], "]"}]], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "a4cd6860-c776-4188-9084-96d1891fed58"],
     "\[LineSeparator]",
     "measures the throughput of the ",
     Cell[BoxData[
      TemplateBox[{
        Cell[
         TextData["PuzzleOracle"]], 
        "paclet:WolframInstitute/Puzzles/ref/PuzzleOracle", 
        "WolframInstitute/Puzzles Package Symbol"},
       "PackageLink",
       BaseStyle->"InlineFormula"]], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "e4e11edd-721a-43e1-be86-a6bd8c9aadbd"],
     " ",
     StyleBox["oracle", "TI"],
     " on synthetic candidates and gives an ",
     Cell[BoxData["Association"], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "b9fd48d4-15a3-45f0-b87b-5562db2f4c7b"],
     " including ",
     Cell[BoxData["\"\<CandidatesPerSecond\>\""], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "bf4a84f2-f820-440c-9262-c558edac9238"],
     "."
    }],ExpressionUUID->"4ff45d2c-a53a-4a90-a2df-d958b6696b9e"]},
   {"", Cell[TextData[{
     Cell[BoxData[
      RowBox[{
       TemplateBox[{
         Cell[
          TextData["OracleBenchmark"]], 
         "paclet:WolframInstitute/Puzzles/ref/OracleBenchmark", 
         "WolframInstitute/Puzzles Package Symbol"},
        "PackageLink",
        BaseStyle->"InlineFormula"], "[", 
       RowBox[{
        StyleBox["oracle", "TI"], ",", " ", 
        StyleBox["n", "TI"]}], "]"}]], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "919fb56b-3c88-435e-b535-b46f9317cfd3"],
     "\[LineSeparator]",
     "measures it over ",
     Cell[BoxData[
      StyleBox["n", "TI"]], "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "28098044-6c6c-4417-8bf9-7005023cf8c5"],
     " synthetic candidates instead of the default 20000."
    }],ExpressionUUID->"d7b3038d-1aa8-4ac4-ad60-2ba5a120cbb2"]},
   {"", Cell[TextData[{
     Cell[BoxData[
      RowBox[{
       TemplateBox[{
         Cell[
          TextData["OracleBenchmark"]], 
         "paclet:WolframInstitute/Puzzles/ref/OracleBenchmark", 
         "WolframInstitute/Puzzles Package Symbol"},
        "PackageLink",
        BaseStyle->"InlineFormula"], "[", 
       RowBox[{
        StyleBox["oracle", "TI"], ",", " ", 
        RowBox[{"{", 
         RowBox[{
          SubscriptBox[
           StyleBox["cand", "TI"], 
           StyleBox["1", "TR"]], ",", " ", 
          SubscriptBox[
           StyleBox["cand", "TI"], 
           StyleBox["2", "TR"]], ",", " ", "\[Ellipsis]"}], "}"}]}], "]"}]], 
      "InlineFormula",
      FontFamily->"Source Sans Pro",
      FontSize->0.9 Inherited,ExpressionUUID->
      "65dc2b72-133d-418f-aca9-b49000bef017"],
     "\[LineSeparator]",
     "measures it over a candidate batch of your own."
    }],ExpressionUUID->"b951716d-95f5-4e52-b76b-5e08448d3d2d"]}
  }]], "Usage",ExpressionUUID->"f3e18a67-6667-4187-bbee-7768dcc20cff"]
}, Open  ]],

Cell[CellGroupData[{

Cell[TextData[Cell[BoxData[Cell[TextData[{
  Cell[BoxData[
   DynamicBox[ToBoxes[
     If[CurrentValue[
        EvaluationCell[], "CellGroupOpen"] =!= Closed, 
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], 
      Rotate[
       Style[
        Graphics[{
          Thickness[0.18], 
          RGBColor[0.8509803921568627, 0.396078431372549, 0], 
          Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
         PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
        0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]],
    ImageSizeCache->{
     13.600000000000001`, {-0.1685058593749993, 13.768505859375}}]],
   ExpressionUUID->"3c588028-6417-4111-9489-03dfd98e1c41"],
  Cell[BoxData[
   TemplateBox[{1},
    "Spacer1"]],ExpressionUUID->"6662b42d-2389-4244-92c3-9cbee5176273"],
  "Details and Options"
 }], "NotesFrameText",ExpressionUUID->
  "2081cdaa-a799-459e-9010-264d0eb8cea9"]],ExpressionUUID->"bf4b8ce7-92ef-\
4336-80a8-1dc97cc6e792"]], "NotesSection",
 ShowGroupOpener->"Thumbnail",
 WholeCellGroupOpener->True,
 CellGroupingRules->{"SectionGrouping", 50},
 CacheGraphics->False,
 CellID->773875941,ExpressionUUID->"7c7d9647-91a8-4826-8a17-da246ce7352b"],

Cell[TextData[{
 "The result records the ",
 Cell[BoxData["\<\"Type\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "825def07-f672-4665-8bed-d2cd1fba2de1"],
 ", ",
 Cell[BoxData["\<\"Method\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "a194a3e2-40f0-4c4b-b7a9-900bb16c5fb1"],
 " and ",
 Cell[BoxData["\<\"Iterations\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "fa3c4a4b-6f7c-4db5-94de-6534e11512e0"],
 " of the oracle, the ",
 Cell[BoxData["\<\"Implementation\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "5cadfc37-4dea-4e33-a980-e0f8b10e1501"],
 " its digest goes through, the ",
 Cell[BoxData["\<\"SampleSize\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "7256ac2d-d71b-4172-92b9-129e69d6330b"],
 ", the ",
 Cell[BoxData["\<\"TimeSeconds\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "93a3f8a1-1962-4315-b65c-e19ab205ab27"],
 " the scan took, the ",
 Cell[BoxData["\<\"CandidatesPerSecond\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "865bd158-343e-43a7-adc5-6f37c404d3c3"],
 " that implies, and the number of ",
 Cell[BoxData["\<\"Matches\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "63031376-c5f9-491c-83aa-f3f59e3c5330"],
 " found."
}], "Notes",ExpressionUUID->"b7beaa1b-292c-443e-83a9-194e974fb5d5"],

Cell[TextData[{
 Cell[BoxData["\<\"Implementation\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "7fc913f6-ecc2-48c3-a216-b398f58c2e22"],
 " is ",
 Cell[BoxData["\<\"Compiled\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "a56fcd9a-f595-4042-a3a3-6cc38d2c59d5"],
 " for a digest with a compiled kernel, ",
 Cell[BoxData["\<\"Kernel\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "51f50ae5-f547-4e7a-9f53-8c407e7a9835"],
 " for one computed by the kernel's ",
 Cell[BoxData[
  TemplateBox[{
    Cell[
     TextData["Hash"]], "paclet:ref/Hash"},
   "RefLink",
   BaseStyle->"InlineFormula"]], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "b1c9f43e-0be6-4022-8fc0-621b2a25e599"],
 ", and ",
 Cell[BoxData["\<\"HashTable\"\>"], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "8b840058-a24b-4c7e-aa2f-ca7219534f96"],
 " for a membership oracle."
}], "Notes",ExpressionUUID->"c674927b-6625-421d-9c00-680c05d4e370"],

Cell["\<\
The synthetic candidates are 64-character hexadecimal strings drawn from a \
fixed seed, so a benchmark is repeatable and does not disturb the ambient \
random state.\
\>", "Notes",ExpressionUUID->"7f2e59a3-0bbf-4b0d-9185-5663e04734bb"],

Cell["\<\
They are chosen not to hit the target, so what is timed is the miss path, \
which is where a sweep spends all of its time.\
\>", "Notes",ExpressionUUID->"aedd1307-62b6-47c9-a95a-69920f3d4a5d"],

Cell["\<\
The oracle is run once on a short prefix before the measurement, so the \
one-off cost of building and validating a compiled digest kernel is not \
counted.\
\>", "Notes",ExpressionUUID->"f38b122c-a11c-40e2-8cfd-5cdc0d1441a2"],

Cell["\<\
Throughput depends on the machine, the digest, the candidate length and \
whether a compiled kernel is in force, so a sweep should be planned against a \
measurement, not against a published figure.\
\>", "Notes",ExpressionUUID->"4d459ba3-2dc0-41e5-a3cb-385ebfcc7b7c"],

Cell["\<\
A non-positive sample size, or a batch containing a candidate the oracle \
cannot read, is out of scope and returned unevaluated.\
\>", "Notes",ExpressionUUID->"060b76fb-b233-4fd4-9855-dde9ab4e6f5d"]
}, Closed]],

Cell["", "PageDelimiter",ExpressionUUID->"d9769cf5-14a6-4e9d-9486-6e9e2415b12a"],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[
     MatchQ[
      CurrentValue[
       EvaluationNotebook[], {
       TaggingRules, "Openers", "PrimaryExamplesSection"}, Open], 
      Alternatives[True, Open]], 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]],
   ImageSizeCache->{
    13.600000000000001`, {4.251494140625001, 9.348505859375}}]],
  ExpressionUUID->"f31f91ee-0a26-4397-92a8-c9669b90b134"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"01ab0832-db31-4508-bd61-527f9ae17e36"],
 "Examples",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(10)", "ExampleCount",ExpressionUUID->
  "a917d215-e4c1-44cf-9390-73433f3c78ff"]
}], "PrimaryExamplesSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->1371974155,ExpressionUUID->"2b7c6f99-f054-482f-a893-dba7abb0d009"],

Cell[BoxData[
 RowBox[{"Needs", "[", "\"\<WolframInstitute`Puzzles`\>\"", "]"}]], "Input", \
"ExampleInitialization",
 CellLabel->"In[1]:=",
 CellID->1969679695,ExpressionUUID->"7dfedd32-fe95-4460-8ad8-eeb7c59e77e5"],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[CurrentValue[
       EvaluationCell[], "CellGroupOpen"] =!= Closed, 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]]]],ExpressionUUID->
  "8e42a89f-d52a-41bd-9cd2-e331f082e15f"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"252ab7cb-334e-438e-9039-2930aad55be6"],
 "Basic Examples",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(2)", "ExampleCount",ExpressionUUID->
  "8a217aae-ffec-46ed-a73b-8152e011a5ba"]
}], "ExampleSection", "ExampleSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->1237705246,ExpressionUUID->"5066218a-97e9-4e9d-9a3a-d64438f31229"],

Cell["The throughput of a SHA-256 preimage oracle on this machine:", \
"ExampleText",
 CellTags->
  "TextAnnotation",ExpressionUUID->"b81e7488-558c-44e6-9b4c-25e731835374"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"OracleBenchmark", "[", 
  RowBox[{
   RowBox[{"PuzzleOracle", "[", 
    RowBox[{"\"\<\
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad\>\"", ",", 
     " ", 
     RowBox[{"Method", " ", "->", " ", "\"\<SHA256\>\""}]}], "]"}], ",", " ", 
   "20000"}], "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"66f90eab-4ceb-4f52-a933-78ac3ecbc042"],

Cell[BoxData[
 RowBox[{"\[LeftAssociation]", 
  RowBox[{
   RowBox[{"\<\"Type\"\>", "\[Rule]", "\<\"Digest\"\>"}], ",", 
   RowBox[{"\<\"Method\"\>", "\[Rule]", "\<\"SHA256\"\>"}], ",", 
   RowBox[{"\<\"Iterations\"\>", "\[Rule]", "1"}], ",", 
   RowBox[{"\<\"Implementation\"\>", "\[Rule]", "\<\"Compiled\"\>"}], ",", 
   RowBox[{"\<\"SampleSize\"\>", "\[Rule]", "20000"}], ",", 
   RowBox[{"\<\"TimeSeconds\"\>", "\[Rule]", "0.111259`"}], ",", 
   RowBox[{"\<\"CandidatesPerSecond\"\>", "\[Rule]", "179761"}], ",", 
   RowBox[{"\<\"Matches\"\>", "\[Rule]", "0"}]}], 
  "\[RightAssociation]"}]], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"2e47206c-8507-4cc6-abb1-6e88329e56c4"]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 InterpretationBox[Cell[
  "\t", "ExampleDelimiter",ExpressionUUID->
   "a8e2633f-6b90-4337-8012-47c7be6844d4"],
  $Line = 0; Null]], "ExampleDelimiter",ExpressionUUID->"d64f15fb-777a-4f9f-\
9e7b-b036ddeaff2e"],

Cell["\<\
A membership oracle is faster still, since it does no hashing at all:\
\>", "ExampleText",ExpressionUUID->"db140be5-3271-4ae7-bf56-9d6c498c1a4a"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{
  RowBox[{"OracleBenchmark", "[", 
   RowBox[{
    RowBox[{
    "PuzzleOracle", "[", "\"\<1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa\>\"", "]"}], 
    ",", " ", "20000"}], "]"}], "[", "\"\<CandidatesPerSecond\>\"", 
  "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"b6b7597a-5855-4c13-b865-cd7102ea56d6"],

Cell[BoxData["1181195"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"e0b8a99f-ce02-4576-a21f-4596f86c04e1"]
}, Open  ]]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[CurrentValue[
       EvaluationCell[], "CellGroupOpen"] =!= Closed, 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]]]],ExpressionUUID->
  "14643d51-3b34-450e-acdb-5050d3be36a6"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"f25159ac-1bf6-4603-af39-d4cd5d31feca"],
 "Scope",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(4)", "ExampleCount",ExpressionUUID->
  "989ff5f0-3bd6-4499-9ef4-fb5b620b845f"]
}], "ExampleSection", "ExampleSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->1293636265,ExpressionUUID->"456c4570-f9a0-4484-bbef-342d2cbf08ae"],

Cell[TextData[{
 "A digest with no compiled kernel goes through the kernel's ",
 Cell[BoxData[
  TemplateBox[{
    Cell[
     TextData["Hash"]], "paclet:ref/Hash"},
   "RefLink",
   BaseStyle->"InlineFormula"]], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "631a8cdc-fe0b-4817-bd21-e0c6d0ef44e1"],
 ", and the report says so:"
}], "ExampleText",ExpressionUUID->"0ec5a272-23e2-4e20-80bf-c54693fc3027"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"KeyTake", "[", 
  RowBox[{
   RowBox[{"OracleBenchmark", "[", 
    RowBox[{
     RowBox[{"PuzzleOracle", "[", 
      RowBox[{"\"\<900150983cd24fb0d6963f7d28e17f72\>\"", ",", " ", 
       RowBox[{"Method", " ", "->", " ", "\"\<MD5\>\""}]}], "]"}], ",", " ", 
     "5000"}], "]"}], ",", " ", 
   RowBox[{"{", 
    RowBox[{"\"\<Implementation\>\"", ",", 
     " ", "\"\<CandidatesPerSecond\>\""}], "}"}]}], "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"ce479458-a610-491d-bff4-51c2405d7960"],

Cell[BoxData[
 RowBox[{"\[LeftAssociation]", 
  RowBox[{
   RowBox[{"\<\"Implementation\"\>", "\[Rule]", "\<\"Kernel\"\>"}], ",", 
   RowBox[{"\<\"CandidatesPerSecond\"\>", "\[Rule]", "9617"}]}], 
  "\[RightAssociation]"}]], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"def3a0bf-9895-4b32-bb17-bea15578837b"]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 InterpretationBox[Cell[
  "\t", "ExampleDelimiter",ExpressionUUID->
   "3c53dc54-a339-401c-ac29-c63f97024011"],
  $Line = 0; Null]], "ExampleDelimiter",ExpressionUUID->"479f5bb0-b1b9-466a-\
9fdc-7d1dd4681258"],

Cell["\<\
A batch of your own measures the candidates a sweep will really run, here \
33-byte compressed public keys against a HASH160 target:\
\>", "ExampleText",ExpressionUUID->"fdbbfe1b-7211-4480-a8e6-5e85ecfe0685"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{
  RowBox[{"OracleBenchmark", "[", "\n", "\t", 
   RowBox[{
    RowBox[{"PuzzleOracle", "[", 
     RowBox[{"\"\<010966776006953d5567439e5e39f86a0d273bee\>\"", ",", " ", 
      RowBox[{"Method", " ", "->", " ", "\"\<RIPEMD160SHA256\>\""}]}], "]"}], 
    ",", "\n", "\t", 
    RowBox[{"Table", "[", 
     RowBox[{
      RowBox[{"ByteArray", "[", 
       RowBox[{"IntegerDigits", "[", 
        RowBox[{"k", ",", " ", "256", ",", " ", "33"}], "]"}], "]"}], ",", 
      " ", 
      RowBox[{"{", 
       RowBox[{"k", ",", " ", "1", ",", " ", "50000"}], "}"}]}], "]"}]}], 
   "\n", "]"}], "[", "\"\<CandidatesPerSecond\>\"", "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"5064fd01-32d2-4a08-95a9-d31631447ab0"],

Cell[BoxData["212188"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"31e70e10-2f2c-4aad-af63-0d89accc317d"]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 InterpretationBox[Cell[
  "\t", "ExampleDelimiter",ExpressionUUID->
   "e444668a-9813-410b-b055-257306ab84ff"],
  $Line = 0; Null]], "ExampleDelimiter",ExpressionUUID->"383f7541-bd3a-47ef-\
b3ac-a9e88e7d980e"],

Cell["A supplied batch that does hit the target reports the hits:", \
"ExampleText",ExpressionUUID->"df50734c-6090-4d9d-a88c-298c364bab02"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{
  RowBox[{"OracleBenchmark", "[", 
   RowBox[{
    RowBox[{"PuzzleOracle", "[", 
     RowBox[{"\"\<\
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad\>\"", ",", 
      " ", 
      RowBox[{"Method", " ", "->", " ", "\"\<SHA256\>\""}]}], "]"}], ",", " ", 
    RowBox[{"{", 
     RowBox[{"\"\<abc\>\"", ",", " ", "\"\<abd\>\"", ",", 
      " ", "\"\<abe\>\""}], "}"}]}], "]"}], "[", "\"\<Matches\>\"", 
  "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"1a3c888b-4dfb-45a9-9da6-a291a9a86b38"],

Cell[BoxData["1"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"55019e00-1ee4-4e08-bc7f-b47b0f35ff15"]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 InterpretationBox[Cell[
  "\t", "ExampleDelimiter",ExpressionUUID->
   "01ee2c26-9a8a-4461-a652-e27ea50e7fca"],
  $Line = 0; Null]], "ExampleDelimiter",ExpressionUUID->"89aed5af-4af2-42c9-\
988a-670818c7654c"],

Cell["\<\
A non-positive sample size is out of scope and is returned unevaluated:\
\>", "ExampleText",ExpressionUUID->"b6c184df-022c-4122-ad6c-b5cc24f0c6f0"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"OracleBenchmark", "[", 
  RowBox[{
   RowBox[{"PuzzleOracle", "[", "\"\<abc\>\"", "]"}], ",", " ", "0"}], 
  "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"0751a147-7462-44e0-8ae7-007188c4f08f"],

Cell[BoxData[
 RowBox[{"OracleBenchmark", "[", 
  RowBox[{
   RowBox[{"PuzzleOracle", "[", 
    RowBox[{"\[LeftAssociation]", 
     RowBox[{
      RowBox[{"\<\"Type\"\>", "\[Rule]", "\<\"Membership\"\>"}], ",", 
      RowBox[{"\<\"Method\"\>", "\[Rule]", "None"}], ",", 
      RowBox[{"\<\"Iterations\"\>", "\[Rule]", "0"}], ",", 
      RowBox[{"\<\"CandidateEncoding\"\>", "\[Rule]", "\<\"String\"\>"}], ",", 
      RowBox[{"\<\"TargetCount\"\>", "\[Rule]", "1"}], ",", 
      RowBox[{"\<\"Targets\"\>", "\[Rule]", 
       RowBox[{"\[LeftAssociation]", 
        RowBox[{"\<\"abc\"\>", "\[Rule]", "True"}], 
        "\[RightAssociation]"}]}]}], "\[RightAssociation]"}], "]"}], ",", 
   "0"}], "]"}]], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"5beda0b4-ed09-4299-84ee-b29bb3e05798"]
}, Open  ]]
}, Open  ]]
}, Closed]],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[CurrentValue[
       EvaluationCell[], "CellGroupOpen"] =!= Closed, 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]]]],ExpressionUUID->
  "e169ed4f-26d6-4bcd-8554-e19f488e17b9"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"0a7dcc7f-63c2-4c59-a8d8-a08416729c7f"],
 "Applications",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(1)", "ExampleCount",ExpressionUUID->
  "2c36c6bb-0c50-4e41-90ab-7f4d871004e8"]
}], "ExampleSection", "ExampleSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->258228157,ExpressionUUID->"b6051eeb-cf81-45e7-ab2f-b3259c12f431"],

Cell["\<\
How long a sweep of a billion candidates would take at the measured rate:\
\>", "ExampleText",ExpressionUUID->"459c5fe1-9dd5-4c1a-aa9d-fe999cdb1fed"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"Quantity", "[", "\n", "\t", 
  RowBox[{
   RowBox[{"Round", "[", 
    RowBox[{
     RowBox[{"10", "^", "9"}], " ", "/", " ", 
     RowBox[{
      RowBox[{"OracleBenchmark", "[", 
       RowBox[{
        RowBox[{"PuzzleOracle", "[", 
         RowBox[{"\"\<\
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad\>\"", ",", 
          " ", 
          RowBox[{"Method", " ", "->", " ", "\"\<SHA256\>\""}]}], "]"}], ",", 
        " ", "20000"}], "]"}], "[", "\"\<CandidatesPerSecond\>\"", "]"}]}], 
    "]"}], ",", "\n", "\t", "\"\<Seconds\>\""}], "\n", "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"83971be7-0c29-4ce4-b4d0-3842ee1f817b"],

Cell[BoxData[
 TemplateBox[{"4316", "\"s\"", "seconds", "\"Seconds\""},
  "Quantity"]], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"7673ac91-5495-473b-b79d-265897ad90d3"]
}, Open  ]]
}, Closed]],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[CurrentValue[
       EvaluationCell[], "CellGroupOpen"] =!= Closed, 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]]]],ExpressionUUID->
  "849f8a9a-1832-4d47-8160-0d1bfb00d50e"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"090b2c14-d828-4a36-96a9-19c0c5d282f5"],
 "Properties & Relations",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(2)", "ExampleCount",ExpressionUUID->
  "efad53e6-618e-47c8-a61d-67820358c483"]
}], "ExampleSection", "ExampleSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->2123667759,ExpressionUUID->"eeee8d98-152e-40dd-bc32-c4a989e5f356"],

Cell[TextData[{
 "The rate is the sample size divided by the measured time, which is the same \
quantity ",
 Cell[BoxData[
  TemplateBox[{
    Cell[
     TextData["AbsoluteTiming"]], "paclet:ref/AbsoluteTiming"},
   "RefLink",
   BaseStyle->"InlineFormula"]], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "47db047b-6e52-48f6-b3e9-717f5c72b80f"],
 " reports for the corresponding ",
 Cell[BoxData[
  TemplateBox[{
    Cell[
     TextData["OracleScan"]], 
    "paclet:WolframInstitute/Puzzles/ref/OracleScan", 
    "WolframInstitute/Puzzles Package Symbol"},
   "PackageLink",
   BaseStyle->"InlineFormula"]], "InlineFormula",
  FontFamily->"Source Sans Pro",
  FontSize->0.9 Inherited,ExpressionUUID->
  "8a2aedac-3d5d-4255-9df9-d750ef454f22"],
 ":"
}], "ExampleText",ExpressionUUID->"f22cb552-2161-4183-84b0-7a2334f9eb93"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"With", "[", 
  RowBox[{
   RowBox[{"{", 
    RowBox[{"report", " ", "=", " ", 
     RowBox[{"OracleBenchmark", "[", 
      RowBox[{
       RowBox[{"PuzzleOracle", "[", "\"\<abc\>\"", "]"}], ",", " ", "5000"}], 
      "]"}]}], "}"}], ",", "\n", "\t", 
   RowBox[{
    RowBox[{"Round", "[", 
     RowBox[{"report", "[", "\"\<CandidatesPerSecond\>\"", "]"}], "]"}], " ", 
    "===", " ", 
    RowBox[{"Round", "[", 
     RowBox[{
      RowBox[{"report", "[", "\"\<SampleSize\>\"", "]"}], " ", "/", " ", 
      RowBox[{"report", "[", "\"\<TimeSeconds\>\"", "]"}]}], "]"}]}]}], "\n", 
  "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"8298ecbd-8bda-4f30-a211-24d2104b7b96"],

Cell[BoxData["True"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"89b416b7-6e2f-4d6c-8411-c8ddf7f758db"]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 InterpretationBox[Cell[
  "\t", "ExampleDelimiter",ExpressionUUID->
   "eee98a0b-362f-43b1-ae2d-d6b81dbcc774"],
  $Line = 0; Null]], "ExampleDelimiter",ExpressionUUID->"1055a4ff-23b1-44ef-\
b123-70553df3ac73"],

Cell["\<\
The benchmark restores the random state it found, so it can be run inside a \
seeded computation:\
\>", "ExampleText",ExpressionUUID->"cabc3fd9-c27a-48eb-a4a8-b257cde5de6a"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{
  RowBox[{"BlockRandom", "[", 
   RowBox[{
    RowBox[{"SeedRandom", "[", "1", "]"}], ";", " ", 
    RowBox[{"OracleBenchmark", "[", 
     RowBox[{
      RowBox[{"PuzzleOracle", "[", "\"\<abc\>\"", "]"}], ",", " ", "100"}], 
     "]"}], ";", " ", 
    RowBox[{"RandomInteger", "[", 
     RowBox[{"{", 
      RowBox[{"0", ",", " ", 
       RowBox[{"10", "^", "9"}]}], "}"}], "]"}]}], "]"}], " ", "===", "\n", 
  "\t", 
  RowBox[{"BlockRandom", "[", 
   RowBox[{
    RowBox[{"SeedRandom", "[", "1", "]"}], ";", " ", 
    RowBox[{"RandomInteger", "[", 
     RowBox[{"{", 
      RowBox[{"0", ",", " ", 
       RowBox[{"10", "^", "9"}]}], "}"}], "]"}]}], "]"}]}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"f9726fe3-1a0e-4f2f-a0d3-08c47b7dc8c2"],

Cell[BoxData["True"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"a78d7b58-123e-4604-8500-13f37d9a33b7"]
}, Open  ]]
}, Open  ]]
}, Closed]],

Cell[CellGroupData[{

Cell[TextData[{
 Cell[BoxData[
  DynamicBox[ToBoxes[
    If[CurrentValue[
       EvaluationCell[], "CellGroupOpen"] =!= Closed, 
     Style[
      Graphics[{
        Thickness[0.18], 
        RGBColor[0.8509803921568627, 0.396078431372549, 0], 
        Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
       PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
      0.68 Inherited], 
     Rotate[
      Style[
       Graphics[{
         Thickness[0.18], 
         RGBColor[0.8509803921568627, 0.396078431372549, 0], 
         Line[{{-1.8, 0.5}, {0, 0}, {1.8, 0.5}}]}, AspectRatio -> 1, 
        PlotRange -> {{-3, 4}, {-1, 1}}, ImageSize -> 20], Magnification -> 
       0.68 Inherited], Rational[1, 2] Pi, {-1.65, -1}]]]]],ExpressionUUID->
  "aae872f6-875c-4773-aa7f-c1b9d2966c1f"],
 Cell[BoxData[
  TemplateBox[{1},
   "Spacer1"]],ExpressionUUID->"4652b9a6-de17-4beb-834b-45e1f225f33f"],
 "Possible Issues",
 "\[NonBreakingSpace]\[NonBreakingSpace]",
 Cell["(1)", "ExampleCount",ExpressionUUID->
  "09631402-ea96-4327-9e81-d2f02612c4d8"]
}], "ExampleSection", "ExampleSection",
 WholeCellGroupOpener->True,
 CacheGraphics->False,
 CellID->1305812373,ExpressionUUID->"1585b794-4eb0-4802-9744-b30de5d0f016"],

Cell["\<\
The measurement is of the miss path over one batch, so it is an upper bound \
on a real sweep: candidate generation, ledger writes and memory pressure are \
not counted. Time a real scan to include them:\
\>", "ExampleText",ExpressionUUID->"98a413fb-5f7d-479b-be5a-6610d90fd540"],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"With", "[", 
  RowBox[{
   RowBox[{"{", 
    RowBox[{"oracle", " ", "=", " ", 
     RowBox[{"PuzzleOracle", "[", 
      RowBox[{"\"\<\
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad\>\"", ",", 
       " ", 
       RowBox[{"Method", " ", "->", " ", "\"\<SHA256\>\""}]}], "]"}]}], "}"}],
    ",", "\n", "\t", 
   RowBox[{"First", "[", 
    RowBox[{"AbsoluteTiming", "[", 
     RowBox[{"OracleScan", "[", 
      RowBox[{"oracle", ",", " ", 
       RowBox[{"StringJoin", " ", "/@", " ", 
        RowBox[{"Tuples", "[", 
         RowBox[{
          RowBox[{"CharacterRange", "[", 
           RowBox[{"\"\<a\>\"", ",", " ", "\"\<t\>\""}], "]"}], ",", " ", 
          "3"}], "]"}]}]}], "]"}], "]"}], "]"}]}], "\n", "]"}]], "Input",
 CellProlog:>Needs["WolframInstitute`Puzzles`"],
 CellLabel->"In[1]:=",ExpressionUUID->"91d1b5dc-8c52-42f8-bec4-16d8dd0df95d"],

Cell[BoxData["0.027777`"], "Output",
 CellLabel->"Out[1]= ",ExpressionUUID->"4202a1e0-cd5d-4520-a2d8-e9201eadf5cf"]
}, Open  ]]
}, Closed]]
}, Open  ]],

Cell[BoxData[GridBox[{
   {
    DynamicBox[FEPrivate`ImportImage[
      FrontEnd`FileName[{"Documentation", "FooterIcons"}, 
       "RelatedFunction.png"]],
     ImageSizeCache->{50., {26.47265625, 33.52734375}}], GridBox[{
      {
       StyleBox[
        RowBox[{"See", " ", "Also"}], "SeeAlsoSection"]},
      {Cell[TextData[{
        Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["OracleScan"]], 
           "paclet:WolframInstitute/Puzzles/ref/OracleScan", 
           "WolframInstitute/Puzzles Package Symbol"},
          "PackageLink",
          BaseStyle->"InlineFormula"]], "InlineFormula",
         FontFamily->"Source Sans Pro",ExpressionUUID->
         "8ff8e043-8424-4bb0-93c4-8984646caf48"],
        "\[NonBreakingSpace]",
        StyleBox[
        "\[MediumSpace]\[FilledVerySmallSquare]\[MediumSpace]", 
         "InlineSeparator"],
        " ",
        Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["PuzzleOracle"]], 
           "paclet:WolframInstitute/Puzzles/ref/PuzzleOracle", 
           "WolframInstitute/Puzzles Package Symbol"},
          "PackageLink",
          BaseStyle->"InlineFormula"]], "InlineFormula",
         FontFamily->"Source Sans Pro",ExpressionUUID->
         "2f49b025-f8d9-408d-9cb9-243e4e182a1a"],
        "\[NonBreakingSpace]",
        StyleBox[
        "\[MediumSpace]\[FilledVerySmallSquare]\[MediumSpace]", 
         "InlineSeparator"],
        " ",
        Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["$OracleCompiledDigests"]], 
           "paclet:WolframInstitute/Puzzles/ref/$OracleCompiledDigests", 
           "WolframInstitute/Puzzles Package Symbol"},
          "PackageLink",
          BaseStyle->"InlineFormula"]], "InlineFormula",
         FontFamily->"Source Sans Pro",ExpressionUUID->
         "64ef1d54-a8ae-4b70-b11b-22fc5292e4b6"],
        "\[NonBreakingSpace]",
        StyleBox[
        "\[MediumSpace]\[FilledVerySmallSquare]\[MediumSpace]", 
         "InlineSeparator"],
        " ",
        Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["HashChain"]], 
           "paclet:WolframInstitute/Puzzles/ref/HashChain", 
           "WolframInstitute/Puzzles Package Symbol"},
          "PackageLink",
          BaseStyle->"InlineFormula"]], "InlineFormula",
         FontFamily->"Source Sans Pro",ExpressionUUID->
         "eeea253e-82f7-42aa-a9dd-abddbeb7ef3a"],
        "\[NonBreakingSpace]",
        StyleBox[
        "\[MediumSpace]\[FilledVerySmallSquare]\[MediumSpace]", 
         "InlineSeparator"],
        " ",
        Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["AbsoluteTiming"]], "paclet:ref/AbsoluteTiming"},
          "RefLink",
          BaseStyle->"InlineFormula"]], "InlineFormula",
         FontFamily->"Source Sans Pro",ExpressionUUID->
         "b9b30cbe-84df-4156-99c1-3c56031ee392"]
       }], "SeeAlso",ExpressionUUID->"ee388b6a-e6c0-4223-b9d0-aec7ecca3458"]}
     }]}
  }]], "SeeAlsoSection",ExpressionUUID->"0893d998-d687-4060-a2af-\
97b2d00e4df7"],

Cell[BoxData[GridBox[{
   {
    DynamicBox[FEPrivate`ImportImage[
      FrontEnd`FileName[{"Documentation", "FooterIcons"}, "RelatedGuide.png"]],
     ImageSizeCache->{50., {26.47265625, 33.52734375}}], GridBox[{
      {
       StyleBox[
        RowBox[{"Related", " ", "Guides"}], "MoreAboutSection"]},
      {
       RowBox[{"\[FilledVerySmallSquare]", Cell[BoxData[
         TemplateBox[{
           Cell[
            TextData["Oracles"]], 
           "paclet:WolframInstitute/Puzzles/guide/Oracles"},
          "RefLinkPlain",
          BaseStyle->{"MoreAbout"}]], "MoreAbout",ExpressionUUID->
         "54bd9cac-a6b3-477b-affb-afa8f4d72211"]}]}
     }]}
  }]], "MoreAboutSection",ExpressionUUID->"a8f64465-27c3-4c59-831f-\
93392d52392c"],

Cell[" ", "FooterCell",ExpressionUUID->"945db665-55a1-414e-9424-2ab214af2e5b"]
},
Saveable->False,
ScreenStyleEnvironment->"Working",
WindowSize->{900, 830},
WindowMargins->{{0, Automatic}, {Automatic, 0}},
WindowTitle->"OracleBenchmark",
TaggingRules->{
 "ModificationHighlight" -> False, "ColorType" -> "", "LinkTrails" -> "", 
  "ExampleCounter" -> 1, 
  "Openers" -> {
   "PrimaryExamplesSection" -> Open, "ExampleSection" -> {"0" -> Open}, 
    "AllOptsTable" -> Closed}, "NewStyles" -> True, 
  "CitationPopupData" -> $Failed, "ShowCitation" -> False, "HasOptions" -> 
  True, "RootCaptions" -> "", "HeaderCoreAreaLink" -> {}, 
  "Metadata" -> {
   "built" -> "{2026, 8, 27, 0, 11, 45.727865}", 
    "history" -> {"XX", "", "", ""}, "context" -> "WolframInstitute`Puzzles`",
     "keywords" -> {}, "specialkeywords" -> {}, 
    "tutorialcollectionlinks" -> {}, "index" -> True, "label" -> 
    "Wolfram Institute/ Puzzles Symbol", "language" -> "en", "paclet" -> 
    "WolframInstitute/Puzzles", "status" -> "None", "summary" -> 
    "PackageLink[OracleBenchmark, paclet : \
WolframInstitute/Puzzles/ref/OracleBenchmark, WolframInstitute/Puzzles \
Package Symbol][oracle] measures the throughput of the \
PackageLink[PuzzleOracle, paclet : WolframInstitute/Puzzles/ref/PuzzleOracle, \
WolframInstitute/Puzzles Package Symbol] oracle on synthetic candidates and \
gives an Association including CandidatesPerSecond. \
PackageLink[OracleBenchmark, paclet : \
WolframInstitute/Puzzles/ref/OracleBenchmark, WolframInstitute/Puzzles \
Package Symbol][oracle, n] measures it over n synthetic candidates instead of \
the default 20000. PackageLink[OracleBenchmark, paclet : \
WolframInstitute/Puzzles/ref/OracleBenchmark, WolframInstitute/Puzzles \
Package Symbol][oracle, {cand1, cand2, ...}] measures it over a candidate \
batch of your own.", "synonyms" -> {}, "tabletags" -> {}, "title" -> 
    "OracleBenchmark", "titlemodifier" -> "", "metadescription" -> "", 
    "windowtitle" -> "OracleBenchmark", "type" -> "Symbol", "uri" -> 
    "WolframInstitute/Puzzles/ref/OracleBenchmark", "WorkflowDockedCell" -> 
    ""}, "SearchTextTranslated" -> ""},
CellContext->CellGroup,
FrontEndVersion->"15.0 for Mac OS X ARM (64-bit) (May 19, 2026)",
StyleDefinitions->FrontEnd`FileName[{"Wolfram"}, "Reference.nb"],
ExpressionUUID->"25263a8c-7214-4af4-9791-6ea241f545dc"
]
(* End of Notebook Content *)

(* Internal cache information *)
(*CellTagsOutline
CellTagsIndex->{
 "TextAnnotation"->{
  Cell[19606, 520, 172, 3, 70, "ExampleText",ExpressionUUID->"b81e7488-558c-44e6-9b4c-25e731835374",
   CellTags->"TextAnnotation"]}
 }
*)
(*CellTagsIndex
CellTagsIndex->{
 {"TextAnnotation", 44411, 1209}
 }
*)
(*NotebookFileOutline
Notebook[{
Cell[583, 21, 6286, 152, 70, "AnchorBarGrid",ExpressionUUID->"c25bd172-ef03-4e83-8c6a-c93e6ff3e056",
 CellID->1],
Cell[6872, 175, 107, 0, 70, "ContextNameCell",ExpressionUUID->"a40659b7-f451-4d55-be3d-461b268b94fc"],
Cell[CellGroupData[{
Cell[7004, 179, 558, 14, 70, "ObjectNameGrid",ExpressionUUID->"3e767076-4c5b-492e-9dc2-d14cfff283d8"],
Cell[7565, 195, 3535, 94, 70, "Usage",ExpressionUUID->"f3e18a67-6667-4187-bbee-7768dcc20cff"]
}, Open  ]],
Cell[CellGroupData[{
Cell[11137, 294, 1443, 34, 70, "NotesSection",ExpressionUUID->"7c7d9647-91a8-4826-8a17-da246ce7352b",
 CellGroupingRules->{"SectionGrouping", 50},
 CellID->773875941],
Cell[12583, 330, 1658, 42, 70, "Notes",ExpressionUUID->"b7beaa1b-292c-443e-83a9-194e974fb5d5"],
Cell[14244, 374, 1171, 31, 70, "Notes",ExpressionUUID->"c674927b-6625-421d-9c00-680c05d4e370"],
Cell[15418, 407, 246, 4, 70, "Notes",ExpressionUUID->"7f2e59a3-0bbf-4b0d-9185-5663e04734bb"],
Cell[15667, 413, 202, 3, 70, "Notes",ExpressionUUID->"aedd1307-62b6-47c9-a95a-69920f3d4a5d"],
Cell[15872, 418, 236, 4, 70, "Notes",ExpressionUUID->"f38b122c-a11c-40e2-8cfd-5cdc0d1441a2"],
Cell[16111, 424, 278, 4, 70, "Notes",ExpressionUUID->"4d459ba3-2dc0-41e5-a3cb-385ebfcc7b7c"],
Cell[16392, 430, 209, 3, 70, "Notes",ExpressionUUID->"060b76fb-b233-4fd4-9855-dde9ab4e6f5d"]
}, Closed]],
Cell[16616, 436, 80, 0, 70, "PageDelimiter",ExpressionUUID->"d9769cf5-14a6-4e9d-9486-6e9e2415b12a"],
Cell[CellGroupData[{
Cell[16721, 440, 1402, 37, 70, "PrimaryExamplesSection",ExpressionUUID->"2b7c6f99-f054-482f-a893-dba7abb0d009",
 CellID->1371974155],
Cell[18126, 479, 216, 4, 70, "Input",ExpressionUUID->"7dfedd32-fe95-4460-8ad8-eeb7c59e77e5",
 CellID->1969679695],
Cell[CellGroupData[{
Cell[18367, 487, 1236, 31, 70, "ExampleSection",ExpressionUUID->"5066218a-97e9-4e9d-9a3a-d64438f31229",
 CellID->1237705246],
Cell[19606, 520, 172, 3, 70, "ExampleText",ExpressionUUID->"b81e7488-558c-44e6-9b4c-25e731835374",
 CellTags->"TextAnnotation"],
Cell[CellGroupData[{
Cell[19803, 527, 435, 10, 70, "Input",ExpressionUUID->"66f90eab-4ceb-4f52-a933-78ac3ecbc042"],
Cell[20241, 539, 685, 12, 70, "Output",ExpressionUUID->"2e47206c-8507-4cc6-abb1-6e88329e56c4"]
}, Open  ]],
Cell[CellGroupData[{
Cell[20963, 556, 224, 5, 70, "ExampleDelimiter",ExpressionUUID->"d64f15fb-777a-4f9f-9e7b-b036ddeaff2e"],
Cell[21190, 563, 155, 2, 70, "ExampleText",ExpressionUUID->"db140be5-3271-4ae7-bf56-9d6c498c1a4a"],
Cell[CellGroupData[{
Cell[21370, 569, 377, 9, 70, "Input",ExpressionUUID->"b6b7597a-5855-4c13-b865-cd7102ea56d6"],
Cell[21750, 580, 113, 1, 70, "Output",ExpressionUUID->"e0b8a99f-ce02-4576-a21f-4596f86c04e1"]
}, Open  ]]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[21924, 588, 1227, 31, 70, "ExampleSection",ExpressionUUID->"456c4570-f9a0-4484-bbef-342d2cbf08ae",
 CellID->1293636265],
Cell[23154, 621, 450, 12, 70, "ExampleText",ExpressionUUID->"0ec5a272-23e2-4e20-80bf-c54693fc3027"],
Cell[CellGroupData[{
Cell[23629, 637, 571, 13, 70, "Input",ExpressionUUID->"ce479458-a610-491d-bff4-51c2405d7960"],
Cell[24203, 652, 313, 6, 70, "Output",ExpressionUUID->"def3a0bf-9895-4b32-bb17-bea15578837b"]
}, Open  ]],
Cell[CellGroupData[{
Cell[24553, 663, 224, 5, 70, "ExampleDelimiter",ExpressionUUID->"479f5bb0-b1b9-466a-9fdc-7d1dd4681258"],
Cell[24780, 670, 218, 3, 70, "ExampleText",ExpressionUUID->"fdbbfe1b-7211-4480-a8e6-5e85ecfe0685"],
Cell[CellGroupData[{
Cell[25023, 677, 784, 18, 70, "Input",ExpressionUUID->"5064fd01-32d2-4a08-95a9-d31631447ab0"],
Cell[25810, 697, 112, 1, 70, "Output",ExpressionUUID->"31e70e10-2f2c-4aad-af63-0d89accc317d"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[25971, 704, 224, 5, 70, "ExampleDelimiter",ExpressionUUID->"383f7541-bd3a-47ef-b3ac-a9e88e7d980e"],
Cell[26198, 711, 139, 1, 70, "ExampleText",ExpressionUUID->"df50734c-6090-4d9d-a88c-298c364bab02"],
Cell[CellGroupData[{
Cell[26362, 716, 585, 14, 70, "Input",ExpressionUUID->"1a3c888b-4dfb-45a9-9da6-a291a9a86b38"],
Cell[26950, 732, 107, 1, 70, "Output",ExpressionUUID->"55019e00-1ee4-4e08-bc7f-b47b0f35ff15"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[27106, 739, 224, 5, 70, "ExampleDelimiter",ExpressionUUID->"89aed5af-4af2-42c9-988a-670818c7654c"],
Cell[27333, 746, 157, 2, 70, "ExampleText",ExpressionUUID->"b6c184df-022c-4122-ad6c-b5cc24f0c6f0"],
Cell[CellGroupData[{
Cell[27515, 752, 276, 6, 70, "Input",ExpressionUUID->"0751a147-7462-44e0-8ae7-007188c4f08f"],
Cell[27794, 760, 789, 16, 70, "Output",ExpressionUUID->"5beda0b4-ed09-4299-84ee-b29bb3e05798"]
}, Open  ]]
}, Open  ]]
}, Closed]],
Cell[CellGroupData[{
Cell[28644, 783, 1233, 31, 70, "ExampleSection",ExpressionUUID->"b6051eeb-cf81-45e7-ab2f-b3259c12f431",
 CellID->258228157],
Cell[29880, 816, 159, 2, 70, "ExampleText",ExpressionUUID->"459c5fe1-9dd5-4c1a-aa9d-fe999cdb1fed"],
Cell[CellGroupData[{
Cell[30064, 822, 728, 17, 70, "Input",ExpressionUUID->"83971be7-0c29-4ce4-b4d0-3842ee1f817b"],
Cell[30795, 841, 176, 3, 70, "Output",ExpressionUUID->"7673ac91-5495-473b-b79d-265897ad90d3"]
}, Open  ]]
}, Closed]],
Cell[CellGroupData[{
Cell[31020, 850, 1244, 31, 70, "ExampleSection",ExpressionUUID->"eeee8d98-152e-40dd-bc32-c4a989e5f356",
 CellID->2123667759],
Cell[32267, 883, 872, 25, 70, "ExampleText",ExpressionUUID->"f22cb552-2161-4183-84b0-7a2334f9eb93"],
Cell[CellGroupData[{
Cell[33164, 912, 749, 19, 70, "Input",ExpressionUUID->"8298ecbd-8bda-4f30-a211-24d2104b7b96"],
Cell[33916, 933, 110, 1, 70, "Output",ExpressionUUID->"89b416b7-6e2f-4d6c-8411-c8ddf7f758db"]
}, Open  ]],
Cell[CellGroupData[{
Cell[34063, 939, 224, 5, 70, "ExampleDelimiter",ExpressionUUID->"1055a4ff-23b1-44ef-b123-70553df3ac73"],
Cell[34290, 946, 183, 3, 70, "ExampleText",ExpressionUUID->"cabc3fd9-c27a-48eb-a4a8-b257cde5de6a"],
Cell[CellGroupData[{
Cell[34498, 953, 819, 22, 70, "Input",ExpressionUUID->"f9726fe3-1a0e-4f2f-a0d3-08c47b7dc8c2"],
Cell[35320, 977, 110, 1, 70, "Output",ExpressionUUID->"a78d7b58-123e-4604-8500-13f37d9a33b7"]
}, Open  ]]
}, Open  ]]
}, Closed]],
Cell[CellGroupData[{
Cell[35491, 985, 1237, 31, 70, "ExampleSection",ExpressionUUID->"1585b794-4eb0-4802-9744-b30de5d0f016",
 CellID->1305812373],
Cell[36731, 1018, 289, 4, 70, "ExampleText",ExpressionUUID->"98a413fb-5f7d-479b-be5a-6610d90fd540"],
Cell[CellGroupData[{
Cell[37045, 1026, 893, 22, 70, "Input",ExpressionUUID->"91d1b5dc-8c52-42f8-bec4-16d8dd0df95d"],
Cell[37941, 1050, 115, 1, 70, "Output",ExpressionUUID->"4202a1e0-cd5d-4520-a2d8-e9201eadf5cf"]
}, Open  ]]
}, Closed]]
}, Open  ]],
Cell[38095, 1056, 3084, 81, 70, "SeeAlsoSection",ExpressionUUID->"0893d998-d687-4060-a2af-97b2d00e4df7"],
Cell[41182, 1139, 742, 19, 70, "MoreAboutSection",ExpressionUUID->"a8f64465-27c3-4c59-831f-93392d52392c"],
Cell[41927, 1160, 78, 0, 70, "FooterCell",ExpressionUUID->"945db665-55a1-414e-9424-2ab214af2e5b"]
}
]
*)

(* End of internal cache information *)

