## News:

Message to All Guests
NB: Posting URL's See here: Posted URL Change

## The calculator

Started by RuiLoureiro, May 31, 2012, 10:59:09 PM

#### RuiLoureiro

Quote from: qWord on June 23, 2016, 06:32:31 AM
OK, so you do parsing on the fly and not as separate step (that was my thought).

regards
Ok  :t
Thanks
Hi all

Square Brackets or Not Brackets ?

In the last calcula67 that i post in this forum we get things like this

input box=> [-x*cos(2.6*x^2-1)
-2*sin(x)
+5*cos(x^2-x)
-sin(x)*cos(x)]'

solution box1=> -[cos(2.6*x^2-1)-5.2*x*sin(2.6*x^2-1)*x]
-2*cos(x)
-5*(2*x-1)*sin(x^2-x)
-[cos(x)*cos(x)-sin(x)*sin(x)]

In the new version calcula68 v2016.01 we get

input box=> [-x*cos(2.6*x^2-1)
-2*sin(x)
+5*cos(x^2-x)
-sin(x)*cos(x)]'

solution box1=> -cos(2.6*x^2-1)+5.2*x*sin(2.6*x^2-1)*x
-2*cos(x)
-5*(2*x-1)*sin(x^2-x)
-cos(x)*cos(x)+sin(x)*sin(x)
OR

input box=>        [-x*tan(2.6*x^2-1)]'

solution box1=> -tan(2.6*x^2-1)-5.2*x*sec(2.6*x^2-1)^2*x

Now, we have not square brackets. What do you say ?
What is better ?
Thanks  :t

#### RuiLoureiro

Quote from: qWord on June 19, 2016, 02:57:16 AM
Hi,
not so easy to find some expression, because nested functions (e.g. sin(cos(x))) are currently not implemented.
One thing I found is that
(-2^x)'
fails with
(-2^x)' = -2  ↯

Alos to note that editing expression is very unintuitive, because the DEL key clears the control rather than removing just one character (definitively breaks usability).

regards
Hi qWord,
In the new version v2016.01 - calcula68 - the calculator do derivatives of nested functions.
Today i got the first result:

input box=> [sin(x-cos( ln(x-1)-x )+x^2 )]'

solution box1=> cos(x-cos( ln(x-1)-x)+x^2 )*[1-(-sin(ln(x-1)-x)*(1/(x-1)-1))+2*x ]

Is there any problem ?
I will post the new versiom as soon as possible.
regards  :t

#### HSE

Fantastic Rui!!

Perhaps you can replace in the final string "-(-sin"  by   "+(sin"
Equations in Assembly: SmplMath

#### RuiLoureiro

Quote from: HSE on July 05, 2016, 09:12:50 AM
Fantastic Rui!!

Perhaps you can replace in the final string "-(-sin"  by   "+(sin"

Many thanks HSE  :t

Here it is:

input box=> [sin(x-cos(ln(x-1)-x)+x^2)]'

solution box1=> cos(x-cos(ln(x-1)-x)+x^2)*[1+sin(ln(x-1)-x)*(1/(x-1)-1)+2*x]

But it gave me a lot of work but it is better, we have not brackets !
Thanks
Are you working in your calculator ? Is it running ?
:icon14:

#### HSE

Perfect now  :t

My derivator sleep. Last week I open the file but close without changes, and begin to make little modifications in HJWasm to see how many macro levels I'm using, and that take me some time. The connection is: I think to obtain derivatives through object recursion, and that perhaps increase macro levels very fast.
Equations in Assembly: SmplMath

#### RuiLoureiro

Quote from: HSE on July 06, 2016, 10:02:34 AM
Perfect now  :t

My derivator sleep. Last week I open the file but close without changes, and begin to make little modifications in HJWasm to see how many macro levels I'm using, and that take me some time. The connection is: I think to obtain derivatives through object recursion, and that perhaps increase macro levels very fast.
Ok, good work
Now i have the solutions for 2 nested functions: one inside onother

input box=> [sin(x^2-cos(x^2-x))]'

solution box1=> cos(x^2-cos(x^2-x))*[2*x+sin(x^2-x)*(2*x-1)]

It starts to work !
Thanks  :t

#### RuiLoureiro

#141
Hi all

Here we have the solutions for the sum of 6 nested functions:

Six functions and six derivatives in the format type I

input box=> [arcsin(cos(x^2-x)+x^2-x+1)
+arcsin(x^2-cos(x^2-x))
+arcsin(x^2-cos(x^2-x)+x^2-x+1)

+arccos(cos(x^2-x)+x^2-x+1)
+arccos(x^2-cos(x^2-x))
+arccos(x^2-cos(x^2-x)+x^2-x+1)]'

solution box1=> 1/sqr(1-(cos(x^2-x)+x^2-x+1)^2)*[-sin(x^2-x)*(2*x-1)+2*x-1]
+1/sqr(1-(x^2-cos(x^2-x))^2)*[2*x+sin(x^2-x)*(2*x-1)]
+1/sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2)*[2*x+sin(x^2-x)*(2*x-1)+2*x-1]

-1/sqr(1-(cos(x^2-x)+x^2-x+1)^2)*[-sin(x^2-x)*(2*x-1)+2*x-1]
-1/sqr(1-(x^2-cos(x^2-x))^2)*[2*x+sin(x^2-x)*(2*x-1)]
-1/sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2)*[2*x+sin(x^2-x)*(2*x-1)+2*x-1]

The same Six functions and six derivatives in the format type II

input box=> [arcsin(cos(x^2-x)+x^2-x+1)
+arcsin(x^2-cos(x^2-x))
+arcsin(x^2-cos(x^2-x)+x^2-x+1)

+arccos(cos(x^2-x)+x^2-x+1)
+arccos(x^2-cos(x^2-x))
+arccos(x^2-cos(x^2-x)+x^2-x+1)]'

solution box1=> [-sin(x^2-x)*(2*x-1)+2*x-1]/sqr(1-(cos(x^2-x)+x^2-x+1)^2)
+[2*x+sin(x^2-x)*(2*x-1)]/sqr(1-(x^2-cos(x^2-x))^2)
+[2*x+sin(x^2-x)*(2*x-1)+2*x-1]/sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2)

+[sin(x^2-x)*(2*x-1)-2*x+1]/sqr(1-(cos(x^2-x)+x^2-x+1)^2)
+[-2*x-sin(x^2-x)*(2*x-1)]/sqr(1-(x^2-cos(x^2-x))^2)
+[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2)

Do you like the solutions ?
Good luck  ;)
JUL 2016
More results:
`input box=> [arctan(cos(x^2-x)+x^2-x+1)            +arctan(x^2-cos(x^2-x))            +arctan(x^2-cos(x^2-x)+x^2-x+1)                        +arccot(cos(x^2-x)+x^2-x+1)            +arccot(x^2-cos(x^2-x))            +arccot(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [-sin(x^2-x)*(2*x-1)+2*x-1]/(1+(cos(x^2-x)+x^2-x+1)^2)               +[2*x+sin(x^2-x)*(2*x-1)]/(1+(x^2-cos(x^2-x))^2)               +[2*x+sin(x^2-x)*(2*x-1)+2*x-1]/(1+(x^2-cos(x^2-x)+x^2-x+1)^2)                              +[sin(x^2-x)*(2*x-1)-2*x+1]/(1+(cos(x^2-x)+x^2-x+1)^2)               +[-2*x-sin(x^2-x)*(2*x-1)]/(1+(x^2-cos(x^2-x))^2)               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/(1+(x^2-cos(x^2-x)+x^2-x+1)^2)input box=> [arcsec(cos(x^2-x)+x^2-x+1)            +arcsec(x^2-cos(x^2-x))            +arcsec(x^2-cos(x^2-x)+x^2-x+1)                        +arccsc(cos(x^2-x)+x^2-x+1)            +arccsc(x^2-cos(x^2-x))            +arccsc(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [-sin(x^2-x)*(2*x-1)+2*x-1]/(abs(os(x^2-x)+x^2-x+1)*sqr((cos(x^2-x)+x^2-x+1)^2-1))               +[2*x+sin(x^2-x)*(2*x-1)]/(abs(x^2-cos(x^2-x))*sqr((x^2-cos(x^2-x))^2-1))               +[2*x+sin(x^2-x)*(2*x-1)+2*x-1]/(abs(x^2-cos(x^2-x)+x^2-x+1)*sqr((x^2-cos(x^2-x)+x^2-x+1)^2-1))                              +[sin(x^2-x)*(2*x-1)-2*x+1]/(abs(os(x^2-x)+x^2-x+1)*sqr((cos(x^2-x)+x^2-x+1)^2-1))               +[-2*x-sin(x^2-x)*(2*x-1)]/(abs(x^2-cos(x^2-x))*sqr((x^2-cos(x^2-x))^2-1))               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/(abs(x^2-cos(x^2-x)+x^2-x+1)*sqr((x^2-cos(x^2-x)+x^2-x+1)^2-1))input box=> [arcsinh(cos(x^2-x)+x^2-x+1)            +arcsinh(x^2-cos(x^2-x))            +arcsinh(x^2-cos(x^2-x)+x^2-x+1)                        +arccosh(cos(x^2-x)+x^2-x+1)            +arccosh(x^2-cos(x^2-x))            +arccosh(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [-sin(x^2-x)*(2*x-1)+2*x-1]/sqr((cos(x^2-x)+x^2-x+1)^2+1)               +[2*x+sin(x^2-x)*(2*x-1)]/sqr((x^2-cos(x^2-x))^2+1)               +[2*x+sin(x^2-x)*(2*x-1)+2*x-1]/sqr((x^2-cos(x^2-x)+x^2-x+1)^2+1)                              +[sin(x^2-x)*(2*x-1)-2*x+1]/sqr((cos(x^2-x)+x^2-x+1)^2-1)               +[-2*x-sin(x^2-x)*(2*x-1)]/sqr((x^2-cos(x^2-x))^2-1)               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/sqr((x^2-cos(x^2-x)+x^2-x+1)^2-1)input box=> [arcsech(cos(x^2-x)+x^2-x+1)            +arcsech(x^2-cos(x^2-x))            +arcsech(x^2-cos(x^2-x)+x^2-x+1)                        +arccsch(cos(x^2-x)+x^2-x+1)            +arccsch(x^2-cos(x^2-x))            +arccsch(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [sin(x^2-x)*(2*x-1)-2*x+1]/(cos(x^2-x)+x^2-x+sqr(1-(cos(x^2-x)+x^2-x+1)^2))               +[-2*x-sin(x^2-x)*(2*x-1)]/((x^2-cos(x^2-x))*sqr(1-(x^2-cos(x^2-x))^2))               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/((x^2-cos(x^2-x)+x^2-x+1)*sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2))                              +[sin(x^2-x)*(2*x-1)-2*x+1]/(abs(os(x^2-x)+x^2-x+1)*sqr(1+(cos(x^2-x)+x^2-x+1)^2))               +[-2*x-sin(x^2-x)*(2*x-1)]/(abs(x^2-cos(x^2-x))*sqr(1+(x^2-cos(x^2-x))^2))               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/(abs(x^2-cos(x^2-x)+x^2-x+1)*sqr(1+(x^2-cos(x^2-x)+x^2-x+1)^2))input box=> [arctanh(cos(x^2-x)+x^2-x+1)            +arctanh(x^2-cos(x^2-x))            +arctanh(x^2-cos(x^2-x)+x^2-x+1)                        +arccoth(cos(x^2-x)+x^2-x+1)            +arccoth(x^2-cos(x^2-x))            +arccoth(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [-sin(x^2-x)*(2*x-1)+2*x-1]/(1-(cos(x^2-x)+x^2-x+1)^2)               +[2*x+sin(x^2-x)*(2*x-1)]/(1-(x^2-cos(x^2-x))^2)               +[2*x+sin(x^2-x)*(2*x-1)+2*x-1]/(1-(x^2-cos(x^2-x)+x^2-x+1)^2)                              +[sin(x^2-x)*(2*x-1)-2*x+1]/(1+(cos(x^2-x)+x^2-x+1)^2)               +[-2*x-sin(x^2-x)*(2*x-1)]/(1+(x^2-cos(x^2-x))^2)               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/(1+(x^2-cos(x^2-x)+x^2-x+1)^2)input box=> [arcsech(cos(x^2-x)+x^2-x+1)            +arcsech(x^2-cos(x^2-x))            +arcsech(x^2-cos(x^2-x)+x^2-x+1)                        +arccsch(cos(x^2-x)+x^2-x+1)            +arccsch(x^2-cos(x^2-x))            +arccsch(x^2-cos(x^2-x)+x^2-x+1)]'solution box1=> [sin(x^2-x)*(2*x-1)-2*x+1]/(cos(x^2-x)+x^2-x+sqr(1-(cos(x^2-x)+x^2-x+1)^2))               +[-2*x-sin(x^2-x)*(2*x-1)]/((x^2-cos(x^2-x))*sqr(1-(x^2-cos(x^2-x))^2))               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/((x^2-cos(x^2-x)+x^2-x+1)*sqr(1-(x^2-cos(x^2-x)+x^2-x+1)^2))                              +[sin(x^2-x)*(2*x-1)-2*x+1]/(abs(os(x^2-x)+x^2-x+1)*sqr(1+(cos(x^2-x)+x^2-x+1)^2))               +[-2*x-sin(x^2-x)*(2*x-1)]/(abs(x^2-cos(x^2-x))*sqr(1+(x^2-cos(x^2-x))^2))               +[-2*x-sin(x^2-x)*(2*x-1)-2*x+1]/(abs(x^2-cos(x^2-x)+x^2-x+1)*sqr(1+(x^2-cos(x^2-x)+x^2-x+1)^2))`

#### Mikl__

Olá, Rui!
Quero parabenizá-lo pela vitória de Portugal no Campeonato Europeu de Futebol!

#### jj2007

Congrats from Italy :t

#### RuiLoureiro

Quote from: Mikl__ on July 11, 2016, 10:48:34 AM
Olá, Rui!
Quero parabenizá-lo pela vitória de Portugal no Campeonato Europeu de Futebol!

Olá meu amigo Mikl__ !
Por acaso gosto de futebol e também eu joguei futebol
:icon14:

#### RuiLoureiro

Quote from: jj2007 on July 11, 2016, 11:15:48 AM
Congrats from Italy :t
Thank you so much, my old friend Jochen !
I like your Italy team too  :t
:icon14:

#### RuiLoureiro

#146
Hi
Here more interesting results:

input box=> [exp(ln(sin(x)))
+sin(cos(-tan(x)))
+sin(-cos(tan(x)))
+sin(-cos(-tan(x)))
-sin(-cos(-tan(x)))
+exp(-ln(sin(x)))]'

solution box1=> exp(ln(sin(x)))/(sin(x))*cos(x)
-cos(cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
+cos(-cos(tan(x)))*sin(tan(x))*sec(x)^2
+cos(-cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
-cos(-cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
-exp(-ln(sin(x)))/(sin(x))*cos(x)

Good luck  :t

#### RuiLoureiro

Hi

Functions and derivatives solutions TYPE I

input box=> [exp(ln(sin(x)))
+sin(cos(-tan(x)))
+sin(-cos(tan(x)))
+sin(-cos(-tan(x)))
-sin(-cos(-tan(x)))
+exp(-ln(sin(x)))]'

solution box1=> exp(ln(sin(x)))*cos(x)/sin(x)
-cos(cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
+cos(-cos(tan(x)))*sin(tan(x))*sec(x)^2
+cos(-cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
-cos(-cos(-tan(x)))*sin(-tan(x))*(-sec(x)^2)
-exp(-ln(sin(x)))*cos(x)/sin(x)

The same Functions and derivatives better solutions TYPE II

input box=> [exp(ln(sin(x)))
+sin(cos(-tan(x)))
+sin(-cos(tan(x)))
+sin(-cos(-tan(x)))
-sin(-cos(-tan(x)))
+exp(-ln(sin(x)))]'

solution box1=> exp(ln(sin(x)))*cos(x)/sin(x)
+cos(cos(-tan(x)))*sin(-tan(x))*sec(x)^2
+cos(-cos(tan(x)))*sin(tan(x))*sec(x)^2
-cos(-cos(-tan(x)))*sin(-tan(x))*sec(x)^2
+cos(-cos(-tan(x)))*sin(-tan(x))*sec(x)^2
-exp(-ln(sin(x)))*cos(x)/sin(x)

Good luck !  :t

#### HSE

Impressive Rui :t

When TYPE III ?

solution box1=>  cos(x)/sin(x)* ( exp(ln(sin(x)))-exp(-ln(sin(x))) )+
sec(x)^2*(
+cos(-cos(tan(x)))*sin(tan(x))
+sin(-tan(x))*( cos(cos(-tan(x)))-cos(-cos(-tan(x)))+cos(-cos(-tan(x))) )
)

Equations in Assembly: SmplMath

#### RuiLoureiro

Quote from: HSE on July 13, 2016, 05:51:13 AM
Impressive Rui :t

When TYPE III ?

solution box1=>  cos(x)/sin(x)* ( exp(ln(sin(x)))-exp(-ln(sin(x))) )+
sec(x)^2*(
+cos(-cos(tan(x)))*sin(tan(x))
+sin(-tan(x))*( cos(cos(-tan(x)))-cos(-cos(-tan(x)))+cos(-cos(-tan(x))) )
)
Hi,
Many thanks HSE !  :t

Yes i could give the TYPE III solutions without any problems
It will be [FncX(ArgX]' = [ArgX]' * FncX' = ...

But i do
[FncX(ArgX)]' = FncX' * [ArgX]' = ...

Example: [exp(ln(sin(x)))]' = [ln(sin(x))]' * exp(ln(sin(x)))
= [sin(x)]'/ sin(x) * exp(ln(sin(x)))
= cos(x)/sin(x) * exp(ln(sin(x)))

In the following examples, when we get the cases FncZ / FncY / FncX at the end
they are modified to FncZ / (FncY * FncX ).
The example is this:

-exp(ln(sin(1/x)))*cos(1/x) / (x^2*sin(1/x))

Here we have functions of X, -X, 1/X and -1/X
Quote
input box=> [exp(ln(sin(x)))
+sin(cos(-tan(x)))
+sin(-cos(tan(x)))
+sin(-cos(-tan(x)))
-sin(-cos(-tan(x)))
+exp(-ln(sin(x)))]'

solution box1=>     exp(ln(sin(x)))*cos(x)/sin(x)
+cos(cos(-tan(x)))*sin(-tan(x))*sec(x)^2
+cos(-cos(tan(x)))*sin(tan(x))*sec(x)^2
-cos(-cos(-tan(x)))*sin(-tan(x))*sec(x)^2
+cos(-cos(-tan(x)))*sin(-tan(x))*sec(x)^2
-exp(-ln(sin(x)))*cos(x)/sin(x)

input box=> [exp(ln(sin(-x)))
+sin(cos(-tan(-x)))
+sin(-cos(tan(-x)))
+sin(-cos(-tan(-x)))
-sin(-cos(-tan(-x)))
+exp(-ln(sin(-x)))]'

solution box1=>     -exp(ln(sin(-x)))*cos(-x)/sin(-x)
-cos(cos(-tan(-x)))*sin(-tan(-x))*sec(-x)^2
-cos(-cos(tan(-x)))*sin(tan(-x))*sec(-x)^2
+cos(-cos(-tan(-x)))*sin(-tan(-x))*sec(-x)^2
-cos(-cos(-tan(-x)))*sin(-tan(-x))*sec(-x)^2
+exp(-ln(sin(-x)))*cos(-x)/sin(-x)

input box=> [exp(ln(sin(1/x)))
+sin(cos(-tan(1/x)))
+sin(-cos(tan(1/x)))
+sin(-cos(-tan(1/x)))
-sin(-cos(-tan(1/x)))
+exp(-ln(sin(1/x)))]'

solution box1=>     -exp(ln(sin(1/x)))*cos(1/x)/(x^2*sin(1/x))
-cos(cos(-tan(1/x)))*sin(-tan(1/x))*sec(1/x)^2/x^2
-cos(-cos(tan(1/x)))*sin(tan(1/x))*sec(1/x)^2/x^2
+cos(-cos(-tan(1/x)))*sin(-tan(1/x))*sec(1/x)^2/x^2
-cos(-cos(-tan(1/x)))*sin(-tan(1/x))*sec(1/x)^2/x^2
+exp(-ln(sin(1/x)))*cos(1/x)/(x^2*sin(1/x))

input box=> [exp(ln(sin(-1/x)))
+sin(cos(-tan(-1/x)))
+sin(-cos(tan(-1/x)))
+sin(-cos(-tan(-1/x)))
-sin(-cos(-tan(-1/x)))
+exp(-ln(sin(-1/x)))]'

solution box1=>     exp(ln(sin(-1/x)))*cos(-1/x)/(x^2*sin(-1/x))
+cos(cos(-tan(-1/x)))*sin(-tan(-1/x))*sec(-1/x)^2/x^2
+cos(-cos(tan(-1/x)))*sin(tan(-1/x))*sec(-1/x)^2/x^2
-cos(-cos(-tan(-1/x)))*sin(-tan(-1/x))*sec(-1/x)^2/x^2
+cos(-cos(-tan(-1/x)))*sin(-tan(-1/x))*sec(-1/x)^2/x^2
-exp(-ln(sin(-1/x)))*cos(-1/x)/(x^2*sin(-1/x))
Good luck !  :t
:icon14:
NOTE: In reply #146 we have other solutions because Z/Y*X is equivalent to Z*X/Y and
Z / Y / X is equivalent to Z/ ( Y * X )