Modular arithmetic
 
Betöltés...
Keresés...
Nincs egyezés
bme névtér-referencia

Osztályok

class  Mod
 

Függvények

int gcdx (int a, int b, int &x, int &y)
 Legnagyobb közös osztó kiszámolása és előállítása.
 
ostream & operator<< (ostream &os, const Mod &M)
 Mod osztály kiírása a képernyőre.
 
bool operator== (int x, const Mod &M)
 
bool operator!= (int x, const Mod &M)
 
Mod operator+ (int x, const Mod &M)
 
Mod operator- (int x, const Mod &M)
 
Mod operator* (int x, const Mod &M)
 
Mod operator/ (int x, const Mod &M)
 

Változók

const int INITIAL_DEFAULT_MODULUS = 2
 a default modulus kezdeti értéke
 
const int NORMAL_PRINT_MODE = 1
 
const int SHORT_PRINT_MODE = 2
 
const int INITIAL_PRINT_MODE = NORMAL_PRINT_MODE
 a print mode kezdeti értéke
 

Függvények dokumentációja

◆ gcdx()

int bme::gcdx ( int a,
int b,
int & x,
int & y )

Legnagyobb közös osztó kiszámolása és előállítása.

Visszaadja a és b legnagyobb közös osztóját (d), és ezt előállítja d=ax+by alakban, x és y értékét a paraméterként megadott referenciákban adja vissza.

Definíció a(z) gcdx.cpp fájl 7. sorában.

◆ operator!=()

bool bme::operator!= ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 275. sorában.

◆ operator*()

Mod bme::operator* ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 278. sorában.

◆ operator+()

Mod bme::operator+ ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 276. sorában.

◆ operator-()

Mod bme::operator- ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 277. sorában.

◆ operator/()

Mod bme::operator/ ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 279. sorában.

◆ operator<<()

ostream & bme::operator<< ( ostream & os,
const Mod & M )

Mod osztály kiírása a képernyőre.

Definíció a(z) mod.cpp fájl 61. sorában.

◆ operator==()

bool bme::operator== ( int x,
const Mod & M )
inline

Definíció a(z) mod.h fájl 274. sorában.

Változók dokumentációja

◆ INITIAL_DEFAULT_MODULUS

const int bme::INITIAL_DEFAULT_MODULUS = 2

a default modulus kezdeti értéke

Definíció a(z) mod.h fájl 13. sorában.

◆ INITIAL_PRINT_MODE

const int bme::INITIAL_PRINT_MODE = NORMAL_PRINT_MODE

a print mode kezdeti értéke

Definíció a(z) mod.h fájl 17. sorában.

◆ NORMAL_PRINT_MODE

const int bme::NORMAL_PRINT_MODE = 1

Definíció a(z) mod.h fájl 14. sorában.

◆ SHORT_PRINT_MODE

const int bme::SHORT_PRINT_MODE = 2

Definíció a(z) mod.h fájl 15. sorában.