MaplePrimes Questions

Hello, 

I am doing a regression analysis, but some of my model says: Warning, model is not of full rank. Can anyone help what to do with that? 

Rok := Vector([2013, 2014, 2015, 2016, 2017, 2018], datatype = float);

TrzbyCelkemEmco := Vector([1028155, 1134120, 1004758, 929584, 995716, 1152042], datatype = float);

KubickaTrzby = Statistics:-PolynomialFit(3, Rok, TrzbyCelkemEmco, x);


 

 

Thank you :)  

 

 

 

Hello.

Is there a way to make maple sum variables with a index definition?

I want to sum this

`X__1`:=4.83

`X__2`:=4.33

`X__3`:=4.66

sum(X[i], i = 1 .. 3)

But it result with X[1] + X[2] + X[3] instead of 13.81

 

Hi,

Is there anyway to solve this equation for x(t) analytically in Maple?

m * diff(diff(x(t),t), t) = - m * A * sin(2*pi*f*t) - piecewise( abs(x) < x__max, 0, abs(x) >= x__max, -k*(abs(x)-x__max)*Sgn(x)) - diff(x(t), t);

m, x_max, f, A, and k are constant parameters.

Thanks,

Baharm31

 

In the help file the permitted declartions for the second argument of the Escape command from the StringTools package are html,regexp and xml, to not specify one, which as far as I can tell instructs maple to take all characters as plain text with no escape characters.

Is this the complete list of options for the form when using the escape command?

Or is it possible to custom build escape rules?

 

Sorry to bother you with another very basic question.

This very simple example shows that Maple gives the first value that is defined back, ignoring changes further down the definition chain.

Could someone explain why, and if there is a way to always get the updated values?


 

m := Matrix(2, 2, {(1, 1) = 1, (1, 2) = 3, (2, 1) = 2, (2, 2) = 4})

Matrix(%id = 18446745932232999750)

(1)

a := 1

1

(2)

b := m[a, 1]

1

(3)

a := 2

2

(4)

b

1

(5)

m[2, 1]

2

(6)

``


 

Download VariableIndex.mw

Hi,

I've been trying to replicate an example described in a book called "Quantum Mechanics Using Maple" by M. Horbatsch, but at the end, when I'm using fsolve it returns 0. instead .500 .

I'm using Maple 18, but I think this book was written using Maple V. I don't know if the syntax changes are causing this. I'm very new to maple. Here's my worksheet (qm_maple_-_periodic_potentials.mw) and book section (qm_maple_periodic.pdf). Thanks in advance!

I try to use phaseportrait to get the phase portrait of the following ode system, why it does not give the plot or the error reminding?


 

with(LinearAlgebra)

phaseportrait([diff(x(t), t) = -((y(t)^2*x(t)+x(t)^3+y(t)-x(t))*sqrt((y(t)^2+x(t)^2)/x(t)^2)-2*x(t))*x(t)/sqrt(y(t)^2+x(t)^2), diff(y(t), t) = -x(t)*((y(t)^3+y(t)*x(t)^2-y(t)-x(t))*sqrt((y(t)^2+x(t)^2)/x(t)^2)-2*y(t))/sqrt(y(t)^2+x(t)^2)], [x(t), y(t)], t = 0 .. 50, [[x(0) = -1, y(0) = -1], [x(0) = -5, y(0) = -5]], x = -10 .. 20, y = -10 .. 30, dirgrid = [40, 40], stepsize = 0.1e-2, numframes = 90, axes = BOXED, linecolor = black)

phaseportrait([diff(x(t), t) = -((y(t)^2*x(t)+x(t)^3+y(t)-x(t))*((y(t)^2+x(t)^2)/x(t)^2)^(1/2)-2*x(t))*x(t)/(y(t)^2+x(t)^2)^(1/2), diff(y(t), t) = -x(t)*((y(t)^3+y(t)*x(t)^2-y(t)-x(t))*((y(t)^2+x(t)^2)/x(t)^2)^(1/2)-2*y(t))/(y(t)^2+x(t)^2)^(1/2)], [x(t), y(t)], t = 0 .. 50, [[x(0) = -1, y(0) = -1], [x(0) = -5, y(0) = -5]], x = -10 .. 20, y = -10 .. 30, dirgrid = [40, 40], stepsize = 0.1e-2, numframes = 90, axes = BOXED, linecolor = black)

(1)

``

``


 

Download m40.mw

 

I was wondering if there was any way to reassign the "||" operator to calculate parallel resistors?

like this:

R1 || R2 = (1/R1+1/R2)^(-1)

 

solve it by Maple , get the following form solution, what's the Int(1,0)

 


 

restart;

 

ODE :=diff(r(t),t)=r(t)*(1-r(t)^2)+mu*r(t)*cos(t)

diff(r(t), t) = r(t)*(1-r(t)^2)+mu*r(t)*cos(t)

(1)

dsolve(ODE)

r(t) = ((_C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t)))*exp(2*t+2*mu*sin(t)))^(1/2)/(_C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t))), r(t) = -((_C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t)))*exp(2*t+2*mu*sin(t)))^(1/2)/(_C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t)))

(2)

g := unapply(sqrt((C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t)))*exp(2*t+2*mu*sin(t)))/(C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t))), t)

proc (t) options operator, arrow; ((C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t)))*exp(2*t+2*mu*sin(t)))^(1/2)/(C1+2*(Int((exp(t))^2*(exp(mu*sin(t)))^2, t))) end proc

(3)

g(0)

1/(C1+2*(Int(1, 0)))^(1/2)

(4)

``


 

Download m39.mw
 

How can I  get the  phase portrait  and several trajectory of the following system(it is in polar coordinates )

r'=r(1 − r^2) + 2rcos(θ),

θ' = 1

 

I'm working along in Maple 2019 and then all of a sudden it freezes.  Anyone else have this?

Maple 2018 and earlier displayed an Array like this

In Maple 2019 I get this

How do I display Arrays in Maple 2019 like Maple 2018?

Why when I read a file in (image file - specifically a TIFF file) and then write the exact same file back out, it makes a file 30% larger.  Should it not be the same size??

Trying to solve this integral here. 

restart;
with(Statistics);

X := RandomVariable(Normal(10, mu));
                            X := _R
dummy := int(PDF(X, mu), r = -infinity .. 500);
                         /   /           2\\         
                         |   |  (mu - 10) ||         
                         |exp|- ----------||         
                         |   |        2   ||         
                         |   \    2 mu    /|         
          dummy := signum|-----------------| infinity
                         \       mu        /         
solve(dummy = 0.05);
 

What am I missing? Any ideas ? :)

Please excuse this newbie question - but any idea what's wrong with this procedure?

I also wonder how text indent and formatting is done in Maple? Are there any tricks, or is it just doing formatting that it look good.

Last thing - what's the best procedure to post questions like this? Is it just attaching a short code example in original Maple file, or do I copy & paste as text?


 

Warning, premature end of input, use <Shift> + <Enter> to avoid this message.

 

assign('`f__t,90,k`', Property(Class, "f_t,90,k"));
       assign('`f__c,0,k`', Property(Class, "f_c,0,k"));
     assign('`f__c,90,k`', Property(Class, "f_c,90,k"));
     assign('`f__v,k`', Property(Class, "f_v,k"));
     assign('`f__r,k`', Property(Class, "f_r,k"));
     assign('`E__0,mean`', Property(Class, "E_0,mean"));
     assign('`E__0,05`', Property(Class, "E_0,05"));
     assign('`E__90,mean`', Property(Class, "E_90,mean"));
     assign('`E__90,0,05`', Property(Class, "E_90,0,05"));
     assign('`G__mean`', Property(Class, "G_mean"));
     assign('`G__0,05`', Property(Class, "G_0,05"));
     assign('`G__r,mean`', Property(Class, "G_r,mean"));
     assign('`G__r,0,05`', Property(Class, "G_r,0,05"));
     assign('`rho__k`', Property(Class, "rho_k"));
     assign('`rho__mean`', Property(Class, "rho_mean"))

Error, reserved word `end` unexpected

 

``


 

Download proc.mw

First 582 583 584 585 586 587 588 Last Page 584 of 2428