# Fungrim entry: f20503

$d = a x + b y\; \text{ where } \left(d, u, v\right) = \operatorname{xgcd}\!\left(a, b\right),\;\left(x, y\right) = \left(u + \frac{k b}{d}, v - \frac{k a}{d}\right)$
Assumptions:$a \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; b \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; k \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; \left(a \ne 0 \;\mathbin{\operatorname{or}}\; b \ne 0\right)$
TeX:
d = a x + b y\; \text{ where } \left(d, u, v\right) = \operatorname{xgcd}\!\left(a, b\right),\;\left(x, y\right) = \left(u + \frac{k b}{d}, v - \frac{k a}{d}\right)

a \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; b \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; k \in \mathbb{Z} \;\mathbin{\operatorname{and}}\; \left(a \ne 0 \;\mathbin{\operatorname{or}}\; b \ne 0\right)
Definitions:
Fungrim symbol Notation Short description
XGCD$\operatorname{xgcd}\!\left(a, b\right)$ Extended greatest common divisor
ZZ$\mathbb{Z}$ Integers
Source code for this entry:
Entry(ID("f20503"),
Formula(Where(Equal(d, Add(Mul(a, x), Mul(b, y))), Equal(Tuple(d, u, v), XGCD(a, b)), Equal(Tuple(x, y), Tuple(Add(u, Div(Mul(k, b), d)), Sub(v, Div(Mul(k, a), d)))))),
Variables(a, b, k),
Assumptions(And(Element(a, ZZ), Element(b, ZZ), Element(k, ZZ), Or(NotEqual(a, 0), NotEqual(b, 0)))))

## Topics using this entry

Copyright (C) Fredrik Johansson and contributors. Fungrim is provided under the MIT license. The source code is on GitHub.

2021-03-15 19:12:00.328586 UTC