Items tagged with derivative derivative Tagged Items Feed

Hi

I need you to help me in writting procedure with input "r" ( order of derivative) and some coefficients seq(alpha[i],i=1..N).  My code work very well, need only put all the element in procedure with output The Taylor series obtained in last line of my code and the order of error.  I want the procedure return the coefficients beta used in the series and the order of Error  and the coefficients beta[i]

May thinks.

Second_Question.mw

 

I will not modify my previous question: only I add this remark. I tried to write these lines of procedure.
Add_display.mw

I need only to add( if the procedure is true) these lines in my procedure.  These lines gives the degree of error computed in the code, but when I put these lines in the codes, there is an error. Thanks for your help.

Degree := degree(Error,stepsize);
    if (showorder) then:
       print(cat(`This stencil is of order `,Degree));
    fi:
    if (showerror) then:
       print(cat(`This leading order term in the error is `,Error));
    fi:
    convert(D[r$n](f)(vars) = stencil,diff);

 

 

 

Dear All, I need your help to plot the numerical solution. many thanks.

The variable t in [0,T], x in [0,1], b in [0,2].

Difference finie for waves equation is :

pde:=diff(u(x, y,t), t$2) = c^2*(diff(u(x, y,t),x$2)+diff(u(x,y,t),y$2));

i: according to x, j according to y, and k according to t.

u[i,j,k+1]=2*u[i,j,k]-u[i,j,k-1]+(c*dt/dx)^2*(u[i-1,j,k]-2*u[i,j,k]+u[i+1,j,k])+ (c*dt/dy)^2*(u[i,j-1,k]-2*u[i,j,k]+u[i,j+1,k])

 

Boundary condition: u(t=0)=1, diff(u(x,y,t),t=0)=0, and the normal derivative on the boundary of Omega =0.

How can solve this problem and plot the numerical solution.

 

 

 

I'm simplifying this Reynolds Equation starting from here:

Reynolds:=Diff(p(x)*h(x)^3/(12*mu)*Diff(p(x),x),x)-u(x)/2*Diff(p(x)*h(x),x)+Diff(p(x)*h(x)^3/(12*mu)*Diff(p(x),z),z)=Diff(p(x)*h(x),t):

 

Then I apply the dchange command:

dchange({p(x)=P(X)*Pa,x=Lx*X,h(x)=H(X)*h2},Reynolds,{P,h,X,u,H});

 

The problem is that it expands the new derivatives and I need the equation in its compact form.

How do I tel Maple only to make the substitution but not to expand the result?

I know that it expands by default, can I modify that?

 

 

I'm writing a simple Maple program to test the Generalized Finite Element Method: main_screened_Poisso.mw

When trying to define the Neumann boundary conditions, I have to define a directional derivative dudn=dudx*n. However, I can't seem to define a unit vector normal to Gamma, which is defined by a LineSegments objects.

Other than that, the row reduction is very slow, even though I'm using floating point arithmatic and not exact arithmatic, I believe.

How can I solve these problems? Thanks in advance!

 

I want  to verify the following function expression

is indeed an antiderivative of the function expression

where  A>0 with B^2-4*A*C<0.

I have tried the command

>diff((2),x);simplify(%);

where (2) is the label of the antiderivative expression.  But the result is very awkarward and lengthy. How could I verify the antiderivative expression is indeed an antiderivative of the other function by using Maple 17? 

 

I have following expression

f:=t->((1/8)*s^2*sinh(4*t)+t+(1/2)*s^2*t+s*sinh(2*t))/(1+s*cosh(2*t))

which is 1 solution of the ODE

ode2 := -(diff(y(t), t, t))+(4-12/(1+s*cosh(2*t))+(8*(-s^2+1))/(1+s*cosh(2*t))^2)*y(t) = 0

Now I wanted to construct 2 linear independent solutions via:

f1:=f(t_b-t)

f2:=f(t-t_a)

and calculate the Wronskian:

with(LinearAlgebra); with(VectorCalculus)

Determinant(Wronskian([f(t_b-t), f(t-t_a)], t))

Since I know these functions are solutions of the second order ODE which does not contain any first order derivative the Wronskian should be a constant. Unfortunately Maple has a hard time to simplify it since the epxression is a little big. Is it my fault or has anyone an idea what to do?

I assign a function like so: f:=x->0.2*x^2*(x-3)^3

Then using d/dx in the expression palette I differentiate: d/dx f(x)

Get the following: 0.6x^2 (x-3)^2 D(x^2)(x-3)

What is the "D" in the last expression? What hasn't the whole differentiation been completed?

Hello, Suppose I have two sinusoids with the same amplitude and frequency. By changing the phase of one of them it is possible to 'align' them. When the phases are exactly the same the difference between the two sinusoids becomes zero. Now lets define a variable (U[int]) that gives a measure of the difference between the two sinusoids and change the phase phi to generate an animation and 3D plot and see if it is possible to mathematically determine that the difference becomes zero when the phases of the waveforms are equal. Chosing a time t>0 and solving for the derivative does the job.

My question is, can (and how can) Maple determine for which phase phi we have the minimum function without chosing a time t.
 

restart

with(plots):

u[G] := sin(omega*t)

u[L] := sin(omega*t+phi)

U[int] := int((u[G]-u[L])^2, t)+C

C := solve(subs(t = 0, U[int]) = 0, C)

omega := 9:

animate(plot, [[u[G], u[L], (1/10)*U[int]], t = 0 .. 2, legend = ["Public grid voltage", "Local grid voltage (control goal)", "Cum. Actuator voltage (scaled)"]], phi = -Pi .. Pi, gridlines = true, labels = ["Time [s]","Voltage [V]"], labeldirections = ["horizontal", "vertical"], labelfont = ["ARIAL", "bold", 12])

plot3d(U[int], t = 0 .. 2, phi = -Pi .. Pi, shading = zhue, orientation = [-150, 70, 15])

t := 1:

phi = fsolve(diff(U[int], phi))


Download 20131114_Finding_min.mw

 

Thanks a lot!

Consider the curve defined by f(x, y) = 3+2x+y+2x^2+2xy+3y^2 = 0.Locally on the curve we can view y as a function of x, i.e. y = y(x).Compute formulas for the first and second derivative of y with resoect to x.

I have an equation x2y-3y3x=0. I want to find the slope of the graph at the point (3,1) , that is the derivative at that point. I was told it was possible to do this in one line of command, so I was just wondering if anyone knoew how to do this. Any ideas would be helpful. Thanks in advance.

I would like to find the derivative for f(x)=min(x^2 +1, 2x+3) and plot f(x) and its derivative on the same graph. I know the "diff" command works on functions, but I'm not sure how to use it on this one. Suggestions would be appreciated. Thanks!

Hey guys,

I have the following problem:

I would like to know whether the derivative (e) is negative (given certain assumptions). 

e := diff(((d1-pfw1*Kw-pfs1*Ks-1/3*(d1-pfw1*Kw-pfs1*Ks+d2-pfw2*Kw-pfs2*Ks+d3-pfw3*Kw-pfs3*Ks))*(pf1w-1/3*(pfw1+pfw2+pfw3))+(d2-pfw2*Kw-pfs2*Ks-1/3*(d1-pfw1*Kw-pfs1*Ks+d2-pfw2*Kw-pfs2*Ks+d3-pfw3*Kw-pfs3*Ks))*(pf2w-1/3*(pfw1+pfw2+pfw3))+(d3-pfw3*Kw-pfs3*Ks-1/3*(d1-pfw1*Kw-pfs1*Ks+d2-pfw2*Kw-pfs2*Ks+d3-pfw3*Kw-pfs3*Ks))*(pf3w-1/3*(pfw1+pfw2+pfw3...

Derivative Definition...

October 02 2013 rkm 10

On the test I had today I was asked to find the derivative of x^3+3*cos(x) using the definition of a derivative. The (f(x+h)-f(x))/h type.

So i set my function and then used the definition and then tried to simplify. Unfortunately the bottom h is still there so when I try to evaluate the function when h=0 it returns an obvious problem. It can't divide by zero. Usually when I do this the h on the bottom will be canceled out, but it wouldn't do it for this one. Does...

Today, I was working on a problem in the class which said:

if f(x)=ax^2+b, x<=1 and 1/x, x>1; then find the values of "a" and "b" such that f'(1) be defined. I checked it to be continuous at x=1 first and so I got a+b=1. Secondly, I wanted to get another equation, so I checked the differentiability of the function by the definition of derivation at x=1, so:

[> f := x-> piecewise(x <= 1, a*x^2+b, 1 < x, 1/x);
> limit((f(x)-f(1))/(x-1), x = 1, right);

1 2 3 4 5 6 7 Last Page 1 of 22