katarzynaadamczyk / Some_Egyptian_fractions

Given a rational number n, n >= 0, with denominator strictly positive, decompose this number as a sum of rationals with numerators equal to one and without repetitions.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Some Egyptian fractions

The program solves the following problem: Given a rational number n, n >= 0, with denominator strictly positive, decompose this number as a sum of rationals with numerators equal to one and without repetitions (2/3 = 1/2 + 1/6 is correct but not 2/3 = 1/3 + 1/3, 1/3 is repeated).

The project was written in C++, can be opened via VSC. It is divided in 3 tabs - one is main to run the project, and a class Decomp declared in Decomp.h and defined in Decomp.cpp. Class Decomp has only static functions to solve the problem described above.

To open the .exe file you need to just double-click on it.

About

Given a rational number n, n >= 0, with denominator strictly positive, decompose this number as a sum of rationals with numerators equal to one and without repetitions.


Languages

Language:C++ 100.0%