Maple 13 Questions and Posts

These are Posts and Questions associated with the product, Maple 13

I am trying to solve system of differential equation as shown in file attached. The differentail eqaution has peicewise function for t=8*n and t not equal to 8*n where n is a positive integer. but i am getting error. please help.

 

 

problem30.mw

Hello everyone! I have just started to using Maple 13. I want to solve complex eauation systems.

When I am working on Maple, If I write simple mathematical calculation and then press right click, the context menu open. However, I want to use solve command. Therefore I wrote an eauation after than press right click the context menu will not open. 

What is the reason of this problem? 

Integral is not evaluated. 

 

PROBLE_13.mw

please I need the code to calculate the convergence order of a multipoint iterative method to solve nonlinear equation systems.

 

my email is: yjmsigma@gmail.com

 

In the first one I used hypergeometric function where the number is converged. Now using the series expansion of hypergeometric function I rewrite the equation as in the 2nd and 3rd case. But here it is not converging. I expect the same answer as in the first case i.e 0.14042. Thank you

 

problem2.mw

In the following problem at two example are given. For Z=2 the sum is converging whereas at Z=4 it is not converging. Thank you

 

PROBLEM.mw

any one can help me to get the output of the plot in 3 rows and 2 columns here is my codes. thanks in advance.

 restart;
  h:=z->1-(delta2/2)*(1 + cos(2*(Pi/L1)*(z - d1 - L1))):
  K1:=((4/h(z)^4)-(sin(alpha)/Gamma2)-h(z)^2+Nb*h(z)^4):
  lambda:=unapply(Int(K1,z=0..1), Gamma2):
  L1:=0.2:
  d1:=0.2:
  alpha:=Pi/6:
  with(plots):
  display
  ( Vector[row]
    ( [ seq
        ( plot
          ( [ seq
              ( eval(lambda(Gamma2), Nb=j),
                j in [0.1,0.2,0.3]
              )
            ],
            delta2=0.02..0.1,
            legend=[Nb=0.1,Nb=0.2,Nb=0.3],
            labels=[typeset(`δ1`), typeset(conjugate(`Δp`))],
            title=typeset("Effect of ", ''alpha'', " when ", Gamma,"2=", Gamma2)
          ),
          Gamma2 in [10,20,30,40,50,-10]
        )
      ]
    )
  );
 

Hellow ,

any body can help me to remove the error from the plot, here is my codes .

Note. 1. *Title {Effect of alpha when 'Gamma2'=Gamma2}

2. *on the y axis i want  bar(deltap)

 

 

 

restart;

 

 

h:=z->1-(delta2/2)*(1 + cos(2*(Pi/L1)*(z - d1 - L1))):
K1:=((4/h(z)^4)-(sin(alpha)/Gamma2)-h(z)^2+Nb*h(z)^4):
lambda:=unapply(Int(K1,z=0..1), Gamma2):
L1:=0.2:
d1:=0.2:
alpha:=Pi/6:
plots:-display(Vector[row]([seq(plot([seq(eval(lambda(Gamma2), Nb=j), j=[0.1,0.2,0.3])], delta2=0.02..0.1, legend=[Nb=0.1,Nb=0.2,Nb=0.3],labels = ["d1 ", "Dp"],labelfont = ["SYMBOL", 12], title=(Effect of alpha when 'Gamma2'=Gamma2)), Gamma2=[10,20,30])]),axes=boxed);
 

how to adjust the height and width of plot in maple 13

plot( x[3]^5, caption = typeset("\n A plot of %1.", x[3]^5), captionfont=[times, 20] );

hellow,

can any body help me to  increase the size of the caption in maple plot

plot( x[3]^5, caption = typeset("A plot of %1.", x[3]^5) );

I want to fetch the trigger time.
I use rhs function.
 

restart; ode := diff(y(x), x) = 1/(y(x)+1); event := [[abs(y(x)+1)-0.1e-1, halt]]

SOL := dsolve([ode, y(0) = 0], numeric, output = listprocedure, range = -10 .. 10, events = event):

Warning, cannot evaluate the solution further left of -.49995006, event #1 triggered a halt

 

``

tlast := rhs(SOL[1](last));

10.

(1)

NULL

x = proc (x) local _res, _dat, _solnproc, _xout, _ndsol, _pars, _i; option `Copyright (c) 2000 by Waterloo Maple Inc. All rights reserved.`; if 1 < nargs then error "invalid input: too many arguments" end if; _EnvDSNumericSaveDigits := Digits; Digits := 15; if _EnvInFsolve = true then _xout := evalf[_EnvDSNumericSaveDigits](x) else _xout := evalf(x) end if; _dat := eval(`dsolve/numeric/data/modules`[1]); _solnproc := _dat:-Get("soln_procedure"); _pars := map(rhs, _dat:-Get("params")); if not type(_xout, 'numeric') then if member(x, ["start", 'start', "method", 'method', "left", 'left', "right", 'right', "leftdata", "rightdata", "enginedata", "eventstop", 'eventstop', "eventclear", 'eventclear', "eventstatus", 'eventstatus', "laxtol", 'laxtol', "numfun", 'numfun', NULL]) then _res := _solnproc(convert(x, 'string')); if 1 < nops([_res]) then return _res elif type(_res, 'array') then return eval(_res, 1) elif _res <> "procname" then return _res end if elif member(x, ["last", 'last', "initial", 'initial', NULL]) then _res := _solnproc(convert(x, 'string')); if type(_res, 'list') then return _res[1] else return NULL end if elif member(x, ["parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(x, 'string'); _res := _solnproc(_xout); if _xout = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[1], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["initial", 'initial', "parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(lhs(x), 'string') = rhs(x); if lhs(_xout) = "initial" then if type(rhs(_xout), 'list') then _res := _solnproc(_xout) else _res := _solnproc("initial" = ["single", 1, rhs(_xout)]) end if elif not type(rhs(_xout), 'list') then error "initial and/or parameter values must be specified in a list" elif lhs(_xout) = "initial_and_parameters" and nops(rhs(_xout)) = nops(_pars)+1 then _res := _solnproc(lhs(_xout) = ["single", 1, op(rhs(_xout))]) else _res := _solnproc(_xout) end if; if lhs(_xout) = "initial" then return _res[1] elif lhs(_xout) = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[1], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["eventdisable", 'eventdisable', "eventenable", 'eventenable', "eventfired", 'eventfired', "direction", 'direction', NULL]) then return _solnproc(convert(lhs(x), 'string') = rhs(x)) elif _xout = "solnprocedure" then return eval(_solnproc) elif _xout = "sysvars" then return _dat:-Get("sysvars") end if; if procname <> unknown then return ('procname')(x) else _ndsol := `tools/gensym`("x"); eval(FromInert(_Inert_FUNCTION(_Inert_NAME("assign"), _Inert_EXPSEQ(ToInert(_ndsol), _Inert_VERBATIM(pointto(_dat:-Get("soln_procedures")[1])))))); return FromInert(_Inert_FUNCTION(ToInert(_ndsol), _Inert_EXPSEQ(ToInert(x)))) end if end if; try _res := _solnproc(_xout); _res[1] catch: error  end try end proc

(2)

``


 

Download RHS_TEST.mw


 

restart

`ode&lambda;` := diff(lambda(tau), tau, tau)+2*a*Ep(tau)*(diff(lambda(tau), tau))/(Xi(tau)*a+1) = 0:

th := algsubs((diff(lambda(tau), tau))^2 = (-1-(diff(xi(tau), tau))^2)/(-(xi(tau)*a+1)^2), `ode&xi;`):

a*(diff(xi(tau), tau))^2/(xi(tau)*a+1)+diff(diff(xi(tau), tau), tau)+a/(xi(tau)*a+1) = 0

 

a*(diff(xi(tau), tau))^2/(xi(tau)*a+1)+diff(diff(xi(tau), tau), tau)-a/(xi(tau)*a+1) = 0

(1)

ds2 := -(xi(tau)*a+1)^2*(diff(lambda(tau), tau))^2+(diff(xi(tau), tau))^2:

`&lambda;p1` := 1:

`ics&lambda;1` := lambda(0) = 0, (D(lambda))(0) = `&lambda;p1`:

xi(0) = (-1+2^(1/2))/a, (D(xi))(0) = 1

 

xi(0) = 1/a, (D(xi))(0) = 2

(2)

`lp&xi;1` := dsolve([`ode&xi;1`, `ics&xi;1`], numeric, output = listprocedure, range = teu .. te, events = event1); Xi := eval(xi(tau), `lp&xi;1`); `&Xi;p` := eval(diff(xi(tau), tau), `lp&xi;1`); `ode&lambda;`; `lp&lambda;1` := dsolve([`ode&lambda;`, `ics&lambda;1`], numeric, output = listprocedure, range = teu .. te, events = event1)

diff(diff(lambda(tau), tau), tau)+.6*Ep(tau)*(diff(lambda(tau), tau))/(.3*Xi(tau)+1) = 0

 

Error, (in dsolve/numeric/DAE/make_proc) number of unknown functions and equations must match, got 3 functions {Ep, Xi, lambda}, and 1 equations

 

`lp&xi;1`(1)

[tau(1) = 1., (xi(tau))(1) = 2.20293901854199481, (diff(xi(tau), tau))(1) = .670856526448510904]

(3)

`&lambda;ep1` := eval(diff(lambda(tau), tau), lp1); `&xi;ep1` := eval(diff(xi(tau), tau), lp1); `&lambda;e1` := eval(lambda(tau), lp1); `&xi;e1` := eval(xi(tau), lp1)

proc (tau) local _res, _dat, _solnproc, _xout, _ndsol, _pars, _i; option `Copyright (c) 2000 by Waterloo Maple Inc. All rights reserved.`; if 1 < nargs then error "invalid input: too many arguments" end if; _EnvDSNumericSaveDigits := Digits; Digits := 15; if _EnvInFsolve = true then _xout := evalf[_EnvDSNumericSaveDigits](tau) else _xout := evalf(tau) end if; _dat := eval(`dsolve/numeric/data/modules`[1]); _solnproc := _dat:-Get("soln_procedure"); _pars := map(rhs, _dat:-Get("params")); if not type(_xout, 'numeric') then if member(tau, ["start", 'start', "method", 'method', "left", 'left', "right", 'right', "leftdata", "rightdata", "enginedata", "eventstop", 'eventstop', "eventclear", 'eventclear', "eventstatus", 'eventstatus', "laxtol", 'laxtol', "numfun", 'numfun', NULL]) then _res := _solnproc(convert(tau, 'string')); if 1 < nops([_res]) then return _res elif type(_res, 'array') then return eval(_res, 1) elif _res <> "procname" then return _res end if elif member(tau, ["last", 'last', "initial", 'initial', NULL]) then _res := _solnproc(convert(tau, 'string')); if type(_res, 'list') then return _res[4] else return NULL end if elif member(tau, ["parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(tau, 'string'); _res := _solnproc(_xout); if _xout = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[4], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["initial", 'initial', "parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(lhs(tau), 'string') = rhs(tau); if lhs(_xout) = "initial" then if type(rhs(_xout), 'list') then _res := _solnproc(_xout) else _res := _solnproc("initial" = ["single", 4, rhs(_xout)]) end if elif not type(rhs(_xout), 'list') then error "initial and/or parameter values must be specified in a list" elif lhs(_xout) = "initial_and_parameters" and nops(rhs(_xout)) = nops(_pars)+1 then _res := _solnproc(lhs(_xout) = ["single", 4, op(rhs(_xout))]) else _res := _solnproc(_xout) end if; if lhs(_xout) = "initial" then return _res[4] elif lhs(_xout) = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[4], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["eventdisable", 'eventdisable', "eventenable", 'eventenable', "eventfired", 'eventfired', "direction", 'direction', NULL]) then return _solnproc(convert(lhs(tau), 'string') = rhs(tau)) elif _xout = "solnprocedure" then return eval(_solnproc) elif _xout = "sysvars" then return _dat:-Get("sysvars") end if; if procname <> unknown then return ('procname')(tau) else _ndsol := `tools/gensym`("xi(tau)"); eval(FromInert(_Inert_FUNCTION(_Inert_NAME("assign"), _Inert_EXPSEQ(ToInert(_ndsol), _Inert_VERBATIM(pointto(_dat:-Get("soln_procedures")[4])))))); return FromInert(_Inert_FUNCTION(ToInert(_ndsol), _Inert_EXPSEQ(ToInert(tau)))) end if end if; try _res := _solnproc(_xout); _res[4] catch: error  end try end proc

(4)

`&lambda;ep2` := eval(diff(lambda(tau), tau), lp2); `&xi;ep2` := eval(diff(xi(tau), tau), lp2); `&lambda;e2` := eval(lambda(tau), lp2); `&xi;e2` := eval(xi(tau), lp2)

proc (tau) local _res, _dat, _solnproc, _xout, _ndsol, _pars, _i; option `Copyright (c) 2000 by Waterloo Maple Inc. All rights reserved.`; if 1 < nargs then error "invalid input: too many arguments" end if; _EnvDSNumericSaveDigits := Digits; Digits := 15; if _EnvInFsolve = true then _xout := evalf[_EnvDSNumericSaveDigits](tau) else _xout := evalf(tau) end if; _dat := eval(`dsolve/numeric/data/modules`[2]); _solnproc := _dat:-Get("soln_procedure"); _pars := map(rhs, _dat:-Get("params")); if not type(_xout, 'numeric') then if member(tau, ["start", 'start', "method", 'method', "left", 'left', "right", 'right', "leftdata", "rightdata", "enginedata", "eventstop", 'eventstop', "eventclear", 'eventclear', "eventstatus", 'eventstatus', "laxtol", 'laxtol', "numfun", 'numfun', NULL]) then _res := _solnproc(convert(tau, 'string')); if 1 < nops([_res]) then return _res elif type(_res, 'array') then return eval(_res, 1) elif _res <> "procname" then return _res end if elif member(tau, ["last", 'last', "initial", 'initial', NULL]) then _res := _solnproc(convert(tau, 'string')); if type(_res, 'list') then return _res[4] else return NULL end if elif member(tau, ["parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(tau, 'string'); _res := _solnproc(_xout); if _xout = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[4], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["initial", 'initial', "parameters", 'parameters', "initial_and_parameters", 'initial_and_parameters', NULL]) then _xout := convert(lhs(tau), 'string') = rhs(tau); if lhs(_xout) = "initial" then if type(rhs(_xout), 'list') then _res := _solnproc(_xout) else _res := _solnproc("initial" = ["single", 4, rhs(_xout)]) end if elif not type(rhs(_xout), 'list') then error "initial and/or parameter values must be specified in a list" elif lhs(_xout) = "initial_and_parameters" and nops(rhs(_xout)) = nops(_pars)+1 then _res := _solnproc(lhs(_xout) = ["single", 4, op(rhs(_xout))]) else _res := _solnproc(_xout) end if; if lhs(_xout) = "initial" then return _res[4] elif lhs(_xout) = "parameters" then return [seq(_pars[_i] = _res[_i], _i = 1 .. nops(_pars))] else return [_res[4], seq(_pars[_i] = [_res][2][_i], _i = 1 .. nops(_pars))] end if elif type(_xout, `=`) and member(lhs(_xout), ["eventdisable", 'eventdisable', "eventenable", 'eventenable', "eventfired", 'eventfired', "direction", 'direction', NULL]) then return _solnproc(convert(lhs(tau), 'string') = rhs(tau)) elif _xout = "solnprocedure" then return eval(_solnproc) elif _xout = "sysvars" then return _dat:-Get("sysvars") end if; if procname <> unknown then return ('procname')(tau) else _ndsol := `tools/gensym`("xi(tau)"); eval(FromInert(_Inert_FUNCTION(_Inert_NAME("assign"), _Inert_EXPSEQ(ToInert(_ndsol), _Inert_VERBATIM(pointto(_dat:-Get("soln_procedures")[4])))))); return FromInert(_Inert_FUNCTION(ToInert(_ndsol), _Inert_EXPSEQ(ToInert(tau)))) end if end if; try _res := _solnproc(_xout); _res[4] catch: error  end try end proc

(5)

ds2h1 := subs([lambda(tau) = `&lambda;e1`(tau), xi(tau) = `&xi;e1`(tau), diff(lambda(tau), tau) = `&lambda;ep1`(tau), diff(xi(tau), tau) = `&xi;ep1`(tau)], ds2); dse1 := unapply(ds2h1, tau); ds2h2 := subs([lambda(tau) = `&lambda;e2`(tau), xi(tau) = `&xi;e2`(tau), diff(lambda(tau), tau) = `&lambda;ep2`(tau), diff(xi(tau), tau) = `&xi;ep2`(tau)], ds2); dse2 := unapply(ds2h2, tau)

dse1(0); dse2(0)

-.999999999

 

1.000000000

(6)

``

t := proc (xi, lambda) options operator, arrow; (xi+1/a)*sinh(a*lambda) end proc; x := proc (xi, lambda) options operator, arrow; (xi+1/a)*cosh(a*lambda) end proc; xi0 := 1; teg := 7

1

 

7

(7)

p1 := plot([[x(xi0, `&lambda;e1`(tau)), t(xi0, `&lambda;e1`(tau)), tau = teu .. te]], legend = ['ds' = -1], color = ["red"]); p2 := plot([[t(xi0, `&lambda;e2`(tau)), x(xi0, `&lambda;e2`(tau)), tau = teu .. te]], legend = ['ds' = 1], color = ["blue"]); p3 := plot([[tau, tau, tau = -teg .. teg], [tau, -tau, tau = -teg .. teg]], color = ["black", "black"], legend = ['ds' = 0, 'ds' = 0])

with(plots); display([p1, p2, p3])

 

NULL

``


 

Download Rindler_simulation_v2.mw

 

Consider for instance the following equation:

Eq:=(a-4)*exp(4*x)+(b+1)*exp(2*x)+(c-2)=0

How can I list the coefficients of the exponential functions and also solve the equation for the constant parameters 

a, b, and c?

I tried 

[coeffs(collect(lhs(EQ), exp), exp)] =~ 0;

but it did not work. Thank you for your help.

1) How can i get the event time. This example 0.69313.

2) I don't want to see the Warning.How can i do it? 

 

Warning, cannot evaluate the solution further right of .69314729, event #1 triggered a halt

Why this event dose'nt work ?
S(t) is a state , a parameter
dsolve(...,numeric,events = [[[s(t), a*arcsinh(2/a) < s(t)], halt]]);

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