HP Forums
Confusing derivative(sqrt(1-sinx)) result Bug? [SOLVED] - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: Confusing derivative(sqrt(1-sinx)) result Bug? [SOLVED] (/thread-10666.html)



Confusing derivative(sqrt(1-sinx)) result Bug? [SOLVED] - vvolkan - 05-04-2018 09:12 PM

Derivative of sqrt(1-sinx) should be -cosx/2sqrt(1-sinx) but it returns a long confusing result and it cant be simplified.


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - Arno K - 05-05-2018 07:48 AM

As I get everything correct in CAS on the emulator you should show us a screenshot.
Arno


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - vvolkan - 05-05-2018 09:24 AM

Hi Arno,
I tried on HP Prime Pro app and pc(both rev.13441),same result. Here are the screenshots from pc.
Volkan


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - DrD - 05-05-2018 10:15 AM

(05-04-2018 09:12 PM)vvolkan Wrote:  Derivative of sqrt(1-sinx) should be cosx/2sqrt(1-sinx) but it returns a long confusing result and it cant be simplified.

[emulator]:
The result should include a negative sign: (-1/2)*cos(x)*1/(sqrt(1-sin(x))).
[attachment=5888] [attachment=5889]


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - Aries - 05-05-2018 10:45 AM

(05-04-2018 09:12 PM)vvolkan Wrote:  Derivative of sqrt(1-sinx) should be cosx/2sqrt(1-sinx) but it returns a long confusing result and it cant be simplified.

[Image: derivative.jpg]

Best,

Aries Wink


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - parisse - 05-05-2018 12:43 PM

sqrt(1-sin(x)) is auto-simplified to sqrt(2)*abs(sin(-pi/4+x/2)), because it's much better not to deal with "false" sqrt, for example if you want to integrate sqrt(1-sin(x)).
The derivative is sqrt(2)*cos(x/2-pi/4)*abs(sin(x/2-pi/4))/(2*sin(x/2-pi/4)), it looks complicated but it is not: it's the product of a cos by a sign. If you make assumptions on x like
assume(x>0 && x<pi/2), you will not get absolute values, and the derivative is simpler -sqrt(2)*cos(x/2-pi/4)/2


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - vvolkan - 05-05-2018 01:43 PM

It seems as calc gives different variation of result if "√" is used instead of "^1/2" for this derivative. Thanks parisse for comprehensive explanation.


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - vvolkan - 05-05-2018 07:24 PM

(05-05-2018 10:15 AM)DrD Wrote:  
(05-04-2018 09:12 PM)vvolkan Wrote:  Derivative of sqrt(1-sinx) should be cosx/2sqrt(1-sinx) but it returns a long confusing result and it cant be simplified.

[emulator]:
The result should include a negative sign: (-1/2)*cos(x)*1/(sqrt(1-sin(x))).

Hi DRD,
I forgot to write the negative sign. I edited the main post. I shared screenshots to clarify the problem. Thanks


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - Arno K - 05-05-2018 09:15 PM

(05-05-2018 01:43 PM)vvolkan Wrote:  It seems as calc gives different variation of result if "√" is used instead of "^1/2" for this derivative. Thanks parisse for comprehensive explanation.

So you got your desired answer.
Arno


RE: Wrong derivative(sqrt(1-sinx)) result Bug? - parisse - 05-06-2018 06:40 AM

Another way to get it: sqrt(a-sin(x))'