Sum the powers that be A simple but hopefully not quite trivial challenge:

Write a program or function that adds up the kth powers dividing a number n. More specifically:


Input: two positive integers n and k (or an ordered pair of integers, etc.)
Output: the sum of all of the positive divisors of n that are kth powers of integers


For example, 11! = 39916800 has six divisors that are cubes, namely 1, 8, 27, 64, 216, and 1728. Therefore given inputs 39916800 and 3, the program should return their sum, 2044.

Other test cases:

{40320, 1} -&gt; 159120
{40320, 2} -&gt; 850
{40320, 3} -&gt; 73
{40320, 4} -&gt; 17
{40320, 5} -&gt; 33
{40320, 6} -&gt; 65
{40320, 7} -&gt; 129
{40320, 8} -&gt; 1
{46656, 1} -&gt; 138811
{46656, 2} -&gt; 69700
{46656, 3} -&gt; 55261
{46656, 4} -&gt; 1394
{46656, 5} -&gt; 8052
{46656, 6} -&gt; 47450
{46656, 7} -&gt; 1
{1, [any positive integer]} -&gt; 1


This is code golf, so the shorter your code, the better. I welcome golfed code in all kinds of different languages, even if some other language can get away with fewer bytes than yours.
05AB1E, 9 bytes

DLImDŠÖÏO


Try it online!

Explanation

Example input 46656, 3

D          # duplicate first input
           # STACK: 46656, 46656
 L         # range [1 ... first input]
           # STACK: 46656, [1 ... 46656]
  Im       # each to the power of second input
           # STACK: 46656, [1, 8, 27 ...]
    D      # duplicate
           # STACK: 46656, [1, 8, 27 ...], [1, 8, 27 ...]
     Š     # move down 2 spots on the stack
           # STACK: [1, 8, 27 ...], 46656, [1, 8, 27 ...]
      Ö    # a mod b == 0
           # STACK: [1, 8, 27 ...], [1,1,1,1,0 ...]
       Ï   # keep only items from first list which are true in second
           # STACK: [1, 8, 27, 64, 216, 729, 1728, 5832, 46656]
        O  # sum
           # OUTPUT: 55261