Questions in category: Bug (Bug)
软件 >> Calculator >> Bug
<[1] [2] [3] [4] >

21. 为算廿四函数 eq24() 添加别名

Posted by haifeng on 2023-03-16 08:44:40 last update 2023-08-29 16:00:16 | Answers (0) | 收藏


v0.574 中为 eq24() 添加别名 s24() 和 suo(). 并且增加了功能, 可以添加第五个参数.

eq24(1,3,5,7) 等价于 eq24(1,3,5,7;24)

在 cmd 终端交互式输入下,  

>> eq24(1,3,5,7)
in> eq24(1,3,5,7)

(1+5)*(7-3)==24
(5+7)*(3-1)==24

------------------------

Total: 2

 

>> eq24(2,3,5,7)

 

3*5+2+7==24
3*7-2+5==24
7*(5-2)+3==24
3*7+5-2==24
3-7*(2-5)==24

 

22. [BUG]

Posted by haifeng on 2023-02-24 19:42:52 last update 2023-02-24 19:42:52 | Answers (0) | 收藏


>> -5*(-1)/6+1/4
in> -5*(-1)/6+1/4

out> 13|12

------------------------


>> -5*(-1)|(6)+1/4
in> -5*(-1)|(6)+1/4

out> 21|4

------------------------

23. [BUG]

Posted by haifeng on 2023-02-24 13:18:00 last update 2023-02-24 13:26:14 | Answers (0) | 收藏


in> printRecursiveSeries(1/n-5*I_n,I_n,0.18232156,10,\n)
0.18232156
0.08839220
1/-5*0.08839220
1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*0.08839220
1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*1/-5*0.08839220


------------------------

 

>> printRecursiveSeries(I_{n+1}==-5*I_n+1/n,I_0=0.18232156, 20, \n)
in> printRecursiveSeries(I_{n+1}~0-5*I_n+1/n,I_0=0.18232156,20,\n)
0.18232156
Inf-0.91160780
-5*I1f+0.08839220
0-5*-5*I1f+0.08839220+1/2
0-5*0-5*-5*I1f+0.08839220+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0-5*0-5*0-5*0-5*-5*I1f+0.08839220+1/2+1/3+1/4+1/5+1/6+1/7+1/8+1/9+1/10+1/11+1/12+1/13+1/14+1/15+1/16
0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*-5*I1f+0.08839220+1/2+1/3+1/4+1/5+1/6+1/7+1/8+1/9+1/10+1/11+1/12+1/13+1/14+1/15+1/16+1/17
0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*0-5*-5*I1f+0.08839220+1/2+1/3+1/4+1/5+1/6+1/7+1/8+1/9+1/10+1/11+1/12+1/13+1/14+1/15+1/16+1/17+1/18


------------------------

24. [Bug] 方阵行列式计算中的问题

Posted by haifeng on 2023-02-15 23:03:17 last update 2023-02-15 23:03:17 | Answers (0) | 收藏


>> n=3
--------------------

>> A=[1^n 2^n;
A=[1^n 2^n;
3^n 4^n]
input> [1^n,2^n;3^n,4^n]
det(A)=(4*^n+0-6*^n*^n)
----------------------------
 type: matrix
 name: A
value:
1^n     2^n
3^n     4^n

determinant: (4*^n+0-6*^n*^n)
--------------------

25. [Bug] 多项式乘法中的错误

Posted by haifeng on 2023-02-10 07:56:28 last update 2024-03-31 10:50:49 | Answers (0) | 收藏


>> :mode=polyn
Switch into polynomial mode.

 

>> 51*(302+8x)+24*(-604-17x)
in> 51*(302+8x)+24*(-604-17x)

out> -14088*x^1 is NOT a polynomial of x

 

>> 51*(8x+302)+24*(-17x-604)
in> 51*(8x+302)+24*(-17x-604)

out> 906

------------------------

 

>> 8x+302-17x-604
in> 8x+302-17x-604

out> 8x+302-17x-604

------------------------


>> 1*(8x+302-17x-604)
in> 1*(8x+302-17x-604)

out> 293x^1-604

------------------------


已经修复.  

Date: 2023-02-11


v0.576

Date: 2023-10-08

>> :mode polyn
Switch into polynomial mode.

>>  51*(302+8x)+24*(-604-17x)
in> 51*(302+8x)+24*(-604-17x)

out> 0|1x^1+906|1
------------------------


还是有问题

>> :mode polyn
Switch into polynomial mode.

>> -1*(8x+302-17x-604)
in> -1*(8x+302-17x-604)

out> -9x^1-302
------------------------


>> -8x
in> -8x

out>

已经在 ver0.592中解决

>> :mode polyn
Switch into polynomial mode.

>> -8x
in> -8x

out> -8x^1
------------------------


>> -1*(x-2)
in> -1*(x-2)

out> -1x^1+2
------------------------


>> -1*(8x+302-17x-604)
in> -1*(8x+302-17x-604)

out> 9x^1+302
------------------------

26. [Bug]

Posted by haifeng on 2023-02-05 21:32:42 last update 2023-02-05 21:34:15 | Answers (0) | 收藏


>> printRecursiveSeries((x+1)x(x+2),x,1,10,\n)
in> printRecursiveSeries((x+1)x(x+2),x,1,10,\n)
1
3
5
7
9
11
13
15
17
19

 

不同于下面的 (x+1)*x*(x+2)
------------------------

>> printRecursiveSeries((x+1)*x*(x+2),x,1,10,\n)
in> printRecursiveSeries((x+1)*x*(x+2),x,1,10,\n)
1
6
336
38272416
56060590716839257663296
176186654453940966415101758343368831005891099500239113100063334235776
5469139827058218798101218465260906817770532009979290887174189373402102848480157704494601835787106557175334209323000899768994221877279015724289748216104673490320217281562508981513548171796332733064696806656


 

>> printRecursiveSeries(x(x+1)(x+2),x,1,10,\n)
in> printRecursiveSeries(x(x+1)*(x+2),x,1,10,\n)
1
6
56
3306
10939556
119673918295806
14321846720271609085072077056

 

27. [Bug] 分数模式下的运算Bug

Posted by haifeng on 2023-01-30 13:54:48 last update 2023-01-30 13:54:48 | Answers (0) | 收藏


>> 25^(-2)+35^(-2)+75^(-2)+100^(-2)+175^(-2)
in> 25^(-2)+35^(-2)+75^(-2)+100^(-2)+175^(-2)

out> (175*100*75*35*^2*^2*^2*^2+175*100*75*25*^2*^2*^2*^2+175*100*875*^2*^2*^2*^2+175*75*875*^2*^2*^2*^2+100*75*875*^2*^2*^2*^2)|175*100*75*875*^2*^2*^2*^2*^2

------------------------

28. [Bug] 多项式计算时遇到的问题

Posted by haifeng on 2023-01-27 09:49:59 last update 2023-01-27 12:39:20 | Answers (0) | 收藏


>> :mode=polyn
Switch into polynomial mode.

>> (x^4+3x^3-x^2-4x-3)/(3x^3+10x^2+2x-3)
in> (x^4+3x^3-x^2-4x-3)/(3x^3+10x^2+2x-3)

out> 没有反应

 


已解决. 问题是其中的系数采用了数值计算, 1 除以 3 得 0.33333333, 这样导致无穷循环.

下面是采用分数运算后运行所得.

>>  (x^4+3x^3-x^2-4x-3)/(3x^3+10x^2+2x-3)
in> (x^4+3x^3-x^2-4x-3)/(3x^3+10x^2+2x-3)

out>
 quotient> q(x) = 1|3x^1-1|9
remainder> r(x) = -5|9x^2-25|9x^1-10|3

1|3x^1-1|9

------------------------

 


Remark:

这个例子见于 [1]  P. 12.

 

References:

[1] 李炯生、查建国  编著  《线性代数》

29. [BUG] Calculator 计算一元不定方程时的BUG

Posted by haifeng on 2022-12-07 10:04:57 last update 2022-12-07 10:04:57 | Answers (0) | 收藏


Solve the indefinite equation :
5*X1+8*X2 = 7

u1=7-2*u0
---------------
X1 = -1*u1+u0
X2 = -1*u0+u1
X1 = -1*X2+u0

------------------------

30. [Bug] Calculator 矩阵输入 Bug

Posted by haifeng on 2022-09-30 20:46:35 last update 2022-09-30 23:23:08 | Answers (0) | 收藏


B=[3 21 27/4;
1 -1 0;
-8 -2 37/4]

输入该矩阵, 出现 Bug.


>> B=[3 21 27/4;
B=[3 21 27/4;
1 -1 0;
-8 -2 37/4]
input> [3,21,27/4;1-1,0;-8,-2,37/4]
det(B)=0
----------------------------
 type: matrix
 name: B
value:
3       21      27/4
1-1     0       0
-8      -2      37/4

determinant: 0
--------------------


已经修复

>> B=[3 21 27/4;
B=[3 21 27/4;
1 -1 0;
-8 -2 37/4]
input> [3,21,27/4;1,-1,0;-8,-2,37/4]
det(B)=-289.50
----------------------------
 type: matrix
 name: B
value:
3       21      27/4
1       -1      0
-8      -2      37/4

determinant: -289.50
--------------------

 

<[1] [2] [3] [4] >