-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from Virnkord/math
5.7 Math functions ln() and log()
- Loading branch information
Showing
7 changed files
with
86 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
tests: | ||
- desc: '5.7 Math' | ||
- desc: '5.7.5 ln() : Decimal' | ||
- desc: '** Can take the natural logarithm of the number' | ||
expression: Math.n1.ln() | ||
result: [0] | ||
- desc: '** Empty result when taking logarithm from empty collection' | ||
expression: Math.n2.ln() | ||
result: [] | ||
- desc: '** Error taking logarithm due to too many input parameters' | ||
expression: Math.n3.ln(n4) | ||
error: true | ||
- desc: '** Error taking logarithm if the input collection contains multiple items' | ||
expression: Math.arr.ln() | ||
error: true | ||
|
||
- desc: '5.7.6 log(base : Decimal) : Decimal' | ||
- desc: '** Can take the logarithm of the number with a given base' | ||
expression: Math.n4.log(2) | ||
result: [3] | ||
- desc: '** Empty result when taking logarithm from empty collection' | ||
expression: Math.n2.log(8) | ||
result: [] | ||
- desc: '** Empty result when taking logarithm with empty base' | ||
expression: Math.n3.log(n2) | ||
result: [] | ||
- desc: '** Error taking logarithm if the input collection contains multiple items' | ||
expression: Math.arr.log(8) | ||
error: true | ||
- desc: '** Error taking logarithm due to too many input parameters' | ||
expression: Math.n3.log([3, 5]) | ||
error: true | ||
|
||
subject: | ||
resourceType: Math | ||
n1: 1 | ||
n2: [] | ||
n3: 2 | ||
n4: 8 | ||
arr: [3, 5] | ||
t: true |
File renamed without changes.
File renamed without changes.