On Wed, Oct 31, 2018 at 9:11 AM Francesco wrote:
>
> Hello; I have installed sage 8.4 and I have problem with the derivatives ...
> I have defined a function in sage of this type:
>
> x=var('x')
> def funz(x):
>if x >= 0:
> return x^2
>else:
> return x^3
>
> but, when I try to
Hello; I have installed sage 8.4 and I have problem with the derivatives
...
I have defined a function in sage of this type:
x=var('x')
def funz(x):
if x >= 0:
return x^2
else:
return x^3
but, when I try to calculate
diff(funz(x),x)
I obtain only
3x^2
and this is wrong !
>From searching the net (1), I gather that
log(x).conjugate(x).diff(x)
should yield
(log(x)/x).conjugate()
but Sage cannot evaluate such differentiated conjugates of functions:
sage: ex=log(x).conjugate()
sage: ex=log(x).conjugate(); ex
conjugate(log(x))
sage: ex.diff(x)
D[0](conjugate)(log(x))/
I am trying to find the maximun of an exponential expression of the form:
sage: t=var('t')
sage: g(t) = e**(-t/10)-e^(-t/2)
between 0 and say 50. My idea is to get the maximun to normalize the
function to that maximum and obtain the algebraic. For that:
sage: diff(g,t)==0,t)
But sage returns
On Sun, 15 Aug 2010 08:37:10 -0700 (PDT)
Paul Rombouts wrote:
> Hi,
>
> I can integrate the function exp(-x^2) to get the error function like
> this:
>
> sage: F=integral(exp(-x^2),x); F
> 1/2*sqrt(pi)*erf(x)
>
> But when I try to differentiate the answer, sage does not seem to know
> the deri
Hi,
I can integrate the function exp(-x^2) to get the error function like
this:
sage: F=integral(exp(-x^2),x); F
1/2*sqrt(pi)*erf(x)
But when I try to differentiate the answer, sage does not seem to know
the derivative of erf:
sage: F.diff(x)
1/2*sqrt(pi)*D[0](erf)(x)
I am assuming that the su
Is there any way to check whether a symbolic expression is a
derivative. Like,
isinstance(diff(f(x),x),"what to put?")
gives "True"
and
isinstance(f(x),"what to put?")
gives false, assuming f is not a derivative itself.
--
To post to this group, send email to sage-support@googlegroups.com
To
On alpha.sagenb.org, I get the following:
sage: t=var('t')
sage: diff(cot(t),t)
D[0](cot)(t)
sage: diff(cos(t)/sin(t),t)
-cos(t)^2/sin(t)^2 - 1
Does Sage not know that cot(t) is cos(t)/sin(t)? Or am I just being silly?
Jason
--~--~-~--~~~---~--~~
To post to t
y=|x|
1st derivative should be +1 x>0 and -1,X<0
f(x) = abs(x)
Dx = x.derivative()
p1 = plot (f(x),(-5,5),color='black')
p2 = plot (Dx, (0,5),color = 'red')
p3 = plot (Dx, (-5,0),color = 'blue')
show (p1+p2+p3)
-d
--~--~-~--~~~---~--~~
To post to this group, se
Hi all:
Upon upgrading to Sage 4.0, i can no longer make a dictionary with
derivatives as keys (see below). Can someone please fix this?
Alex
--
| Sage Version 4.0, Release Date: 2009-05-29 |
| Type not
Hi all:
Do any of you know how to get Sage to use the chain rule and expand
the derivative of a composition involving one or two callable symbolic
functions? Here's an example with one callable symbolic function.
--
| Sage Vers
Hello
Another problem:
I want the derivative for the function arccos((1-x^2)/(1+x^2))
I wrote:
f=arccos((1-x^2)/(1+x^2))
f.diff(x)
-(-2*x/(x^2 + 1) - 2*x*(1 - x^2)/(x^2 + 1)^2)/sqrt(1 - (1 - x^2)^2/
(x^2 + 1)^2)
The best answer would be:
2/(1+x^2)*sign(x)
How can I simplify this expression to
I want to accomplish the following:
Mathematica syntax:
x=q[t];
z=1/2 *x^2;
x'=D[x,t];
z'=D[z,t];
D[z*z',x']
out: 1/2 q[t]^3
When I try this in sage :
t=variable('t')
x=function('q',t)
x_dot=diff(x,t)
z_dot=diff(z,t)
diff(z_dot *z,x_dot)
fails because x_dot is a derivative and not a symbol
13 matches
Mail list logo