2021-06-15 00:49:18 -07:00
---
id: 5900f5111000cf542c510023
2022-03-04 19:46:29 +05:30
title: 'Problema 420: matrice intera 2x2 positiva'
2021-06-15 00:49:18 -07:00
challengeType: 5
forumTopicId: 302090
dashedName: problem-420-2x2-positive-integer-matrix
---
# --description--
2022-03-04 19:46:29 +05:30
Una matrice intera positiva è una matrice i cui elementi sono tutti interi positivi.
2021-06-15 00:49:18 -07:00
2022-03-04 19:46:29 +05:30
Alcune matrici intere positive possono essere espresse come un quadrato di una matrice intera positiva in due modi diversi. Ecco un esempio:
2021-06-15 00:49:18 -07:00
2022-03-31 22:31:59 +05:30
$$$\begin{pmatrix} 40 & 12 \\\\
48 & 40 \end{pmatrix}=
2022-03-04 19:46:29 +05:30
{\start{pmatrix}
2022-03-31 22:31:59 +05:30
2 & 3 \\\\
12 & 2 \end{pmatrix}}^2 =
2022-03-04 19:46:29 +05:30
{\start{pmatrix}
2022-03-31 22:31:59 +05:30
6 & 1 \\\\
4 & 6 \end{pmatrix}}^2$$
2021-06-15 00:49:18 -07:00
2022-03-04 19:46:29 +05:30
Definiamo $F(N)$ come il numero delle matrici intere positive 2x2 che hanno una traccia inferiore a N e che possono essere espresse come un quadrato di una matrice intera positiva in due modi diversi.
Possiamo verificare che $F(50) = 7$ e $F(1000) = 1019$.
Trova $F({10}^7)$.
2021-06-15 00:49:18 -07:00
# --hints--
2022-03-04 19:46:29 +05:30
`positiveIntegerMatrix()` dovrebbe restituire `145159332` .
2021-06-15 00:49:18 -07:00
```js
2022-03-04 19:46:29 +05:30
assert.strictEqual(positiveIntegerMatrix(), 145159332);
2021-06-15 00:49:18 -07:00
```
# --seed--
## --seed-contents--
```js
2022-03-04 19:46:29 +05:30
function positiveIntegerMatrix() {
2021-06-15 00:49:18 -07:00
return true;
}
2022-03-04 19:46:29 +05:30
positiveIntegerMatrix();
2021-06-15 00:49:18 -07:00
```
# --solutions--
```js
// solution required
```