Groundhog Puzzle












7












$begingroup$


A groundhog has made an infinite number of holes one metre apart in a straight line in both directions on an infinite plane. Every day it travels a fixed number of holes in one direction. A farmer would like to catch the groundhog by shining a torch into one of the holes at midnight when it is asleep.



What strategy can the farmer use to ensure that he catches the groundhog eventually?










share|improve this question









New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$








  • 1




    $begingroup$
    Possible duplicate of Sink the Submarine
    $endgroup$
    – Jaap Scherphuis
    40 mins ago
















7












$begingroup$


A groundhog has made an infinite number of holes one metre apart in a straight line in both directions on an infinite plane. Every day it travels a fixed number of holes in one direction. A farmer would like to catch the groundhog by shining a torch into one of the holes at midnight when it is asleep.



What strategy can the farmer use to ensure that he catches the groundhog eventually?










share|improve this question









New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$








  • 1




    $begingroup$
    Possible duplicate of Sink the Submarine
    $endgroup$
    – Jaap Scherphuis
    40 mins ago














7












7








7





$begingroup$


A groundhog has made an infinite number of holes one metre apart in a straight line in both directions on an infinite plane. Every day it travels a fixed number of holes in one direction. A farmer would like to catch the groundhog by shining a torch into one of the holes at midnight when it is asleep.



What strategy can the farmer use to ensure that he catches the groundhog eventually?










share|improve this question









New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$




A groundhog has made an infinite number of holes one metre apart in a straight line in both directions on an infinite plane. Every day it travels a fixed number of holes in one direction. A farmer would like to catch the groundhog by shining a torch into one of the holes at midnight when it is asleep.



What strategy can the farmer use to ensure that he catches the groundhog eventually?







mathematics






share|improve this question









New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited 2 hours ago









Glorfindel

14.8k45687




14.8k45687






New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 2 hours ago









Jeff BehJeff Beh

361




361




New contributor




Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Jeff Beh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.








  • 1




    $begingroup$
    Possible duplicate of Sink the Submarine
    $endgroup$
    – Jaap Scherphuis
    40 mins ago














  • 1




    $begingroup$
    Possible duplicate of Sink the Submarine
    $endgroup$
    – Jaap Scherphuis
    40 mins ago








1




1




$begingroup$
Possible duplicate of Sink the Submarine
$endgroup$
– Jaap Scherphuis
40 mins ago




$begingroup$
Possible duplicate of Sink the Submarine
$endgroup$
– Jaap Scherphuis
40 mins ago










3 Answers
3






active

oldest

votes


















3












$begingroup$

The farmer can




enumerate all the possible groundhog-trajectories -- there are only countably many of them -- and then on day N shine the torch into the hole the groundhog will be in on day N if it is on trajectory N.




More concretely




associate with the number $2^a3^b5^c7^d$ where $a,b,c,d$ are non-negative integers the possibility that the groundhog is at position $(-1)^acdot b$ on day 0, and moves by $(-1)^ccdot d$ on each day. List all positive integers in order, one per night, and when on night $n$ you find one of the form $2^a3^b5^c7^d$ shine the torch into hole $(-1)^acdot b + ncdot(-1)^ccdot d$. (There are much more efficient strategies than this one, but clearly the farmer has all the time in the world and more in any case.)







share|improve this answer









$endgroup$









  • 1




    $begingroup$
    Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
    $endgroup$
    – visualnotsobasic
    18 mins ago










  • $begingroup$
    @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
    $endgroup$
    – colmde
    7 mins ago





















1












$begingroup$

Extending Gareth McCaughan's answer, the farmer can:




Enumerate all the possible options. Draw a diagram with "starting position" on the X axis, and "groundhog speed" on the Y axis. Hit all the points on the integer grid for that diagram.




For example, follow the path:




Path for hitting all the integer grid points Start at the red "X" (the origin) on day 1, then follow the arrows to all the grid points.




To determine which hole to illuminate each day:




Pick an arbitrary hole to label hole zero, then number the rest like a number line. The hole ($H$) to illuminate on day $d$ is: $H = x + d times y$. For example, on day 1, illuminate the arbitrarily chosen hole 0. On day 2, illuminate hole 1. On day 3 illuminate hole 3, etc. On day 16, the grid position is (1,2), so the hole would be number 33.




This ensures that no matter which hole the groundhog started in or how many holes it moves each day, the farmer will eventually catch him.






share|improve this answer









$endgroup$





















    0












    $begingroup$

    The farmer should




    Look in the hole that is the number of days since started squared (e.g. 1, 2, 9, 16, etc.).




    Because of this, the farmer will eventually catch the groundhog on day N, where




    N is the number of holes the groundhog moves per day.




    EDIT: Just realized that this will only work assuming you know which direction the groundhog starts travelling in. I will leave it here in case it gives someone an idea though.






    share|improve this answer









    $endgroup$









    • 1




      $begingroup$
      doesn't this also assume that the farmer knows where the groundhog started?
      $endgroup$
      – Bass
      1 hour ago










    • $begingroup$
      @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
      $endgroup$
      – APrough
      1 hour ago












    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "559"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });






    Jeff Beh is a new contributor. Be nice, and check out our Code of Conduct.










    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fpuzzling.stackexchange.com%2fquestions%2f83341%2fgroundhog-puzzle%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    3 Answers
    3






    active

    oldest

    votes








    3 Answers
    3






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    3












    $begingroup$

    The farmer can




    enumerate all the possible groundhog-trajectories -- there are only countably many of them -- and then on day N shine the torch into the hole the groundhog will be in on day N if it is on trajectory N.




    More concretely




    associate with the number $2^a3^b5^c7^d$ where $a,b,c,d$ are non-negative integers the possibility that the groundhog is at position $(-1)^acdot b$ on day 0, and moves by $(-1)^ccdot d$ on each day. List all positive integers in order, one per night, and when on night $n$ you find one of the form $2^a3^b5^c7^d$ shine the torch into hole $(-1)^acdot b + ncdot(-1)^ccdot d$. (There are much more efficient strategies than this one, but clearly the farmer has all the time in the world and more in any case.)







    share|improve this answer









    $endgroup$









    • 1




      $begingroup$
      Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
      $endgroup$
      – visualnotsobasic
      18 mins ago










    • $begingroup$
      @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
      $endgroup$
      – colmde
      7 mins ago


















    3












    $begingroup$

    The farmer can




    enumerate all the possible groundhog-trajectories -- there are only countably many of them -- and then on day N shine the torch into the hole the groundhog will be in on day N if it is on trajectory N.




    More concretely




    associate with the number $2^a3^b5^c7^d$ where $a,b,c,d$ are non-negative integers the possibility that the groundhog is at position $(-1)^acdot b$ on day 0, and moves by $(-1)^ccdot d$ on each day. List all positive integers in order, one per night, and when on night $n$ you find one of the form $2^a3^b5^c7^d$ shine the torch into hole $(-1)^acdot b + ncdot(-1)^ccdot d$. (There are much more efficient strategies than this one, but clearly the farmer has all the time in the world and more in any case.)







    share|improve this answer









    $endgroup$









    • 1




      $begingroup$
      Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
      $endgroup$
      – visualnotsobasic
      18 mins ago










    • $begingroup$
      @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
      $endgroup$
      – colmde
      7 mins ago
















    3












    3








    3





    $begingroup$

    The farmer can




    enumerate all the possible groundhog-trajectories -- there are only countably many of them -- and then on day N shine the torch into the hole the groundhog will be in on day N if it is on trajectory N.




    More concretely




    associate with the number $2^a3^b5^c7^d$ where $a,b,c,d$ are non-negative integers the possibility that the groundhog is at position $(-1)^acdot b$ on day 0, and moves by $(-1)^ccdot d$ on each day. List all positive integers in order, one per night, and when on night $n$ you find one of the form $2^a3^b5^c7^d$ shine the torch into hole $(-1)^acdot b + ncdot(-1)^ccdot d$. (There are much more efficient strategies than this one, but clearly the farmer has all the time in the world and more in any case.)







    share|improve this answer









    $endgroup$



    The farmer can




    enumerate all the possible groundhog-trajectories -- there are only countably many of them -- and then on day N shine the torch into the hole the groundhog will be in on day N if it is on trajectory N.




    More concretely




    associate with the number $2^a3^b5^c7^d$ where $a,b,c,d$ are non-negative integers the possibility that the groundhog is at position $(-1)^acdot b$ on day 0, and moves by $(-1)^ccdot d$ on each day. List all positive integers in order, one per night, and when on night $n$ you find one of the form $2^a3^b5^c7^d$ shine the torch into hole $(-1)^acdot b + ncdot(-1)^ccdot d$. (There are much more efficient strategies than this one, but clearly the farmer has all the time in the world and more in any case.)








    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered 2 hours ago









    Gareth McCaughanGareth McCaughan

    68.9k3174270




    68.9k3174270








    • 1




      $begingroup$
      Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
      $endgroup$
      – visualnotsobasic
      18 mins ago










    • $begingroup$
      @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
      $endgroup$
      – colmde
      7 mins ago
















    • 1




      $begingroup$
      Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
      $endgroup$
      – visualnotsobasic
      18 mins ago










    • $begingroup$
      @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
      $endgroup$
      – colmde
      7 mins ago










    1




    1




    $begingroup$
    Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
    $endgroup$
    – visualnotsobasic
    18 mins ago




    $begingroup$
    Can I ask how one learns things like this without a formal education in math? I find these things fascinating and would really like to get better at these sorts of questions.
    $endgroup$
    – visualnotsobasic
    18 mins ago












    $begingroup$
    @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
    $endgroup$
    – colmde
    7 mins ago






    $begingroup$
    @visualnotsobasic - I'm sure there's a farmer nearby who wouldn't mind teaching you this stuff...
    $endgroup$
    – colmde
    7 mins ago













    1












    $begingroup$

    Extending Gareth McCaughan's answer, the farmer can:




    Enumerate all the possible options. Draw a diagram with "starting position" on the X axis, and "groundhog speed" on the Y axis. Hit all the points on the integer grid for that diagram.




    For example, follow the path:




    Path for hitting all the integer grid points Start at the red "X" (the origin) on day 1, then follow the arrows to all the grid points.




    To determine which hole to illuminate each day:




    Pick an arbitrary hole to label hole zero, then number the rest like a number line. The hole ($H$) to illuminate on day $d$ is: $H = x + d times y$. For example, on day 1, illuminate the arbitrarily chosen hole 0. On day 2, illuminate hole 1. On day 3 illuminate hole 3, etc. On day 16, the grid position is (1,2), so the hole would be number 33.




    This ensures that no matter which hole the groundhog started in or how many holes it moves each day, the farmer will eventually catch him.






    share|improve this answer









    $endgroup$


















      1












      $begingroup$

      Extending Gareth McCaughan's answer, the farmer can:




      Enumerate all the possible options. Draw a diagram with "starting position" on the X axis, and "groundhog speed" on the Y axis. Hit all the points on the integer grid for that diagram.




      For example, follow the path:




      Path for hitting all the integer grid points Start at the red "X" (the origin) on day 1, then follow the arrows to all the grid points.




      To determine which hole to illuminate each day:




      Pick an arbitrary hole to label hole zero, then number the rest like a number line. The hole ($H$) to illuminate on day $d$ is: $H = x + d times y$. For example, on day 1, illuminate the arbitrarily chosen hole 0. On day 2, illuminate hole 1. On day 3 illuminate hole 3, etc. On day 16, the grid position is (1,2), so the hole would be number 33.




      This ensures that no matter which hole the groundhog started in or how many holes it moves each day, the farmer will eventually catch him.






      share|improve this answer









      $endgroup$
















        1












        1








        1





        $begingroup$

        Extending Gareth McCaughan's answer, the farmer can:




        Enumerate all the possible options. Draw a diagram with "starting position" on the X axis, and "groundhog speed" on the Y axis. Hit all the points on the integer grid for that diagram.




        For example, follow the path:




        Path for hitting all the integer grid points Start at the red "X" (the origin) on day 1, then follow the arrows to all the grid points.




        To determine which hole to illuminate each day:




        Pick an arbitrary hole to label hole zero, then number the rest like a number line. The hole ($H$) to illuminate on day $d$ is: $H = x + d times y$. For example, on day 1, illuminate the arbitrarily chosen hole 0. On day 2, illuminate hole 1. On day 3 illuminate hole 3, etc. On day 16, the grid position is (1,2), so the hole would be number 33.




        This ensures that no matter which hole the groundhog started in or how many holes it moves each day, the farmer will eventually catch him.






        share|improve this answer









        $endgroup$



        Extending Gareth McCaughan's answer, the farmer can:




        Enumerate all the possible options. Draw a diagram with "starting position" on the X axis, and "groundhog speed" on the Y axis. Hit all the points on the integer grid for that diagram.




        For example, follow the path:




        Path for hitting all the integer grid points Start at the red "X" (the origin) on day 1, then follow the arrows to all the grid points.




        To determine which hole to illuminate each day:




        Pick an arbitrary hole to label hole zero, then number the rest like a number line. The hole ($H$) to illuminate on day $d$ is: $H = x + d times y$. For example, on day 1, illuminate the arbitrarily chosen hole 0. On day 2, illuminate hole 1. On day 3 illuminate hole 3, etc. On day 16, the grid position is (1,2), so the hole would be number 33.




        This ensures that no matter which hole the groundhog started in or how many holes it moves each day, the farmer will eventually catch him.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered 15 mins ago









        user3294068user3294068

        5,7841729




        5,7841729























            0












            $begingroup$

            The farmer should




            Look in the hole that is the number of days since started squared (e.g. 1, 2, 9, 16, etc.).




            Because of this, the farmer will eventually catch the groundhog on day N, where




            N is the number of holes the groundhog moves per day.




            EDIT: Just realized that this will only work assuming you know which direction the groundhog starts travelling in. I will leave it here in case it gives someone an idea though.






            share|improve this answer









            $endgroup$









            • 1




              $begingroup$
              doesn't this also assume that the farmer knows where the groundhog started?
              $endgroup$
              – Bass
              1 hour ago










            • $begingroup$
              @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
              $endgroup$
              – APrough
              1 hour ago
















            0












            $begingroup$

            The farmer should




            Look in the hole that is the number of days since started squared (e.g. 1, 2, 9, 16, etc.).




            Because of this, the farmer will eventually catch the groundhog on day N, where




            N is the number of holes the groundhog moves per day.




            EDIT: Just realized that this will only work assuming you know which direction the groundhog starts travelling in. I will leave it here in case it gives someone an idea though.






            share|improve this answer









            $endgroup$









            • 1




              $begingroup$
              doesn't this also assume that the farmer knows where the groundhog started?
              $endgroup$
              – Bass
              1 hour ago










            • $begingroup$
              @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
              $endgroup$
              – APrough
              1 hour ago














            0












            0








            0





            $begingroup$

            The farmer should




            Look in the hole that is the number of days since started squared (e.g. 1, 2, 9, 16, etc.).




            Because of this, the farmer will eventually catch the groundhog on day N, where




            N is the number of holes the groundhog moves per day.




            EDIT: Just realized that this will only work assuming you know which direction the groundhog starts travelling in. I will leave it here in case it gives someone an idea though.






            share|improve this answer









            $endgroup$



            The farmer should




            Look in the hole that is the number of days since started squared (e.g. 1, 2, 9, 16, etc.).




            Because of this, the farmer will eventually catch the groundhog on day N, where




            N is the number of holes the groundhog moves per day.




            EDIT: Just realized that this will only work assuming you know which direction the groundhog starts travelling in. I will leave it here in case it gives someone an idea though.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered 1 hour ago









            AProughAPrough

            5,9061245




            5,9061245








            • 1




              $begingroup$
              doesn't this also assume that the farmer knows where the groundhog started?
              $endgroup$
              – Bass
              1 hour ago










            • $begingroup$
              @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
              $endgroup$
              – APrough
              1 hour ago














            • 1




              $begingroup$
              doesn't this also assume that the farmer knows where the groundhog started?
              $endgroup$
              – Bass
              1 hour ago










            • $begingroup$
              @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
              $endgroup$
              – APrough
              1 hour ago








            1




            1




            $begingroup$
            doesn't this also assume that the farmer knows where the groundhog started?
            $endgroup$
            – Bass
            1 hour ago




            $begingroup$
            doesn't this also assume that the farmer knows where the groundhog started?
            $endgroup$
            – Bass
            1 hour ago












            $begingroup$
            @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
            $endgroup$
            – APrough
            1 hour ago




            $begingroup$
            @Bass - it does. I clearly did not understand all of the parameters of the question, but still leave this incredibly incorrect answer here as a potential jumping off point.
            $endgroup$
            – APrough
            1 hour ago










            Jeff Beh is a new contributor. Be nice, and check out our Code of Conduct.










            draft saved

            draft discarded


















            Jeff Beh is a new contributor. Be nice, and check out our Code of Conduct.













            Jeff Beh is a new contributor. Be nice, and check out our Code of Conduct.












            Jeff Beh is a new contributor. Be nice, and check out our Code of Conduct.
















            Thanks for contributing an answer to Puzzling Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            Use MathJax to format equations. MathJax reference.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fpuzzling.stackexchange.com%2fquestions%2f83341%2fgroundhog-puzzle%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Ponta tanko

            Tantalo (mitologio)

            Erzsébet Schaár