Merge lp:~gang65/ubuntu-calculator-app/ubuntu-calculator-app-mathjs-2.4.2-upgrade into lp:ubuntu-calculator-app

Proposed by Bartosz Kosiorek
Status: Merged
Approved by: Riccardo Padovani
Approved revision: 241
Merged at revision: 240
Proposed branch: lp:~gang65/ubuntu-calculator-app/ubuntu-calculator-app-mathjs-2.4.2-upgrade
Merge into: lp:ubuntu-calculator-app
Prerequisite: lp:~gang65/ubuntu-calculator-app/ubuntu-calculator-app-long-complex-numbers-fix
Diff against target: 116 lines (+13/-13)
2 files modified
app/engine/math.js (+12/-13)
debian/changelog (+1/-0)
To merge this branch: bzr merge lp:~gang65/ubuntu-calculator-app/ubuntu-calculator-app-mathjs-2.4.2-upgrade
Reviewer Review Type Date Requested Status
Riccardo Padovani Approve
Jenkins Bot continuous-integration Approve
Review via email: mp+277509@code.launchpad.net

Commit message

Upgrade math.js to version 2.4.2 to fix complex numbers formatting

Description of the change

Upgrade math.js to version 2.4.2 to fix complex numbers formatting

To post a comment you must log in.
Revision history for this message
Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Riccardo Padovani (rpadovani) wrote :

lgtm, thanks

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'app/engine/math.js'
2--- app/engine/math.js 2015-10-30 20:02:49 +0000
3+++ app/engine/math.js 2015-11-15 00:20:00 +0000
4@@ -14,8 +14,8 @@
5 * It features real and complex numbers, units, matrices, a large set of
6 * mathematical functions, and a flexible expression parser.
7 *
8- * @version 2.4.1
9- * @date 2015-10-29
10+ * @version 2.4.2
11+ * @date 2015-11-14
12 *
13 * @license
14 * Copyright (C) 2013-2015 Jos de Jong <wjosdejong@gmail.com>
15@@ -113,7 +113,7 @@
16 math.create = create;
17
18 // import data types, functions, constants, expression parser, etc.
19- math.import(__webpack_require__(13));
20+ math['import'](__webpack_require__(13));
21
22 return math;
23 }
24@@ -2422,7 +2422,7 @@
25 }
26
27 if (c.length > precision) {
28- var removed = c.splice(precision);
29+ var removed = c.splice(precision, c.length - precision);
30
31 if (removed[0] >= 5) {
32 var i = precision - 1;
33@@ -9123,7 +9123,7 @@
34 this.units = [{
35 unit: matchingUnit.unit,
36 prefix: matchingUnit.prefix,
37- power: 1.0,
38+ power: 1.0
39 }];
40 }
41 else {
42@@ -9150,8 +9150,7 @@
43 }
44
45 this.isUnitListSimplified = true;
46- return;
47- }
48+ };
49
50 /**
51 * Get a string representation of the units of this Unit, without the value.
52@@ -10493,7 +10492,7 @@
53 base: BASE_UNITS.ELECTRIC_CHARGE,
54 prefixes: PREFIXES.LONG,
55 value: 1,
56- offset: 0,
57+ offset: 0
58 },
59 C: {
60 name: 'C',
61@@ -10939,7 +10938,7 @@
62 0: '0',
63 1: '\\left(${args[0]}\\right)',
64 2: '\\left(\\left(${args[0]}\\right)+'
65- + latex.symbols['i'] + '\\cdot\\left(${args[1]}\\right)\\right)',
66+ + latex.symbols['i'] + '\\cdot\\left(${args[1]}\\right)\\right)'
67 };
68
69 return complex;
70@@ -18689,7 +18688,7 @@
71 /* 79 */
72 /***/ function(module, exports) {
73
74- module.exports = '2.4.1';
75+ module.exports = '2.4.2';
76 // Note: This file is automatically generated when building math.js.
77 // Changes made in this file will be overwritten.
78
79@@ -19618,7 +19617,7 @@
80 'examples': [
81 'lup([[2, 1], [1, 4]])',
82 'lup(matrix([[2, 1], [1, 4]]))',
83- 'lup(sparse([[2, 1], [1, 4]]))',
84+ 'lup(sparse([[2, 1], [1, 4]]))'
85 ],
86 'seealso': [
87 'lusolve', 'lsolve', 'usolve', 'matrix', 'sparse', 'slu'
88@@ -19682,7 +19681,7 @@
89 'description':
90 'Solves the linear system U * x = b where U is an [n x n] upper triangular matrix and b is a [n] column vector.',
91 'examples': [
92- 'x=usolve(sparse([1, 1, 1, 1; 0, 1, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1]), [1; 2; 3; 4])',
93+ 'x=usolve(sparse([1, 1, 1, 1; 0, 1, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1]), [1; 2; 3; 4])'
94 ],
95 'seealso': [
96 'lup', 'lusolve', 'lsolve', 'matrix', 'sparse'
97@@ -25241,7 +25240,7 @@
98 'OperatorNode:pow': {
99 associativity: 'right',
100 associativeWith: [],
101- latexRightParens: false,
102+ latexRightParens: false
103 //the exponent doesn't need parentheses in
104 //LaTeX because it's 2 dimensional
105 //(it's on top)
106
107=== modified file 'debian/changelog'
108--- debian/changelog 2015-11-15 00:20:00 +0000
109+++ debian/changelog 2015-11-15 00:20:00 +0000
110@@ -2,6 +2,7 @@
111
112 [ Bartosz Kosiorek ]
113 * Fix evaluation of long complex numbers (LP: #1515600)
114+ * Upgrade math.js to version 2.4.2 to fix complex numbers formatting
115
116 -- Bartosz Kosiorek <gang65@poczta.onet.pl> Thu, 12 Nov 2015 13:28:29 +0100
117

Subscribers

People subscribed via source and target branches