Question: A simple but hopefully not quite trivial challenge:

Write a program or function that adds up the `k`th 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 `k`th 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} -> 159120
{40320, 2} -> 850
{40320, 3} -> 73
{40320, 4} -> 17
{40320, 5} -> 33
{40320, 6} -> 65
{40320, 7} -> 129
{40320, 8} -> 1
{46656, 1} -> 138811
{46656, 2} -> 69700
{46656, 3} -> 55261
{46656, 4} -> 1394
{46656, 5} -> 8052
{46656, 6} -> 47450
{46656, 7} -> 1
{1, [any positive integer]} -> 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.

Answer: 
Scala 63 bytes
==============

```
(n:Int,k:Int)=>1 to n map{Math.pow(_,k).toInt}filter{n%_==0}sum

```
[Japt](https://github.com/ETHproductions/japt) [`-x`](https://codegolf.meta.stackexchange.com/a/14339/), 9 [bytes](https://en.wikipedia.org/wiki/ISO/IEC_8859-1)
================================================================================================================================================================

```
ÆvX=pV)*X

```

[Try it](https://petershaggynoble.github.io/Japt-Interpreter/?v=1.4.6&flags=LXg&code=xnZYPXBWKSpY&input=NDAzMjAKMw)

8 bytes
-------

My first pass. Realised as I was about to post it that it's pretty much identical to Oliver's existing solution.

```
opV f@vX

```

[Try it](https://petershaggynoble.github.io/Japt-Interpreter/?v=1.4.6&flags=LXg&code=b3BWIGZAdlg&input=NDAzMjAKMw)

```
ÆvX=pV)*X     :Implicit input of integers U=n & V=k
Æ             :Map each X in the range [0,U)
 v            :  Is U divisible by
  X=          :    Reassign to X
    pV        :    X raised to the power of V
      )       :  End divisibility check
       *X     :  Multiply by X
              :Implicit output of sum of resulting array

```