Items tagged with argument argument Tagged Items Feed

Hello,

Im solving 4 ODE equations with BC. im trying to shoot the initial value but im having this error:

""Error, (in isolate) cannot isolate for a function when it appears with different arguments""

anyone could help me???

shooting92.mw

``

restart

Shootlib := "E:\\shooting/":

libname := Shootlib, libname:

with(Shoot):

with(plots):

n := 2:

FNS := {F(eta), H(eta), f(eta), g(eta), u(eta), v(eta)}:

ODE := {g(eta)*(diff(g(eta), eta))+B*(f(eta)+g(eta)) = 0, g(eta)*(diff(F(eta), eta))+F(eta)^2+B*(F(eta)-u(eta)) = 0, g(eta)*(diff(H(eta), eta))+H(eta)*(diff(g(eta), eta))+F(eta)*H(eta) = 0, diff(v(eta), eta)+f(eta)*v(eta)-u(eta)^2+B*H(eta)*(F(eta)-u(eta))-M*u(eta) = 0, diff(f(eta), eta) = u(eta), diff(u(eta), eta) = v(eta)};

{g(eta)*(diff(H(eta), eta))+H(eta)*(diff(g(eta), eta))+F(eta)*H(eta) = 0, g(eta)*(diff(g(eta), eta))+0.2e-1*f(eta)+0.2e-1*g(eta) = 0, g(eta)*(diff(F(eta), eta))+F(eta)^2+0.2e-1*F(eta)-0.2e-1*u(eta) = 0, diff(v(eta), eta)+f(eta)*v(eta)-u(eta)^2+0.2e-1*H(eta)*(F(eta)-u(eta))-3*u(eta) = 0, diff(f(eta), eta) = u(eta), diff(u(eta), eta) = v(eta)}

(1)

IC := {F(0) = gamma, H(0) = Q, f(0) = 0, g(0) = z, u(0) = 1, v(0) = alpha};

{F(0) = gamma, H(0) = Q, f(0) = 0, g(0) = z, u(0) = 1, v(0) = alpha}

(2)

BC := {F(L) = 0, H(L) = n, g(L) = -f(L), u(L) = 0};

{F(6) = 0, H(6) = 2, g(6) = -f(6), u(6) = 0}

(3)

infolevel[shoot] := 1:

S := shoot(ODE, IC, BC, FNS, [alpha = 0, gamma = 0, z = -.2, Q = 0])

Error, (in isolate) cannot isolate for a function when it appears with different arguments

 

``

``


Download shooting92.mw

How do I use msolve to solve y^2 + y - 11=0 in Zp for all primes p with 41=< p =<107 ?

Also, using the results make a conjecture describing the primes p for which there are solutions to y^2 + y - 11 = 0 in Zp

This was what I did.

41<=p<=107

msolve(y^2 + y - 11=0, p)

but I received this error, no implementation of msolve matches the arguments in call, msolve(y^2 + y - 11=0, p)

Any help is appreciated. Thanks

Dear friends:

I have a long expression having a/some RootOf(something..) inside it. 

Any way to get just that "something..", i.e., the argument of RootOf() from that expression?

 

Thank you very much.

César Lozada

 

 

I'm attempting to plot several solutions of this differential equation (I have uploaded my worksheet). I have used this series of commands before without issue, but for some reason I keep getting the error message: "Error, (in plot) incorrect first argument" ect.. Does anyone have any insight into what might be going wrong? Thank you.

Download ass_1_#9.mw

ass_1_#9.mw

Hi there!

I want to improve the way I code up my procedures. For instance I want to code them safe in the sense that they only accept the arguments when they have the correct type.

I know that in principle this is done with the double-colon operator in the following way:

proc(argument::argumenttype)::valuetype;

 

(Q1)Now, given that my argument is of a type such as set, list, Array, etc.:

(a) How would I specify the allowed types of the elements of that list (for all elements, and for specific ones)? And if the element of the list is a list again, how would I specify the type of that's elements? and so forth..

(b) How would I specify the allowed size of the listArray, etc. ?

 

(Q2) How do I specify the types of more than one output, if my proc returns more than one value?

 

(Q3) I know that there are special integer types, such as nonnegint, posint, negint. Is there also a way to specify that the ineger (or float) argument has to be greater than some given value, e.g. >2, or that it has to lie between two values, or out of a given set?

 

Thats all for now. Thanks for your help guys! : )

Gernot

I am trying to solve the following integral

beta^alpha*x^(alpha-1)*exp(-beta*x)/((1+x)*GAMMA(alpha)) 

with respect to x, between zero and infinity.

If i just integrate it the result that I obtain is

(alpha^2*beta^(alpha+1)*exp(beta)*GAMMA(-alpha-1, beta)+alpha*beta^(alpha+1)*exp(beta)*GAMMA(-alpha-1, beta)+beta-alpha)/beta

My problem is that the alpha is positive and consequently the GAMMA functions do not exist, since the argument...

I'd like to be able to get a quicker low accuracy computation of the argument of the complex-valued JacobiTheta1 function.

I only need as much accuracy as to get a decent plot, which means... I don't know... about 1e-3 relative accuracy?

If I can get a formula or approach that is "evalhf'able" then I can construct a procedure which does this action and writes results inplace to a float[8] Matrix.

The naive approach in the code below takes about 6min...

Hello. I am creating a custom component similar to the one that maplesoft has as an example (the discretized counterflow heat exchanger), but with some diff. The problem is that when i execute dyamic systems i get an error saying:

Error, (in DynamicSystems:-ParseSystemInputs) cannot match the arguments to an appropriate system

Is this a problem on my equation (something that i may have forget) or is another thing? Are the arguments type of dynamic system in the right "type"?

I have written a procedure to overload a new "Subs" function. It uses a seq of equations as its first argument followed by the object to act upon (yes, it is to have subs functionality on these objects). I find the overloading works when I have just one equation in the argument list, but with more than one it never calls any of the procedures. The code worked with multiple equations before I overloaded it (i.e. the first proc was verified by itself). FWIW the objects (elemt or bm...

Hi all. I am trying to find the cube roots of -sqrt(6)-sqrt(18)*I in polar form. I have used the following commands but it does not convert the argument properly. Can anyone help? readlib(polar); sola:=solve(z^3=-sqrt(6)-sqrt(18)*I,z); polar(sola[1]); polar(sola[2]); polar(sola[3]); I have also used the following but it could not simplify the argument/angle. sola1 := simplify(convert(sola[1], polar)); Can anyone please suggest a fix to this? The argument...

I have a module which is an argument to a procedure.

When I "trace" this procedure, the entire module is  printed (as it should).

Is there a way to NOT print the contents of the passed module? It is annoying when debugging.

 

Paul 

I simplified the real task and

the principal problem is how to assign a condition( if x < 3 then t := 0 elif x >= 3 then t := 5 end if) to a variable t which depends on x (x is a argument of function g(x))?

Is it possible at all without writing the procedure?

Here is the code:

g := proc (x) options operator, arrow; 2*x+t end proc; if x < 3 then t := 0 elif x >= 3 then t := 5 end if; plot(g(x))

i am successfully transforming a 2D plot, when doing the exact analog thing to a 3D plot i get the error message 

Error, (in t) invalid input: unknown uses a 3rd argument, z, which is missing

 

i have no idea what's going on, please advise.

 

i made a minimum example:

this works:

> restart:with(plots):with(plottools):
> norm2:=x->x[1]^2+x[2]^2:
> N:=[0,1]:
> phi:=(x,y)->N+2*([x,y]-N)/norm2([x,y]-N):

Find the principal arguments of the 5 roots of the polynomial:p(z)=z^5-5*z^4-5*z-5,and enter a decimal approximation to the largest principal argument in the box below.  Your approximation should be correct to 10 significant figures

 

Can some one tell me how to write in maple?correct answer is 2.691121659

 

Page 1 of 1