diff --git a/d4/d5d/math_2armstrong__number_8cpp.html b/d4/d5d/math_2armstrong__number_8cpp.html deleted file mode 100644 index 56353e7b8..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp.html +++ /dev/null @@ -1,295 +0,0 @@ - - - - - - - -Algorithms_in_C++: math/armstrong_number.cpp File Reference - - - - - - - - - - - - - - - -
-
- - - - - - -
-
Algorithms_in_C++ 1.0.0 -
-
Set of algorithms implemented in C++.
-
-
- - - - - - - -
-
- -
-
-
- -
- -
-
- - -
-
-
-
-
-
Loading...
-
Searching...
-
No Matches
-
-
-
-
- -
- -
armstrong_number.cpp File Reference
-
-
- -

Program to check if a number is an Armstrong/Narcissistic number in decimal system. -More...

-
#include <cassert>
-#include <cmath>
-#include <iostream>
-
-Include dependency graph for armstrong_number.cpp:
-
-
-
-
- - - - - - - - - -

-Functions

int number_of_digits (int num)
 
bool is_armstrong (int number)
 
void test ()
 
int main ()
 
-

Detailed Description

-

Program to check if a number is an Armstrong/Narcissistic number in decimal system.

-

Armstrong number or Narcissistic number is a number that is the sum of its own digits raised to the power of the number of digits.

Author
iamnambiar
-

Function Documentation

- -

◆ is_armstrong()

- -
-
- - - - - - - - -
bool is_armstrong (int number)
-
-

Function to check whether the number is armstrong number or not.

Parameters
- - -
numNumber
-
-
-
Returns
true if the number is armstrong.
-
-false if the number is not armstrong.
-
36 {
-
37 // If the number is less than 0, then it is not a armstrong number.
-
38 if (number < 0) {
-
39 return false;
-
40 }
-
41 int sum = 0;
-
42 int temp = number;
-
43 // Finding the total number of digits in the number
-
44 int total_digits = number_of_digits(number);
-
45 while (temp > 0) {
-
46 int rem = temp % 10;
-
47 // Finding each digit raised to the power total digit and add it to the
-
48 // total sum
-
49 sum = sum + std::pow(rem, total_digits);
-
50 temp = temp / 10;
-
51 }
-
52 return number == sum;
-
53}
-
int number_of_digits(int num)
Definition armstrong_number.cpp:21
-
T sum(const std::vector< std::valarray< T > > &A)
Definition vector_ops.hpp:232
-
T pow(T... args)
-
-Here is the call graph for this function:
-
-
-
- -
-
- -

◆ main()

- -
-
- - - - - - - - -
int main (void )
-
-

Main Function

-
77 {
-
78 test();
-
79 return 0;
-
80}
-
void test()
Definition armstrong_number.cpp:59
-
-Here is the call graph for this function:
-
-
-
- -
-
- -

◆ number_of_digits()

- -
-
- - - - - - - - -
int number_of_digits (int num)
-
-

Function to calculate the total number of digits in the number.

Parameters
- - -
numNumber
-
-
-
Returns
Total number of digits.
-
21 {
-
22 int total_digits = 0;
-
23 while (num > 0) {
-
24 num = num / 10;
-
25 ++total_digits;
-
26 }
-
27 return total_digits;
-
28}
-
-
-
- -

◆ test()

- -
-
- - - - - - - -
void test ()
-
-

Function for testing the is_armstrong() function with all the test cases.

-
59 {
-
60 // is_armstrong(370) returns true.
-
61 assert(is_armstrong(370) == true);
-
62 // is_armstrong(225) returns false.
-
63 assert(is_armstrong(225) == false);
-
64 // is_armstrong(-23) returns false.
-
65 assert(is_armstrong(-23) == false);
-
66 // is_armstrong(153) returns true.
-
67 assert(is_armstrong(153) == true);
-
68 // is_armstrong(0) returns true.
-
69 assert(is_armstrong(0) == true);
-
70 // is_armstrong(12) returns false.
-
71 assert(is_armstrong(12) == false);
-
72}
-
bool is_armstrong(int number)
Definition armstrong_number.cpp:36
-
-Here is the call graph for this function:
-
-
-
- -
-
-
-
- - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp.js b/d4/d5d/math_2armstrong__number_8cpp.js deleted file mode 100644 index b12e05158..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp.js +++ /dev/null @@ -1,7 +0,0 @@ -var math_2armstrong__number_8cpp = -[ - [ "is_armstrong", "d4/d5d/math_2armstrong__number_8cpp.html#a9cebd92bc70890c3cfa261d68a5016e7", null ], - [ "main", "d4/d5d/math_2armstrong__number_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4", null ], - [ "number_of_digits", "d4/d5d/math_2armstrong__number_8cpp.html#aab733299b170fa5a752503f95f090fcd", null ], - [ "test", "d4/d5d/math_2armstrong__number_8cpp.html#ae1a3968e7947464bee7714f6d43b7002", null ] -]; \ No newline at end of file diff --git a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.map b/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.map deleted file mode 100644 index 9b3c76688..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.map +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.md5 b/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.md5 deleted file mode 100644 index cb7f2a1b2..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.md5 +++ /dev/null @@ -1 +0,0 @@ -d737a5cfb01a3326b1a51e7bdabef31e \ No newline at end of file diff --git a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.svg b/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.svg deleted file mode 100644 index 2a5f2afe1..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph.svg +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - - - - - -is_armstrong - - -Node1 - - -is_armstrong - - - - - -Node2 - - -number_of_digits - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -std::pow - - - - - -Node1->Node3 - - - - - - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph_org.svg b/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph_org.svg deleted file mode 100644 index ef6a84426..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_a9cebd92bc70890c3cfa261d68a5016e7_cgraph_org.svg +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - -is_armstrong - - -Node1 - - -is_armstrong - - - - - -Node2 - - -number_of_digits - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -std::pow - - - - - -Node1->Node3 - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.map b/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.map deleted file mode 100644 index 7728416b5..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.map +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.md5 b/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.md5 deleted file mode 100644 index 2c02120e7..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.md5 +++ /dev/null @@ -1 +0,0 @@ -4ed4e36355984677ea9ead13adaabf9d \ No newline at end of file diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.svg b/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.svg deleted file mode 100644 index 75e1363fd..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph.svg +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - - - - - -test - - -Node1 - - -test - - - - - -Node2 - - -is_armstrong - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -number_of_digits - - - - - -Node2->Node3 - - - - - - - - -Node4 - - -std::pow - - - - - -Node2->Node4 - - - - - - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph_org.svg b/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph_org.svg deleted file mode 100644 index 412c9dc46..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae1a3968e7947464bee7714f6d43b7002_cgraph_org.svg +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - -test - - -Node1 - - -test - - - - - -Node2 - - -is_armstrong - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -number_of_digits - - - - - -Node2->Node3 - - - - - - - - -Node4 - - -std::pow - - - - - -Node2->Node4 - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map b/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map deleted file mode 100644 index 4315565e8..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 b/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 deleted file mode 100644 index a352ea07d..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 +++ /dev/null @@ -1 +0,0 @@ -9950fe690b2d5fcc7036c238426e3034 \ No newline at end of file diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg b/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg deleted file mode 100644 index 4e00f4984..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - - - - - -main - - -Node1 - - -main - - - - - -Node2 - - -test - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -is_armstrong - - - - - -Node2->Node3 - - - - - - - - -Node4 - - -number_of_digits - - - - - -Node3->Node4 - - - - - - - - -Node5 - - -std::pow - - - - - -Node3->Node5 - - - - - - - - - - - - - diff --git a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg b/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg deleted file mode 100644 index 753a00d4c..000000000 --- a/d4/d5d/math_2armstrong__number_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - -main - - -Node1 - - -main - - - - - -Node2 - - -test - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -is_armstrong - - - - - -Node2->Node3 - - - - - - - - -Node4 - - -number_of_digits - - - - - -Node3->Node4 - - - - - - - - -Node5 - - -std::pow - - - - - -Node3->Node5 - - - - - - - - diff --git a/d6/d74/math_2armstrong__number_8cpp__incl.map b/d6/d74/math_2armstrong__number_8cpp__incl.map deleted file mode 100644 index 3d5126b42..000000000 --- a/d6/d74/math_2armstrong__number_8cpp__incl.map +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/d6/d74/math_2armstrong__number_8cpp__incl.md5 b/d6/d74/math_2armstrong__number_8cpp__incl.md5 deleted file mode 100644 index 9a1bc9505..000000000 --- a/d6/d74/math_2armstrong__number_8cpp__incl.md5 +++ /dev/null @@ -1 +0,0 @@ -319447288d71f5b96364e1874c58a09f \ No newline at end of file diff --git a/d6/d74/math_2armstrong__number_8cpp__incl.svg b/d6/d74/math_2armstrong__number_8cpp__incl.svg deleted file mode 100644 index b0f891fb6..000000000 --- a/d6/d74/math_2armstrong__number_8cpp__incl.svg +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - - - - - -math/armstrong_number.cpp - - -Node1 - - -math/armstrong_number.cpp - - - - - -Node2 - - -cassert - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -cmath - - - - - -Node1->Node3 - - - - - - - - -Node4 - - -iostream - - - - - -Node1->Node4 - - - - - - - - - - - - - diff --git a/d6/d74/math_2armstrong__number_8cpp__incl_org.svg b/d6/d74/math_2armstrong__number_8cpp__incl_org.svg deleted file mode 100644 index 4d1e3b63a..000000000 --- a/d6/d74/math_2armstrong__number_8cpp__incl_org.svg +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - -math/armstrong_number.cpp - - -Node1 - - -math/armstrong_number.cpp - - - - - -Node2 - - -cassert - - - - - -Node1->Node2 - - - - - - - - -Node3 - - -cmath - - - - - -Node1->Node3 - - - - - - - - -Node4 - - -iostream - - - - - -Node1->Node4 - - - - - - - - diff --git a/dd/d47/namespacemath.html b/dd/d47/namespacemath.html index 8487a0dfe..4c646a16e 100644 --- a/dd/d47/namespacemath.html +++ b/dd/d47/namespacemath.html @@ -115,6 +115,7 @@ Classes

Functions

uint64_t aliquot_sum (const uint64_t num) + to return the aliquot sum of a number
  double approximate_pi (const std::vector< Point > &pts)   @@ -313,27 +314,29 @@ Algorithm
-

Function to return the aliquot sum of a number

Parameters
+ +

to return the aliquot sum of a number

+
Parameters
numThe input number
-
26 {
-
27 if (num == 0 || num == 1) {
-
28 return 0; // The aliquot sum for 0 and 1 is 0
-
29 }
-
30
-
31 uint64_t sum = 0;
-
32
-
33 for (uint64_t i = 1; i <= num / 2; i++) {
-
34 if (num % i == 0) {
-
35 sum += i;
-
36 }
-
37 }
-
38
-
39 return sum;
-
40}
+
35 {
+
36 if (num == 0 || num == 1) {
+
37 return 0; // The aliquot sum for 0 and 1 is 0
+
38 }
+
39
+
40 uint64_t sum = 0;
+
41
+
42 for (uint64_t i = 1; i <= num / 2; i++) {
+
43 if (num % i == 0) {
+
44 sum += i;
+
45 }
+
46 }
+
47
+
48 return sum;
+
49}
T sum(const std::vector< std::valarray< T > > &A)
Definition vector_ops.hpp:232
diff --git a/de/d99/aliquot__sum_8cpp.html b/de/d99/aliquot__sum_8cpp.html index fc8547f00..8cb489267 100644 --- a/de/d99/aliquot__sum_8cpp.html +++ b/de/d99/aliquot__sum_8cpp.html @@ -123,6 +123,7 @@ Namespaces

Functions

uint64_t math::aliquot_sum (const uint64_t num) + to return the aliquot sum of a number
  static void test ()  Self-test implementations.
@@ -133,7 +134,14 @@ Functions

Detailed Description

Program to return the Aliquot Sum of a number.

-

The Aliquot sum s(n) of a non-negative integer n is the sum of all proper divisors of n, that is, all the divisors of n, other than itself. For example, the Aliquot sum of 18 = 1 + 2 + 3 + 6 + 9 = 21

+

The Aliquot sum \(s(n)\) of a non-negative integer n is the sum of all proper divisors of n, that is, all the divisors of n, other than itself.

+

Formula:

+

+\[ + s(n) = \sum_{d|n, d\neq n}d. +\] +

+

For example; \(s(18) = 1 + 2 + 3 + 6 + 9 = 21 \)

Author
SpiderMath

Function Documentation

@@ -154,12 +162,11 @@ Functions

Main function.

Returns
0 on exit
-
64 {
-
65 test(); // run the self-test implementations
-
66
-
67 return 0;
-
68}
-
static void test()
Self-test implementations.
Definition aliquot_sum.cpp:47
+
73 {
+
74 test(); // run the self-test implementations
+
75 return 0;
+
76}
+
static void test()
Self-test implementations.
Definition aliquot_sum.cpp:56
Here is the call graph for this function:
@@ -193,20 +200,20 @@ Here is the call graph for this function:

Self-test implementations.

Returns
void
-
47 {
-
48 // Aliquot sum of 10 is 1 + 2 + 5 = 8
-
49 assert(math::aliquot_sum(10) == 8);
-
50 // Aliquot sum of 15 is 1 + 3 + 5 = 9
-
51 assert(math::aliquot_sum(15) == 9);
-
52 // Aliquot sum of 1 is 0
-
53 assert(math::aliquot_sum(1) == 0);
-
54 // Aliquot sum of 97 is 1 (the aliquot sum of a prime number is 1)
-
55 assert(math::aliquot_sum(97) == 1);
-
56
-
57 std::cout << "All the tests have successfully passed!\n";
-
58}
+
56 {
+
57 // Aliquot sum of 10 is 1 + 2 + 5 = 8
+
58 assert(math::aliquot_sum(10) == 8);
+
59 // Aliquot sum of 15 is 1 + 3 + 5 = 9
+
60 assert(math::aliquot_sum(15) == 9);
+
61 // Aliquot sum of 1 is 0
+
62 assert(math::aliquot_sum(1) == 0);
+
63 // Aliquot sum of 97 is 1 (the aliquot sum of a prime number is 1)
+
64 assert(math::aliquot_sum(97) == 1);
+
65
+
66 std::cout << "All the tests have successfully passed!\n";
+
67}
-
uint64_t aliquot_sum(const uint64_t num)
Definition aliquot_sum.cpp:26
+
uint64_t aliquot_sum(const uint64_t num)
to return the aliquot sum of a number
Definition aliquot_sum.cpp:35
Here is the call graph for this function:
diff --git a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.map b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.map index 537aed97f..550a57a3f 100644 --- a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.map +++ b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.map @@ -1,5 +1,5 @@ - + diff --git a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.md5 b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.md5 index 01332e564..019b91ea9 100644 --- a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.md5 +++ b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.md5 @@ -1 +1 @@ -7b52f3da1e2814fcecc5b4a2cedd4b9e \ No newline at end of file +9de40daebfdd73839fe6de7dbc3cefb9 \ No newline at end of file diff --git a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.svg b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.svg index 4ba090b19..1a2329bd1 100644 --- a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.svg +++ b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph.svg @@ -30,7 +30,7 @@ Node2 - + math::aliquot_sum diff --git a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph_org.svg b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph_org.svg index 8b775f8d6..3665cefef 100644 --- a/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph_org.svg +++ b/de/d99/aliquot__sum_8cpp_aa8dca7b867074164d5f45b0f3851269d_cgraph_org.svg @@ -20,7 +20,7 @@ Node2 - + math::aliquot_sum diff --git a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map index 59db9cf31..dd2c22aaf 100644 --- a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map +++ b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.map @@ -2,6 +2,6 @@ - + diff --git a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 index 549a4f14f..882449eb0 100644 --- a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 +++ b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.md5 @@ -1 +1 @@ -0686e8357f8d0a058a9287ddd2816a9f \ No newline at end of file +84b115a7d95db54c6e35b8265ffa00ab \ No newline at end of file diff --git a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg index 9924cc3ff..0b8b8e8ce 100644 --- a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg +++ b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg @@ -48,7 +48,7 @@ Node3 - + math::aliquot_sum diff --git a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg index 99fa788a5..a581445fc 100644 --- a/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg +++ b/de/d99/aliquot__sum_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg @@ -38,7 +38,7 @@ Node3 - + math::aliquot_sum diff --git a/dir_296d53ceaeaa7e099814a6def439fe8a.html b/dir_296d53ceaeaa7e099814a6def439fe8a.html index dffca13a9..f0ca228cc 100644 --- a/dir_296d53ceaeaa7e099814a6def439fe8a.html +++ b/dir_296d53ceaeaa7e099814a6def439fe8a.html @@ -112,9 +112,6 @@ Files  area.cpp  Implementations for the area of various shapes.
  - armstrong_number.cpp - Program to check if a number is an Armstrong/Narcissistic number in decimal system.
 binary_exponent.cpp  C++ Program to find Binary Exponent Iteratively and Recursively.
  diff --git a/dir_296d53ceaeaa7e099814a6def439fe8a.js b/dir_296d53ceaeaa7e099814a6def439fe8a.js index 39b87d61e..8b0631b66 100644 --- a/dir_296d53ceaeaa7e099814a6def439fe8a.js +++ b/dir_296d53ceaeaa7e099814a6def439fe8a.js @@ -3,7 +3,6 @@ var dir_296d53ceaeaa7e099814a6def439fe8a = [ "aliquot_sum.cpp", "de/d99/aliquot__sum_8cpp.html", "de/d99/aliquot__sum_8cpp" ], [ "approximate_pi.cpp", "d0/d51/approximate__pi_8cpp.html", "d0/d51/approximate__pi_8cpp" ], [ "area.cpp", "dc/d82/area_8cpp.html", "dc/d82/area_8cpp" ], - [ "armstrong_number.cpp", "d4/d5d/math_2armstrong__number_8cpp.html", "d4/d5d/math_2armstrong__number_8cpp" ], [ "binary_exponent.cpp", "de/dcf/binary__exponent_8cpp.html", "de/dcf/binary__exponent_8cpp" ], [ "binomial_calculate.cpp", "d8/db1/binomial__calculate_8cpp.html", "d8/db1/binomial__calculate_8cpp" ], [ "check_amicable_pair.cpp", "d5/df6/check__amicable__pair_8cpp.html", "d5/df6/check__amicable__pair_8cpp" ], diff --git a/files.html b/files.html index ebd9ece99..94d6edd45 100644 --- a/files.html +++ b/files.html @@ -226,64 +226,63 @@ solve-a-rat-in-a-maze-c-java-pytho/" target="_blank">Rat in a Maze algorithm  aliquot_sum.cppProgram to return the Aliquot Sum of a number  approximate_pi.cppImplementation to calculate an estimate of the number Ï€ (Pi)  area.cppImplementations for the area of various shapes - armstrong_number.cppProgram to check if a number is an Armstrong/Narcissistic number in decimal system - binary_exponent.cppC++ Program to find Binary Exponent Iteratively and Recursively - binomial_calculate.cppProgram to calculate Binomial coefficients - check_amicable_pair.cppA C++ Program to check whether a pair of number is amicable pair or not - check_factorial.cppA simple program to check if the given number is a factorial of some number or not - check_prime.cppA simple program to check if the given number is Prime or not - complex_numbers.cppAn implementation of Complex Number as Objects - double_factorial.cppCompute double factorial: \(n!!\) - eratosthenes.cppThe Sieve of Eratosthenes - eulers_totient_function.cppImplementation of Euler's Totient @description Euler Totient Function is also known as phi function - extended_euclid_algorithm.cppGCD using [extended Euclid's algorithm] (https://en.wikipedia.org/wiki/Extended_Euclidean_algorithm) - factorial.cppC++ program to find factorial of given number - fast_power.cppFaster computation for \(a^b\) - fibonacci.cppGenerate fibonacci sequence - fibonacci_fast.cppFaster computation of Fibonacci series - fibonacci_large.cppComputes N^th Fibonacci number given as input argument. Uses custom build arbitrary integers library to perform additions and other operations - fibonacci_matrix_exponentiation.cppThis program computes the N^th Fibonacci number in modulo mod input argument - fibonacci_sum.cppAn algorithm to calculate the sum of Fibonacci Sequence: \(\mathrm{F}(n) + + binary_exponent.cppC++ Program to find Binary Exponent Iteratively and Recursively + binomial_calculate.cppProgram to calculate Binomial coefficients + check_amicable_pair.cppA C++ Program to check whether a pair of number is amicable pair or not + check_factorial.cppA simple program to check if the given number is a factorial of some number or not + check_prime.cppA simple program to check if the given number is Prime or not + complex_numbers.cppAn implementation of Complex Number as Objects + double_factorial.cppCompute double factorial: \(n!!\) + eratosthenes.cppThe Sieve of Eratosthenes + eulers_totient_function.cppImplementation of Euler's Totient @description Euler Totient Function is also known as phi function + extended_euclid_algorithm.cppGCD using [extended Euclid's algorithm] (https://en.wikipedia.org/wiki/Extended_Euclidean_algorithm) + factorial.cppC++ program to find factorial of given number + fast_power.cppFaster computation for \(a^b\) + fibonacci.cppGenerate fibonacci sequence + fibonacci_fast.cppFaster computation of Fibonacci series + fibonacci_large.cppComputes N^th Fibonacci number given as input argument. Uses custom build arbitrary integers library to perform additions and other operations + fibonacci_matrix_exponentiation.cppThis program computes the N^th Fibonacci number in modulo mod input argument + fibonacci_sum.cppAn algorithm to calculate the sum of Fibonacci Sequence: \(\mathrm{F}(n) + \mathrm{F}(n+1) + .. + \mathrm{F}(m)\) - finding_number_of_digits_in_a_number.cpp[Program to count digits in an integer](https://www.geeksforgeeks.org/program-count-digits-integer-3-different-methods) - gcd_iterative_euclidean.cppCompute the greatest common denominator of two integers using iterative form of Euclidean algorithm - gcd_of_n_numbers.cppThis program aims at calculating the GCD of n numbers by division method - gcd_recursive_euclidean.cppCompute the greatest common denominator of two integers using recursive form of Euclidean algorithm - integral_approximation.cppCompute integral approximation of the function using Riemann sum - integral_approximation2.cppMonte Carlo Integration - inv_sqrt.cppImplementation of the inverse square root Root - large_factorial.cppCompute factorial of any arbitratily large number/ - large_number.hLibrary to perform arithmatic operations on arbitrarily large numbers - largest_power.cppAlgorithm to find largest x such that p^x divides n! (factorial) using Legendre's Formula - lcm_sum.cppAn algorithm to calculate the sum of LCM: \(\mathrm{LCM}(1,n) + + finding_number_of_digits_in_a_number.cpp[Program to count digits in an integer](https://www.geeksforgeeks.org/program-count-digits-integer-3-different-methods) + gcd_iterative_euclidean.cppCompute the greatest common denominator of two integers using iterative form of Euclidean algorithm + gcd_of_n_numbers.cppThis program aims at calculating the GCD of n numbers by division method + gcd_recursive_euclidean.cppCompute the greatest common denominator of two integers using recursive form of Euclidean algorithm + integral_approximation.cppCompute integral approximation of the function using Riemann sum + integral_approximation2.cppMonte Carlo Integration + inv_sqrt.cppImplementation of the inverse square root Root + large_factorial.cppCompute factorial of any arbitratily large number/ + large_number.hLibrary to perform arithmatic operations on arbitrarily large numbers + largest_power.cppAlgorithm to find largest x such that p^x divides n! (factorial) using Legendre's Formula + lcm_sum.cppAn algorithm to calculate the sum of LCM: \(\mathrm{LCM}(1,n) + \mathrm{LCM}(2,n) + \ldots + \mathrm{LCM}(n,n)\) - least_common_multiple.cpp - magic_number.cppA simple program to check if the given number is a magic number or not. A number is said to be a magic number, if the sum of its digits are calculated till a single digit recursively by adding the sum of the digits after every addition. If the single digit comes out to be 1,then the number is a magic number - miller_rabin.cpp - modular_division.cppAn algorithm to divide two numbers under modulo p Modular Division - modular_exponentiation.cppC++ Program for Modular Exponentiation Iteratively - modular_inverse_fermat_little_theorem.cppC++ Program to find the modular inverse using Fermat's Little Theorem - modular_inverse_simple.cppSimple implementation of modular multiplicative inverse - n_bonacci.cppImplementation of the N-bonacci series - n_choose_r.cppCombinations n choose r function implementation - ncr_modulo_p.cppThis program aims at calculating nCr modulo p - number_of_positive_divisors.cppC++ Program to calculate the number of positive divisors - perimeter.cppImplementations for the perimeter of various shapes - power_for_huge_numbers.cppCompute powers of large numbers - power_of_two.cppImplementation to check whether a number is a power of 2 or not - prime_factorization.cppPrime factorization of positive integers - prime_numbers.cppGet list of prime numbers - primes_up_to_billion.cppCompute prime numbers upto 1 billion - quadratic_equations_complex_numbers.cppCalculate quadratic equation with complex roots, i.e. b^2 - 4ac < 0 - realtime_stats.cppCompute statistics for data entered in rreal-time - sieve_of_eratosthenes.cppGet list of prime numbers using Sieve of Eratosthenes - sqrt_double.cppCalculate the square root of any positive real number in \(O(\log + least_common_multiple.cpp + magic_number.cppA simple program to check if the given number is a magic number or not. A number is said to be a magic number, if the sum of its digits are calculated till a single digit recursively by adding the sum of the digits after every addition. If the single digit comes out to be 1,then the number is a magic number + miller_rabin.cpp + modular_division.cppAn algorithm to divide two numbers under modulo p Modular Division + modular_exponentiation.cppC++ Program for Modular Exponentiation Iteratively + modular_inverse_fermat_little_theorem.cppC++ Program to find the modular inverse using Fermat's Little Theorem + modular_inverse_simple.cppSimple implementation of modular multiplicative inverse + n_bonacci.cppImplementation of the N-bonacci series + n_choose_r.cppCombinations n choose r function implementation + ncr_modulo_p.cppThis program aims at calculating nCr modulo p + number_of_positive_divisors.cppC++ Program to calculate the number of positive divisors + perimeter.cppImplementations for the perimeter of various shapes + power_for_huge_numbers.cppCompute powers of large numbers + power_of_two.cppImplementation to check whether a number is a power of 2 or not + prime_factorization.cppPrime factorization of positive integers + prime_numbers.cppGet list of prime numbers + primes_up_to_billion.cppCompute prime numbers upto 1 billion + quadratic_equations_complex_numbers.cppCalculate quadratic equation with complex roots, i.e. b^2 - 4ac < 0 + realtime_stats.cppCompute statistics for data entered in rreal-time + sieve_of_eratosthenes.cppGet list of prime numbers using Sieve of Eratosthenes + sqrt_double.cppCalculate the square root of any positive real number in \(O(\log N)\) time, with precision fixed using bisection method of root-finding - string_fibonacci.cppThis Programme returns the Nth fibonacci as a string - sum_of_binomial_coefficient.cppAlgorithm to find sum of binomial coefficients of a given positive integer - sum_of_digits.cppA C++ Program to find the Sum of Digits of input integer - vector_cross_product.cppCalculates the Cross Product and the magnitude of two mathematical 3D vectors - volume.cppImplmentations for the volume of various 3D shapes + string_fibonacci.cppThis Programme returns the Nth fibonacci as a string + sum_of_binomial_coefficient.cppAlgorithm to find sum of binomial coefficients of a given positive integer + sum_of_digits.cppA C++ Program to find the Sum of Digits of input integer + vector_cross_product.cppCalculates the Cross Product and the magnitude of two mathematical 3D vectors + volume.cppImplmentations for the volume of various 3D shapes   numerical_methods  babylonian_method.cppA babylonian method (BM) is an algorithm that computes the square root  bisection_method.cppSolve the equation \(f(x)=0\) using bisection method diff --git a/globals_func_i.html b/globals_func_i.html index 02675e290..7ea75fe1e 100644 --- a/globals_func_i.html +++ b/globals_func_i.html @@ -106,11 +106,10 @@ $(document).ready(function(){initNavTree('globals_func_i.html',''); initResizabl
  • insertAtTheBeginning() : linkedlist_implentation_usingarray.cpp
  • interactive() : md5.cpp, sha1.cpp
  • InterpolationSearch() : interpolation_search2.cpp
  • -
  • is_armstrong() : armstrong_number.cpp
  • is_happy() : happy_number.cpp
  • is_square() : ordinary_least_squares_regressor.cpp
  • -
  • isPrime() : modular_inverse_fermat_little_theorem.cpp
  • IsPrime() : primality_test.cpp
  • +
  • isPrime() : modular_inverse_fermat_little_theorem.cpp
  • it_ternary_search() : ternary_search.cpp
  • diff --git a/globals_func_m.html b/globals_func_m.html index 20f880c1c..c11581063 100644 --- a/globals_func_m.html +++ b/globals_func_m.html @@ -100,7 +100,7 @@ $(document).ready(function(){initNavTree('globals_func_m.html',''); initResizabl
    Here is a list of all documented functions with links to the documentation:

    - m -

    diff --git a/globals_func_t.html b/globals_func_t.html index 6d8bbc3e9..32256652c 100644 --- a/globals_func_t.html +++ b/globals_func_t.html @@ -101,7 +101,7 @@ $(document).ready(function(){initNavTree('globals_func_t.html',''); initResizabl

    - t -

    diff --git a/globals_m.html b/globals_m.html index b9a389978..16080352c 100644 --- a/globals_m.html +++ b/globals_m.html @@ -100,7 +100,7 @@ $(document).ready(function(){initNavTree('globals_m.html',''); initResizable();
    Here is a list of all documented file members with links to the documentation:

    - m -

    diff --git a/globals_t.html b/globals_t.html index efcf8dba2..cb3192c15 100644 --- a/globals_t.html +++ b/globals_t.html @@ -101,7 +101,7 @@ $(document).ready(function(){initNavTree('globals_t.html',''); initResizable();

    - t -