[Question]
  [
You have a square board with a bunch of items laid out on it in one of a \$3 \times 3\$ grid of cells and you want to lift it up using balloons, but you can only attach balloons to the corners of the board. Your task is to determine the minimum number of balloons in each corner to make sure the board won't tip over in flight, but can still lift all its contents.
## "Physics" Model
* Each balloon can lift 0.25kg (these are very strong balloons)
* The board itself weighs 1kg, so you would need 1 balloon in each corner to lift an empty board
* Items in each corner cell only exert force on their respective corners (i.e. 4 balloons are needed in the corresponding corner per kg)
* Items on each edge cell split their force evenly between their neighboring corners (i.e. 2 balloons on each of the two corresponding corners per kg)
* Items in the center cell split their force evenly across all corners (i.e. 1 balloon is needed in each corner per kg)
## Example Test Cases
### 1
```
Input:
0 0 0
0 0 0
0 0 0
Output:
1 1
1 1
```
### 2
```
Input:
1 2 1
2 4 2
1 2 1
Output:
17 17
17 17
```
### 3
```
Input:
5 0 0
0 0 2
0 1 0
Output:
21 5
 3 7
```
### 4
```
Input:
12  9 35
 1 32  2
 4  6 18
Output:
101 195
 63 121
```
### 5
```
Input:
9999 9999 9999
9999 9999 9999
9999 9999 9999
Output:
89992 89992
89992 89992
```
### 6
```
Input:
9999    2 9001
   0 9999 9999
9999  999 9999
Output:
50000 66006
51994 71992
```
## Rules and Assumptions
* You may assume each cell is filled with a whole number between \$0\$ and \$9999\$ kg weight worth of items
* Use any convenient format for I/O
* Shortest code wins!
  
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 14 bytes
```
3Ḷ×þ`ZU$Ƭ×µ§§‘
```
[Try it online!](https://tio.run/##y0rNyan8/9/44Y5th6cf3pcQFapybM3h6Ye2Hlp@aPmjhhn///@PNjTSUbDUUTA2jdVRiDYEMoB8IxDbREfBTEfB0CIWAA "Jelly – Try It Online")
Takes input as a 3x3 matrix and outputs a list going clockwise starting from the bottom-right.
# Explanation
```
3Ḷ×þ`ZU$Ƭ×µ§§‘     Main Link
3Ḷ                 [0, 1, 2]
  ×þ`              outer product by multiplication with itself ([0, 0, 0], [0, 1, 2], [0, 2, 4])
        Ƭ          (include the original, plus) rotate clockwise until results are no longer unique (4 results total)
     ZU$           zip and upend (clockwise rotation)
         ×         vectorized multiply with original (gets the workload distributions to each balloon)
           §§      sum results for each balloon (vectorized-sum rows in the matrix; sum the results)
              ‘    increment
```
[Answer]
# [Python 2](https://docs.python.org/2/), ~~58~~ ~~57~~ 56 bytes
```
lambda c,*b:[b[~i]*4-~c+b[i]*2+b[i-2]*2for i in 0,2,4,6]
```
[Try it online!](https://tio.run/##hZAxT8MwEIX3@xVPsCTFRYnTlhapI4ywsIUI2Y1DXVInch0BC3@9nAst3bClu3e@Z/vT9Z9h3Tm5b5bP@1Ztda2wEiN9W@ryy1ajyfhrdaVLVjKmsWTRdB4W1iETUkzErNpbV2OJkjATyAXmglAIbuOG1URgKiAFVfS@tq3Bkx/MLeESCnaHzbALCGuDplUhGGdq6E75mrjNb1aE4D/ZjtO3XrlXkxRpPGTT1RKt3YVkq/rEuiC8en@xrh9Ckl7v@tZyTlOC@ViZPuDu8f7O@84fLl/CMHnX4OCPJ9ob9RbZdGSLWGoVBtUeHToyPXTOVBhhQT9QYhOxjBu2xqtgmKI@wOlyU7Ff8fgIvWc4NMlIp8fi4oJwRrvPwJvOI@WQyEliAvmraXrqS475wSWBBYopcVmwljx1YIZ8TrTghVP4p/ypeRVYZFkeJ5LFzvzMjT/3Nw "Python 2 – Try It Online")
**Input**: 9 numbers, representing the board in the following orders:
```
 6 1 8
 3 0 7
 4 5 2
```
**Output**: list of length 4, representing the balloons as follow:
```
1 0
2 3
```
## Explanation
`lambda c,*b:` separates the 9 numbers into the center `c` and a list of length 8 representing the corner and edge values:
```
5 0 7
2 _ 6
3 4 1
```
The reason for this is because length 8 works nicely with negative index, as shown as follow:
```
                Indices    |  Indices mod 8
Edge 1 (i)     0  2  4  6  |  0  2  4  6
Edge 2 (i-2)  -2  0  2  4  |  6  0  2  4
Corner (~i)   -1 -3 -5 -7  |  7  5  3  1
```
*-1 byte thanks to @xnor!*
[Answer]
# [Python 3](https://docs.python.org/3/), ~~86~~ ~~78~~ 77 bytes
Saved 8 bytes thanks to [xnor](https://codegolf.stackexchange.com/users/20260/xnor)!!!  
Saved a byte thanks to [S.S. Anne](https://codegolf.stackexchange.com/users/89298/s-s-anne)!!! 
```
lambda b:[[4*b[i][j]+2*b[1][j]+2*b[i][1]-~b[1][1]for j in(0,2)]for i in(0,2)]
```
[Try it online!](https://tio.run/##jVFRb4IwEH73V1x4sZUzoa0uQuLe97QfUHnACBsEKoGabDHur7NaZoWp2a7hrvfdfaXftf7U73slumy96cqk2u4S2EZSLmZbmceyiH1udsztDMbi@ZeFWJztGyggVyRATm2Wu6zTaatbWAOZgDEpAzQrxl8xxp8yQ47MwBwXyE3sc1deDljcRjZicwxRLC1PcNuxwCdkq2tLaAydMw1/AWMmCIQwCJj9NxhkZb3jwcU5Ip2cJ6LNRMDOIrJoZUZSpoq0uiFV8mE/beYKl/FBk6i3lAh6Np9ZUt3kShPvRdUHHXnUYjf9/fmXUnG/dD0t8466f@Po@VidTh5CqnbrKUzpZNxJh3fYqNeDHlzj/MQZ0X1S3hHX3hHHh@Juag@F8EdCWiek/LeQuTcjFfjA6EwMC7T7Bg "Python 3 – Try It Online")
Uses a list of lists for both input (\$3\times3\$) and output (\$2\times2\$).
[Answer]
# [Python 2](https://docs.python.org/2/), ~~69~~ ~~63~~ ~~59~~ ~~58~~ 57 bytes
```
lambda l:[2*(2*l[i]+l[i%2]+l[i/2])-~l[8]for i in 4,5,6,7]
```
[Try it online!](https://tio.run/##K6gsycjPM/qfZhvzPycxNyklUSHHKtpIS8NIKyc6M1YbSKgagSl9o1hN3bqcaIvYtPwihUyFzDwFEx1THTMd89j/OQq2CtGWQLahjpGOoZGOiY6xqY6hhY6xUSxXQVFmXolGmkaOpuZ/AA "Python 2 – Try It Online")
The input is in this order:
```
4 0 6
2 8 3
5 1 7
```
and output is
```
0 2
1 3
```
-1 thanks to @SurculoseSputum
I kept this solution because I started thinking about shuffling indices with it:
### [Python 3.8 (pre-release)](https://docs.python.org/3.8/), ~~82~~ ~~81~~ 80 bytes
```
def f(l):*l,d=l;return[(l:=l[2:]+l[:2])and-~d+2*(l[1]+l[7]+2*l[0])for _ in'0'*4]
```
[Try it online!](https://tio.run/##HY3BCsMgEETv/Qpv0SQFYykNBr9kWUrBSAPLRhZ76CW/bk1nGHgzl8nf8t75NmepNa5JJU3G9zTGQIus5SMMmnwgcB4HAu/QvDhejzi4XhNM5/jAVggsmrSLeqqNO9vUYSUVFNxH2@xapj9ZvGTZuOjzy9Qf "Python 3.8 (pre-release) – Try It Online")
Thanks HyperNeutrino, SSAnne and Surculose Sputum for -1 each!
[Answer]
# [R](https://www.r-project.org/), ~~76~~ ~~64~~ 50 bytes
-12 bytes thanks to Giuseppe!
-8 bytes with outer product `%*%`
-6 bytes by changing the order of the output
```
scan()%*%matrix(c(y<-2:0%o%c(2:0,0:2),rev(y)),9)+1
```
[Try it online!](https://tio.run/##DcUxCoAwDADAr2QJJFqhSVW0@JlSHBxUqCL29dFbrphdOR3E2OCe7rK9lKkunUaPJ2b6dz4qu7I@VJndzK2YKMwQBhAICgo9jCCTfQ "R – Try It Online")
Takes input as 9 integers, top to bottom and left to right. Output is in order (NW, SW, NE, SE).
Performs the matrix multiplication of the input vector with the matrix
```
4   0   0   0
2   0   2   0
0   0   4   0
2   2   0   0
1   1   1   1
0   0   2   2
0   4   0   0
0   2   0   2
0   0   0   4
```
which is constructed by inputting the values of the first two columns, and then combining with those columns in reverse.
[Answer]
# [05AB1E](https://github.com/Adriandmen/05AB1E/wiki/Commands), ~~26~~ ~~25~~ ~~17~~ 14 [bytes](https://github.com/Adriandmen/05AB1E/wiki/Codepage)
```
2ÝÂ‚Dδδ*€€*OO>
```
-8 bytes by porting [*@HyperNeutrino*'s Jelly answer](https://codegolf.stackexchange.com/a/200932/52210), so make sure to upvote him!!  
-3 bytes thanks to *@Grimmy*.
I/O are both integer-matrices. The output-matrix is mirrored diagonally (i.e. if the input-matrix would be `[[a,b,c],[d,e,f],[g,h,i]]` the output-matrix would result in `[[I,G],[C,A]]`).
[Try it online](https://tio.run/##yy9OTMpM/f/f6PDcw02PGma5nNtybovWo6Y1QKTl72/3/390tKGRjqWOsWmsTrShjrGRjhGQYaJjpmNoERsLAA) or [verify all test cases](https://tio.run/##yy9OTMpM/V@m5JlXUFpipaBkX3lopQ6Xkn9pCZT/3@jw3MNNjxpmuZzbcm6L1rmt57YeWqdVW@vvb/df59A2@//R0dEGOkAYq4NGAxnRhjpGOoZAhpGOiY4RkIbwQTKmSGqNwLQhTI@RjqWOsSlYtbERWNJEx0zH0AIsawkEOnACKEJIAK7JWMfSwMAQbBWQa4GuHKo6FgA).
**Explanation:**
```
2Ý       # Push list [0,1,2]
  Â      # Bifurcate it (short for Duplicate & Reverse copy)
   ‚     # Pair those two together: [[0,1,2],[2,1,0]]
    D    # Duplicate it
     δ   # Apply double-vectorized:
      δ  #  Inner apply double-vectorized:
       * #   Multiply:
         #    [[[[0,0,0],[0,1,2],[0,2,4]],
         #      [[0,0,0],[2,1,0],[4,2,0]]],
         #     [[[0,2,4],[0,1,2],[0,0,0]],
         #      [[4,2,0],[2,1,0],[0,0,0]]]]
€        # Map over each inner pair of matrices:
 €       #  Map over each matrix in this pair:
  *      #   Multiply each by the (implicit) input-matrix at the same indices
O        # Sum each row of the inner-most matrices
 O       # Sum those row-sums together as well
  >      # And increase each by 1 for the board itself
         # (after which the result is output implicitly)
```
[Answer]
# [R](https://www.r-project.org/), 47 bytes
```
x=scan();4*x[1:4]+2*x[5:8]+2*x[c(6:8,5)]+x[9]+1
```
[Try it online!](https://tio.run/##K/r/v8K2ODkxT0PT2kSrItrQyiRW2wjIMLWygDCSNcysLHRMNWO1K6ItY7UN/xsaKRibKhhaKJgoGCpYKhgpmCkYG/0HAA "R – Try It Online")
Input is a vector in the order
```
1 6 2 
5 9 7 
4 8 3
```
And output
```
1 2
4 3
```
[Answer]
# JavaScript (ES6), ~~63~~ 57 bytes
Takes input as a flat array of 9 integers. Outputs a flat array of 4 integers.
```
a=>[0,2,6,8].map(i=>a[i]*4+2*(a[3+i%6]+a[i>2?7:1])-~a[4])
```
[Try it online!](https://tio.run/##lU7LDoIwELz7Fb2YtFAILVDBBPyQpocNgqlBSsR49NdrxWjUlIObzWQfM7N7hCtMzVmPl2gw@9Z2lYWqlgnlVNBCxScYsa5qkFoFWcgDDDIN9Vqo0I1qvttsmSLRDWSmiG3MMJm@jXtzwB12JsifipDVD5dRxCl6YvZRMw83/7bjM7IFX7ctKUrzmZHy1wHh@sLDL104xV@4aPO4nSRs/s8rfevtHQ "JavaScript (Node.js) – Try It Online")
### How?
Below is the matrix of the item indices:
$$\pmatrix{
0&\color{red}1&2\\
\color{blue}3&4&\color{blue}5\\
6&\color{red}7&8}$$
We iterate on the indices of the corners \$i\in\{0,2,6,8\}\$.
The index of the left or right edge (\$\color{blue}3\$ or \$\color{blue}5\$) is given by:
$$H\_i=3+(i\bmod6)$$
The index of the top or bottom edge (\$\color{red}1\$ or \$\color{red}7\$) is given by:
$$V\_i=\cases{
1&\text{if $i\le2$}\\
7&\text{if $i>2$}
}$$
[Answer]
# [Charcoal](https://github.com/somebody1234/Charcoal), 27 bytes
```
Ｆ⁴«≔Ｅ³Ｅ⮌θ§μκθ⟦Ｉ⊕ΣＥθ×λΣＥκ×νμ
```
[Try it online!](https://tio.run/##NYw9D4IwFEVn@BVvfE2eAx8ajRNxYjAx6tZ0IFCVQIu0lZgYf3sFA3e5957hlI/ClF3Ren/rDGDK4BMGmbX1XeOxeGJCMNVZDtJYiT0jyFyuK/lGRdAwNoKe7cPgZGrtkB8K6zDXpZFKaicrvLzUX9QTXGslLbYEC2sWpgkUmyNG29d7znkUE8COIFkLCgE4ROOeWDz/dNwbgmgrhPCrof0B "Charcoal – Try It Online") Link is to verbose version of code. Outputs the four corners in order top right, top left, bottom left, bottom right as compared to the test case format. Explanation:
```
Ｆ⁴«
```
Process each corner in turn.
```
≔Ｅ³Ｅ⮌θ§μκθ
```
Rotate the board.
```
⟦Ｉ⊕ΣＥθ×λΣＥκ×νμ
```
Multiply each row and column by its coordinate, then sum the results, and increment the final total.
[Answer]
# [Python 3](https://docs.python.org/3/), ~~90~~ 86 bytes
```
lambda a,b,c,d,e,f,g,h,i:(4*a+2*b+2*d-~e,2*b+2*f+4*c-~e,2*d+4*g+2*h-~e,2*f+2*h+4*i-~e)
```
[Try it online!](https://tio.run/##LYhBCoMwFAWv4jKJT7DRbgqepLpITL4JtBrETTdePf4SeQzMvPQ7wrZ2mYYxf8zXOlMZWMxw8CAsCIgv0StTa2UZ15weRanu1VzSsS58hZL0V74ip8xpj@shSKj3E@09zTzQTlLmCw "Python 3 – Try It Online")
Thanks @xnor for the -4.
[Answer]
# [APL (Dyalog Extended)](https://github.com/abrudz/dyalog-apl-extended), 16 bytes
```
1+{⍉⊥2↑⍉↑⍵⍮⌽⍵}⍣2
```
[Try it online!](https://tio.run/##SyzI0U2pTMzJT9dNrShJzUtJTfn/31C7@lFv56OupUaP2iaCWCBy66PedY969gIZtY96Fxv9T3vUNuFRb9@jvqme/o@6mg@tNwYp65saHOQMJEM8PIP/pykAhTQMFIBQE5XigkgZAjmGIDFDkBSEB5cyAkkZKZgoGGlCeTApIwVLBWNTkKixEUjWRMFMwdBCEwA "APL (Dyalog Extended) – Try It Online")
An anonymous function that takes a 3x3 matrix and returns a 2x2 matrix.
### How it works
```
1+{⍉⊥2↑⍉↑⍵⍮⌽⍵}⍣2  ⍝ Input: 3x3 matrix of numbers
  {     ↑⍵⍮⌽⍵}    ⍝ Join the input with its horizontal reverse,
                  ⍝ adding a leading length-2 axis
   ⍉   ⍉          ⍝ For each row (last axis),
     2↑           ⍝ Take the first two numbers x, y and
    ⊥             ⍝ Apply base-2, i.e. evaluate (2×x)+y
                  ⍝ (equivalent to dot product with [2 1 0])
              ⍣2  ⍝ Repeat the above twice
1+                ⍝ Increment element-wise
```
[Answer]
# Excel (as CSV), 92 bytes
```
,,,=1+A1*4+(B1+A2)*2+B2,=1+C1*4+(B1+C2)*2+B2
,,,=1+A3*4+(B3+A2)*2+B2,=1+C3*4+(B3+C2)*2+B2
,,
```
To use:
 Input between `,`'s, save as CSV, open in Excel.
Eg:
```
12,9,35,=1+A1*4+(B1+A2)*2+B2,=1+C1*4+(B1+C2)*2+B2
1,32,2,=1+A3*4+(B3+A2)*2+B2,=1+C3*4+(B3+C2)*2+B2
4,6,18
```
[Answer]
# [GolfScript](http://www.golfscript.com/golfscript/), 73 bytes
```
:a;0{..2/2*:x;2%2*:y;).2%!a...x=y=4*\x=1=2*+\1=y=2*+\1=1=+)`" "+\n*+\}4*;
```
Just here to submit something. Cool question! stack-based languages are NOT the solution. Fuck this shit, lmfao.
Could probably golf with better modulo shit, but I've stopped caring lol
[Try the really "golf-inputted" one, awkward for input](https://tio.run/##JcdBCsIwEEbhvaf4LXTRBEZnGkUb5iRJwCIoQlFRFyni2WPE1Xvf@TadnsfH5f4qIbAAe/SbtEBg9FXyWwdswbuUyjD69ZtIVmKG7KWtmX1H0i5HIso6qzMxK6sYG7nyX1bbHRo0Nl6rP874Ur4 "GolfScript – Try It Online")
[Same program, weird header and footer to format OP's input into the one above, easier to use and test. Plus, look at that identically-formatted output. Gorgeous, ainnit?](https://tio.run/##JY3RCoIwGIXvfYo/YRfut183Lcqx8D1akASGGCuqC2XMV1@Trs754PCd@/PRf27v4fUNtnAppMwtnnkWmk6VjkgWkjeTkizGrDKSbNMR0aRnXXMzaaElRyMi/lNozK5Rg8ZG9jVXARHtdjWXzajWC6R8PDnKI3rnh96zCKNZN9ygZ@fFtu0lCAlwhGqXgIAqdplADbAHcfgB "GolfScript – Try It Online")
[Answer]
# [Perl 5](https://www.perl.org/) `-MList::Util=sum -MPOSIX -a`, 76 bytes
```
map$_*=++$i==5||$i%2*2+2,@F;map{say ceil.25+sum@F[$_,$_+1,$_+3,$_+4]}0,1,3,4
```
[Try it online!](https://tio.run/##FYzLCsIwFER/5S7ipklLHo1oJdBVQVAURBBEQpAuAqkNJi7E@uvGdHNmOAPj@6eTKQ3GI10ojJFVSk4TsgtecMxJ223y9gnmDffeuopLHF5D212RJkhjNkPMqG9fShgRpE6JcYA1CAkMRK4caoAlsNVv9NGOj5DKvawoozl3NsSmOUfrVP7N4ng4bS@pNH8 "Perl 5 – Try It Online")
### Input:
If the grid is denoted as:
```
a b c
d e f
g h i
```
Then the input is space separated:
```
a b c d e f g h i
```
### Output:
Output is line separated:
```
balloons attached at a
balloons attached at c
balloons attached at g
balloons attached at i
```
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), ~~21~~ 19 bytes
```
3,1p`ạ€3Rp`¤P€€×³§‘
```
[Try it online!](https://tio.run/##y0rNyan8/99Yx7Ag4eGuhY@a1hgHFSQcWhIAZAHR4emHNh9a/qhhxv///6MNjXQULHUUjE11FAyBFJAHRCY6CmZAvkUsAA "Jelly – Try It Online")
# How?
Notice that we can create the weight matrices for each corner by finding the absolute difference to the opposite corners.
For example, for the first balloon, the weight matrix is 
```
4 2 0
2 1 0
0 0 0
```
This can be found by, for each coordinate, find the absolute difference to the corner (3, 3), and product. For example, (1, 1) has an absolute difference (2, 2) and product 4. 
```
3,1p`ạ€3Rp`¤P€€×³§‘    Main link
3,1                      Get 3,1 pair
   p`                    cartesian product with itself, gives the 3 corner coordinates
       3Rp`¤             Get all the coordinates
     ạ€                  get the absolute differences for each corner coordinate
            P€€          product each subsublist
               ×³        vectorize multiply with the input
                 §‘      sum each sublist and increment
```
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 14 [bytes](https://github.com/DennisMitchell/jelly/wiki/Code-page)
```
ŒJḂ§2*ṁ×⁸+Ɲ⁺€‘
```
A monadic Link accepting a list of lists of integers which yields a list of list of integers:  
`[[top-left, top-right], [bottom-left, bottom-right]]`
**[Try it online!](https://tio.run/##y0rNyan8///oJK@HO5oOLTfSeriz8fD0R407tI/NfdS461HTmkcNM/7//x9taKSjYKmjYGwaq6MQbQhkAPlGILaJjoKZjoKhRSwA "Jelly – Try It Online")**
### How?
```
ŒJḂ§2*ṁ×⁸+Ɲ⁺€‘ - Link: list of lists of integers, T    e.g. [[ 3, 9, 5],[ 1, 3, 2],[ 4, 6, 1]]
ŒJ             - multidimensional indices (T)               [[1,1],[1,2],[1,3],[2,1],[2,2],[2,3],[3,1],[3,2],[3,3]]
  Ḃ            - least significant bit (vectorises)         [[1,1],[1,0],[1,1],[0,1],[0,0],[0,1],[1,1],[1,0],[1,1]]
   §           - sums                                       [2,1,2,1,0,1,2,1,2]
    2          - literal two                                2
     *         - exponentiate                               [4,2,4,2,1,2,4,2,4]
      ṁ        - mould like (T)                             [[ 4, 2, 4],[ 2, 1, 2],[ 4, 2, 4]]
        ⁸      - chain's left argument, T                   [[ 3, 9, 5],[ 1, 3, 2],[ 4, 6, 1]]
       ×       - multiply (vectorises)                      [[12,18,20],[ 2, 3, 4],[16,12, 4]]
          Ɲ    - for neighbours:
         +     -   add (vectorises)                         [[14,21,24],[18,15, 8]]
            €  - for each:
           ⁺   -   repeat last link                         [[35,45],[33,23]]
               - (...i.e +Ɲ for each)
             ‘ - increment (vectorises)                     [[36,46],[34,24]]
```
[Answer]
# [Haskell](https://www.haskell.org/), ~~67~~ 66 bytes
```
f a b c d e f g h i=[2*v+e+1|v<-[2*a+b+d,b+2*c+f,d+2*g+h,f+h+2*i]]
```
[Try it online!](https://tio.run/##LYZBCoAgFAWv8pbVNyihXZ4kWmj6UyqJClfd3VzEMMx4fW9u33NmaBgssHBgrPAIapJNIkf9m8a2vCZDVhiSzUIsbOlKXjD5cmGe86FDhMJ5hfhUjAHdjyz26Or8AQ "Haskell – Try It Online")
Inspired by [my Python answer](https://codegolf.stackexchange.com/a/200937/75323).
[Answer]
# [brainfuck](https://github.com/TryItOnline/brainfuck), 138 bytes
```
,[->++++<],[->++>++<<],[->>++++<<],[->++>>++<<<],[->+>+>+>+<<<<],[->>++>>++<<<<],[->>>++++<<<],[->>>++>++<<<<],[->>>>++++<<<<]>+.>+.>+.>+.
```
[Try it online!](https://tio.run/##SypKzMxLK03O/v9fJ1rXThsIbGIhLCCygbAhwnBxsASUB4E2NgiVUGkoH6oVwUOVhUnbxNpp68HR//8A "brainfuck – Try It Online"), just for the byte count.
[Try it here](https://copy.sh/brainfuck/?c=LFstPisrKys8XSxbLT4rKz4rKzw8XSxbLT4-KysrKzw8XSxbLT4rKz4-Kys8PDxdLFstPis-Kz4rPis8PDw8XSxbLT4-Kys-PisrPDw8PF0sWy0-Pj4rKysrPDw8XSxbLT4-PisrPisrPDw8PF0sWy0-Pj4-KysrKzw8PDxdPisuPisuPisuPisu), by pasting this input: `\12\9\35\1\32\2\4\6\18` and hitting the "view memory" button to compare it with the expected output `101 195 063 121`.
[Answer]
# [Pyth](https://github.com/isaacg1/pyth), 24 bytes
```
mh+eQ+ys<.<ecPQ4d2yy@Qd4
```
[Try it online!](https://tio.run/##K6gsyfj/PzdDOzVQu7LYRs8mNTkg0CTFqLLSITDF5P//aEMjHWNTHUMLHRMdQx1LHSMdMx1jo1gA "Pyth – Try It Online")
I/O format: List `[0, 1, 2, 3, 4, 5, 6, 7, 8]` (input) and `[0, 1, 2, 3]` (output) with positions
```
Input: 0 5 1     Output: 0 1
 = Q   4 8 6             3 2
       3 7 2
```
### Explanation
```
m                      4   # map [0, 1, 2, 3] to (current number = d)
 h                         # 1 +
  +eQ                      # Q[-1] + 1 +
      ys                   #   2 * sum of
           ec  4           #     chop       into pieces of length 4, take last element
             PQ            #          Q[:-1]                 -> [4,5,6,7]
         .<     d          #     rotate left by d
        <        2         #     first two elements -> [4,5], [5,6], [6,7] or [7,4]
     +                     # +
                  yy       #   4 *
                    @Qd    #       Q[d]
```
[Answer]
# [PHP](https://php.net/), 101 bytes
A rather inelegant solution. Just multiples corners by 4, sides by 2 and adds 1 to the center than adds up each corner. Some form of matrix multiplication may be possible with `array_map()`.
```
parse_str($argv[1]);$e++;echo$a*4+$b*2+$d*2+$e,$c*4+$b*2+$f*2+$e,$g*4+$d*2+$h*2+$e,$i*4+$f*2+$h*2+$e;
```
[Try it online!](https://tio.run/##RclBDoMgEAXQy0wmVlxg24UGSQ/SNA3iAK4kYHp96qhpZ/F/5v0YYhkecctoUqZ3XlMFJvnPs31dFJAQimxYwNR3AWN9FTBxUAP2J@4Uz7LP4ZSZxf1FlVKM7rfDUd/Q6l7KFictkVg7dMfojwpcOO/PFw "PHP – Try It Online")
It takes input as a string in a html query format e.g. `a=9999&b=3&c=9001&d=0&e=9998&f=9999&g=9999&h=999&i=9999`
+7 bytes if the output can't be an unseparated list, by making it into an array and using `print_r()`
# [PHP](https://php.net/), 108 bytes
```
parse_str($argv[1]);$e++;print_r([$a*4+$b*2+$d*2+$e,$c*4+$b*2+$f*2+$e,$g*4+$d*2+$h*2+$e,$i*4+$f*2+$h*2+$e]);
```
[Try it online!](https://tio.run/##RcxNDoJADAXgyzQNMi4GdSHBiQchhgwwfxvTFOL1xykQ7eK99GtSipQfTypJlhc3LCtXYDl8@uZ16sAp1RGn9zpw1YOtbwrG@qJglnBnmH7iDwki2zkekkT8X8rfnLM1bRkczRUn02rd4Gw0OtE7@v0Y9opSmLblCw "PHP – Try It Online")
]