>
 >
 >
 >
 >
 >
 >
 >
 >
 >
 >

## How do I get rid of the error?...

`Download 2222222222222222222.mw`

```> restart;
> A[0] := 10^(-3); a := 10^5;
> sys := diff(R(theta), theta) = A[0]*exp(2*mu(theta))*sin(theta)/(2*a), R(theta) = 2*exp(-2*mu(theta))*(1-(diff(mu(theta), `\$`(theta, 2)))-cot(theta)*(diff(mu(theta), theta)));
> cond := R(0) = 10^(-5), mu(0) = 118.92, (D(mu))(0) = 0;
> F := dsolve({cond, sys}, [R(theta), mu(theta)], numeric);
> with(plots);
> odeplot(F, [theta, R(theta)], 0 .. 3.14, color = black, thickness = 3, linestyle = 4)
> odeplot(F, [theta, mu(theta)], 0 .. 3.14, color = blue, thickness = 3, linestyle = 1)```

After last two lines maple writes:

Warning, cannot evaluate the solution past the initial point, problem may be complex, initially singular or improperly set up

And gives me empty plots. I can't figure out where an error can be. Some things I noticed:

Maple doesn't calculate the system before and after zero. If I change the range from 0..3.14 to -10..10 or to 0.00001..0.00001, it gives me 2 errors for 1 plot.

Also if I change the condition mu(0) = 118.92 to mu(0) = 1 or mu(0) = 50 or mu(0) = 80, it works. After ~80 it gives an error. I can't imagine where could appear a division by 0 or some other mistake.

## Can this Jacobi Differential equation be solved?...

I have been trying to find a solution for the equation below. Is there a non numerical explicit solution?

 (1)

 (2)

 (3)

 (4)

 (5)

 (6)

 (7)

 (8)

 (9)

 (10)

 (11)

## How do I solve the example from Maple Help LPSolve...

When I try the example from Maple Help for LPSolve (I use Windows)

with(Optimization);
LPSolve(-4*x-5*y, {0 <= x, 0 <= y, x+2*y <= 6, 5*x+4*y <= 20});

I do not get the same solution like in the example: [-19., [x = 2.66666666666667, y = 1.66666666666667]]

Warning, problem appears to be unbounded
[0., [x = HFloat(0.0), y = HFloat(0.0)]]

My Professor uses the same version, but with Linux and do not have such problems. Why my installation does not solve the standart Help example?

Thank you

## Maple fails to simplify negative power...

f1:=(1/s^2)^N;

Maple failed to convert it into  f1:=s^(-2N);

## Solve PDE by pdsolve, how to interpret answer?...

Hi!

Tried to solve the PDE below (q and p are time-dependent variabels, q(t),p(t)):

```pde := diff(rho(t, q, p), t) = -(diff(rho(t, q, p), q))*p+(diff(rho(t, q, p), p))*(2*q+2);

pdsolve(pde, rho(t, q, p));
```

`rho(t, q, p) = _F1(p^2+2*q^2+4*q, -(1/2)*sqrt(2)*arctan((q+1)*sqrt(2)*(1/sqrt(p^2)))+t)`

But I'm not sure how to interpret the result. I understand that  _F1 is an arbitrary function, but then I get confused with the comma? I thought that I'd get a function of q and p, where they depend on t.

Best regards
Sannis

## How do I solve a first order linear PDE with two t...

Hello!

For the last couple of days I've been trying really hard to solve the linear PDE

. Where R is a function R(t,q(t),p(t)) and H is the hamiltonian H=   .

(dH/dp= p and dH/dq= -2q-2), q and p depends on the time t, and I'm supposed to solve the PDE and then plot the gaussian distribution (2D).

I tried doing this:

pde := diff(R(t, q1(t), p1(t)), t) = -(diff(R(t, q(t), p(t)), q(t)))*p(t)+(diff(R(t, q(t), p(t)), p(t)))*(-2*q(t)-2)

But pdsolve(pde) gives me:  "Error, (in pdsolve/info) the name of the indeterminate function must be given".

When I change q(t) to q and p(t) to p I get:

R(t, q, p) = _F1(p^2-2*q^2-4*q, -(1/2)*ln(sqrt(2)*q+p+sqrt(2))*sqrt(2)+t)

And then I'm lost. How do I solve this PDE in maple?

Thankful for any help

## how to find roots of equation J...

how to find roots of equation J0(xR) = 0 ,R is constant, using maple? I know command for zeros of Bessel function i.e J0(x) = 0.  but what to do with different argument?

## How to export worksheet into word document using M...

Thank you very much !

## integrating differential forms...

I have

dZ(x)=−xdlog(z(x))

where d is the exterior derivative. I would like to recover the function Z(x) by integrating both sides of the equation. How would I compute this in Maple?

## KroneckerProduct() function not performing as it d...

I'm trying to compute the tensor product of two column vectors as

with(LinearAlgebra):

A:=Matrix([[1/sqrt(2)],[0],[0],[1/sqrt(2)]]);

KroneckerProduct(A,A);

And the output is a column vector with entries: "16 x 1 Matrix", "Data Type: Anything", "Storage: rectangular", "Order: Fortran_order"

The Maple documentation indicates that this function should output the result of the kronecker tensor product of the input matrices, and I've followed the same form as the examples in the documentation... Does anyone know why this isn't working as it should?

## What's indexed piecewise used for?...

The page ?type,piecewise shows the example

type(piecewise[](x < 1, a, b), 'piecewise');

and lines 4-8 of showstat(`print/piecewise`) deal with the case of an indexed piecewise. Yet I can find no other reference to indexed piecewise. What is it used for? When I put an index on a piecewise, nothing special seems to happen, either computationally or display-wise:

piecewise[abs](x > 0, x, -x);
piecewise[Carl](x > 0, x, -x);

The code in `print/piecewise` suggests that it serves some purpose.

## How do I save a matrix in an intermediate step of ...

I am working on an iterative code where I need to save a matrix in an intermediate step. My code is long and it uses a separate data file. So, I am trying to state my problem taking a simple example.

At first, I define a column matrix A0. Using A0, I do some calculations and test some conditions.
In the next step, I want  to do similar calculations and test some conditions but this time by changing the first element of A0. For the purpose of later use, I need to save the matrix A0 in its original form. I am trying to use the following method but both A0 and A1 (modified A0) turn out to be same.

> restart;
> n := 3;
> A0 := Matrix(n, 1, 1);
> #Do some calculation with A0
> A1 := A0;
> A1[1, 1] := A1[1, 1]+.1*A1[1, 1];
> A1;
> print(A0, A1);

This might be because I set A1:=A0 in the third line. But how do I save A0 in its original form?

## Solving with HPM...

Hi everyone. I'm going to solve a problem of an article with hpm. well I wrote some initial codes(I uploaded both codes and article). but now I face with a problem. I cant reach to the correct plot that is in the article. could you please help me???

(dont think I am lazy ;))) I found f and g (by make a system with A1 and B1 and solve it i found f[0] and g[0], with p^3 coefficient in A-->f[1] and then with B2 I foud g[1]) and their plot was correct. but the problem is theta and phi and their plots :(( )

Project.mw

2.pdf   this is article

 > restart;
 > lambda:=0.5;K[r]:=0.5;Sc:=0.5;Nb:=0.1;Nt:=0.1;Pr:=10;
 (1)
 > equ1:=diff(f(eta),eta\$4)-R*(diff(f(eta),eta)*diff(f(eta),eta\$2)-f(eta)*diff(f(eta),eta\$2))-2*K[r]*diff(g(eta),eta)=0; equ2:=diff(g(eta),eta\$2)-R*(diff(f(eta),eta)*g(eta)-f(eta)*diff(g(eta),eta))+2*K[r]*diff(f(eta),eta)=0; equ3:=diff(theta(eta),eta\$2)+Pr*R*f(eta)*diff(theta(eta),eta)+Nb*diff(phi(eta),eta)*diff(theta(eta),eta)+Nt*diff(theta(eta),eta)^2=0; equ4:=diff(phi(eta),eta\$2)+R*Sc*f(eta)*diff(phi(eta),eta)+diff(theta(eta),eta\$2)*(Nt/Nb)=0;
 (2)
 > ics:= f(0)=0,D(f)(0)=1,g(0)=0,theta(0)=1,phi(0)=1; f(1)=lambda,D(f)(1)=0,g(1)=0,theta(1)=0,phi(1)=0;
 (3)
 > hpm1:=(1-p)*(diff(f(eta),eta\$4)-2*K[r]*diff(g(eta),eta))+p*(diff(f(eta),eta\$4)-R*(diff(f(eta),eta)*diff(f(eta),eta\$2)-f(eta)*diff(f(eta),eta\$2))-2*K[r]*diff(g(eta),eta))=0; hpm2:=(1-p)*(diff(g(eta),eta\$2)+2*K[r]*diff(f(eta),eta))+p*(diff(g(eta),eta\$2)-R*(diff(f(eta),eta)*g(eta)-f(eta)*diff(g(eta),eta))+2*K[r]*diff(f(eta),eta))=0; hpm3:=(1-p)*(diff(theta(eta),eta\$2))+p*(diff(theta(eta),eta\$2)+Pr*R*f(eta)*diff(theta(eta),eta)+Nb*diff(phi(eta),eta)*diff(theta(eta),eta)+Nt*diff(theta(eta),eta)^2)=0; hpm4:=(1-p)*(diff(phi(eta),eta\$2)+diff(theta(eta),eta\$2)*(Nt/Nb))+p*(diff(phi(eta),eta\$2)+R*Sc*f(eta)*diff(phi(eta),eta)+diff(theta(eta),eta\$2)*(Nt/Nb))=0;
 (4)
 > f(eta)=sum(f[i](eta)*p^i,i=0..1);
 (5)
 > g(eta)=sum(g[i](eta)*p^i,i=0..1);
 (6)
 > theta(eta)=sum(theta[i](eta)*p^i,i=0..1);
 (7)
 > phi(eta)=sum(phi[i](eta)*p^i,i=0..1);
 (8)
 > A:=collect(expand(subs(f(eta)=f[0](eta)+f[1](eta)*p,g(eta)=g[0](eta)+g[1](eta)*p,hpm1)),p);
 (9)
 > A1:=diff(f[0](eta),eta\$4)-2*K[r]*(diff(g[0](eta),eta))=0; A2:=diff(f[1](eta),eta\$4)-2*K[r]*(diff(g[1](eta),eta))-R*(diff(f[0](eta),eta))*(diff(f[0](eta),eta\$2))+R*f[0](eta)*(diff(f[0](eta),eta\$2))=0;
 (10)
 > icsA1:=f[0](0)=0,D(f[0])(0)=1,g[0](0)=0,f[0](1)=lambda,D(f[0])(1)=0,g[0](1)=0; icsA2:=f[1](0)=0,D(f[1])(0)=0,g[1](0)=0,f[1](1)=0,D(f[1])(1)=0,g[1](1)=0;
 (11)
 > B:=collect(expand(subs(f(eta)=f[0](eta)+f[1](eta)*p,g(eta)=g[0](eta)+g[1](eta)*p,hpm2)),p);
 (12)
 > B1:=diff(g[0](eta),eta\$2)+2*K[r]*(diff(f[0](eta),eta))=0; B2:=diff(g[1](eta),eta\$2)+2*K[r]*(diff(f[1](eta),eta))-R*(diff(f[0](eta),eta))*g[0](eta)+R*f[0](eta)*(diff(g[0](eta),eta))=0;
 (13)
 > icsB1:=f[0](0)=0,D(f[0])(0)=1,g[0](0)=0,f[0](1)=lambda,D(f[0])(1)=0,g[0](1)=0; icsB2:=f[1](0)=0,D(f[1])(0)=0,g[1](0)=0,f[1](1)=0,D(f[1])(1)=0,g[1](1)=0;
 (14)
 > C:=collect(expand(subs(theta(eta)=theta[0](eta)+theta[1](eta)*p,phi(eta)=phi[0](eta)+phi[1](eta)*p,f(eta)=f[0](eta)+f[1](eta)*p,hpm3)),p);
 (15)
 > C1:=diff(theta[0](eta),eta\$2)=0; C2:=diff(theta[1](eta), eta, eta)+Pr*R*f[0](eta)*(diff(theta[0](eta), eta))+Nb*(diff(phi[0](eta), eta))*(diff(theta[0](eta), eta))+Nt*(diff(theta[0](eta), eta))^2=0;
 (16)
 > icsC1:=theta[0](0)=1,theta[0](1)=0; icsC2:=f[0](0)=0,D(f[0])(0)=1,f[1](1)=0,D(f[1])(1)=0,theta[1](0)=0,theta[1](1)=0,phi[0](0)=0,phi[0](1)=0;
 (17)
 > E:=collect(expand(subs(theta(eta)=theta[0](eta)+theta[1](eta)*p,phi(eta)=phi[0](eta)+phi[1](eta)*p,f(eta)=f[0](eta)+f[1](eta)*p,hpm4)),p);
 (18)
 > E1:=diff(phi[0](eta),eta\$2)+Nt*(diff(theta[0](eta),eta\$2))/Nb=0; E2:=diff(phi[1](eta),eta\$2)+Nt*(diff(theta[1](eta),eta\$2))/Nb+R*Sc*f[0](eta)*(diff(phi[0](eta),eta))=0;
 (19)
 > icsE1:=phi[0](0)=1,phi[0](1)=0; icsE2:=f[0](0)=0,D(f[0])(0)=1,f[1](1)=0,D(f[1])(1)=0,theta[1](0)=0,theta[1](1)=0,phi[1](0)=0,phi[1](1)=0;
 (20)
 >

Project.mw

## Sum vs expanded form...

N:=3;

sum1 := lcm(N, 0)+lcm(N, 1)+lcm(N, 2)+lcm(N, 3);

sum2 := sum(lcm(N, k), k = 0 .. N);

Why is sum2 wrong?

Regards,

 1 2 3 4 5 6 7 Last Page 1 of 36
﻿