Hi!
I have an external library with this function:
```
double test(double x)
{
return sin(x);
}
```

In Maple I am doing this:
**test := define_external('test', x::(float[8]), RETURN::(float[8]), LIB = "Test.dylib");
f := x->test(x);
**
Now when I call f(2) for example, I get 0.909297426825681710 back.
But if I try this:
**plot(f(y), y = 0 .. 2);**
I get this error message:
`Error, (in f) invalid input: test expects its 1st argument, x, to be of type numeric, but received y`

I think I need to somehow convert the (possible) symbolic input of f into a float[8] before it is passed to the procedure test, but I can't figure it out.

Dear All,
Does anybody know how to plot a surface in 3d with only those points which satisfy a constraint?
In particular I'm plotting the surface defined by the equation F(beta,Omega,delta)=0 using implicitplot3d. Unfortunately, I want to command Maple to leave out any points which violate the inequality h(beta,Omega)>0.
Does anybody know how to do this?
cmichael

Dear Sir or Madam,
There is a maple code below for finding all paths between two given pair of vertices. Is there any maple code available for finding all minimal cut sets ( i.e., components whose failure will results in a network failure) between any given pair of vertices?
For example, a bridge network:
>with(networks):
>G:=graph({1,2,3,4},{{1,2},{1,3},{2,3},{2,4},{3,4}}):
Question:
Find all cuts between node 1 and node 4.
Doing it by hand, I got: [{1,2},{1,3}],[{2,4},{3,4}],[{1,2},{2,3},{3,4}],[{1,3},{3,2},{2,4}].
It is not easy to enumerate all cut sets by hand when the network is large. How do I code it in Maple??

Hello,
I have expressions of the form

`e[i,j,k]:= s*U(s)*a(s,y,z,t)+ s*(s+1)^2*b(s,y,z,t)+ ...`

where `e` is a symmetric array, i=1..4, j=1..4, k=1..4
and function a(s,y,z,t),b(s,y,z,t),c(s,y,z,t),f(y,z,t),g(s,y,z,t),... and their partial derivatives are appearing in these expressions
I exracted different coeff, named them,
and then I wanted to rewrite each e[i,j,k] while substituting coeffs with implicit function, so I've used `applyrule` in a procedure but not all coeffs are substituted.
Can anyone help please.
Here is my worksheet

View 4780_beny1.mw on MapleNet or

Download 4780_beny1.mwView file details
Hello!

I use Maple 9 for some weeks and it helps me a lot. In the last days I have 2 problems that I could not implement in Maple. I spent many hours reading manuals, tips etc. without finding an idea, so I decided to post here my questions:

I use dsolve (numeric) to solve a system of ODEs. I receive the solution "p" wich I can plot whithout problems.

Question 1

----------

After this, I define a new function "S" as:

S := t -> p(t)[2] + p(t)[3] + p(t)[4] + p(t)[5];

I tried to plot it with

e:=1.5;

interface(plotoutput="sum.ps");

plot(S, 1..e);

but I receive the message

I am trying to import data from Excel and re-create the scatterplot that is on the Excel spreadsheet. The first column contains the Y data. The second column contains the X data. I can import and browse the array of data but I cannot create a scatter plot of the data. I want to fit a function to the data and overlay this function on the graph to visually see how well the fit is.
Thanks.

Hello,
I would like to know how i could manipulate the output that i receive from the solve/fsolve commands:
sample code:
> for n from 1 to 10 by 1 do
> fsolve({x+y=n+6,x*y=10},{x,y})
> end do;
{y = 2.000000000, x = 5.000000000}
{y = 1.550510257, x = 6.449489743}
{x = 7.701562119, y = 1.298437881}
{x = 8.872983346, y = 1.127016654}
{y = 1.000000000, x = 10.00000000}
{y = 0.9009804864, x = 11.09901951}
{y = 0.8210916542, x = 12.17890835}
{x = 13.24499800, y = 0.7550020016}

Does anyone know how to do commutative matrix multiplication ?
I'm doing a worksheet with the classic worksheet of Maple 10.
To clarify further, I just want to multiply corresponding elements of two square matrices, NOT multiply the matrices using the proper rules of matrix multiplication.
respectfully,
Dan

We hav a version of Maple 8 which is still running on our department machines which is currently running a version of RedHat Enterprise Linux 3 or 4. At home I've been using Fedora Core. I managed to keep Maple 8 running up to Fedora Core 3. To do so, I had to relink libc.so.6 in /usr/local/maple8/bin.IBM_INTEL_LINUX to a copy of libc.so I copied from a department machine. I've now installed Fedora Core 6, and that arrangment doesn't work. maple gives the error message
/usr/local/maple8/bin.IBM_INTEL_LINUX/cmaple: relocation error: /usr/local/maple8/bin.IBM_INTEL_LINUX/libc.so.6: symbol _dl_out_of_memory, version GLIBC_PRIVATE not defined in file ld-linux.so.2 with link time reference

Hi,
First of all, I'm quite new to Maple and here, so I hope you will be patient with me..ehhehe.
I've been struggling some days creating abstract vectorial equations with no luck.
The equations have vectorial components as well as a matrix, it is the equation of motion, i.e:
Inertia * dw/dt + w x Inertia.w = T
Inertia is a matrix that I dont want to define now, and most of all I dont want to spread out its components, so it has to be all the time "Inertia".
w is a angular speed vector and T is the Torque vector.
Neither I want w to be defined or component separated (wx,wy,wz) at this point since I need to work with w for some change of coordinates .i.e w = w1 + ww1 . So I need to work in this abstract level.

The default dot density for exported GIF files is 96 dpi - necessary for screen display but not optimal for printing. Is there anywhere, internal or external to Maple 11, to monkey with the resolution to suit me? (Obviously, I can export GIF and then "alter" resolution in a third party package, but, hopefully obviously as well, this doesn't help as it is very lossy. I need to save the vector content directly to, say, a 200 dpi GIF image).
Also, wmf and eps format exportations are not good options for me either, as these two file export formats fail to reproduce the graph I see on my Maple document: layering gets scrambled, transparency settings are ignored or altered, etc.

Hello,
I have a question and really appreciate for any input:
- I define an exponential distribution function called f(t)
- Then, I define RP2(t) as a piecewise function of random variable t and some constant parameters.
- I would like to parametrically derive Expected value of RP2. I can easily derive it on paper, given exponential distribution of f(t).
- However, in Maple 10 as its file has been attached, I get the piecewise results without any simplification. Even simplify command yields the same results. I don’t know what I am missing.
Any input is highly appreciated.
Best regards,

Hi.. been using maple v.10 for a few days now.. I created a maple sheet for newton's method of approximation.

The aim was to find F(x) = 0, my final value for Xo was −1.509410457

I wanted to know, how to create a situation where Xo is continuously replaced with Xnew until Xo = Xnew.

Here's my code:

> restart;

> Xo:=-2;

> F(x):=(Xo^5) + 3*((Xo)^2)+1;

> dFx:=5*((Xo)^4) + 6*(Xo);

>

>

Xo := -2

F(x) := -19

dFx := 68

> Xnew:=Xo - ((F(x))/dFx);

.............-117

Xnew := ----

Hello, I am trying to solve this PDE using the Method of Lines and so I turn it into N ODEs. The following is how I plan on solving it;
p1:=proc(N,x,Y,YP)
FD:=proc(i,N,Y)
if (i=1) then "use this stencil (like (Y[1] - Y[2]) / 60*dx);
elif (i=2) then "another stencil";
...
...
else "last, general stencil";
end if;
end proc;
SD:=proc(i,N,Y)

I have done a lot of experimenting since my post of 13 hours ago and now have a better handle on the print problem. I am using an HP2110 printer. When I try to print out a document OR work sheet that I originated on maple, I click on file, select print, and on the resulting pop-up menu select properties. There are now 4 choices for print quality: Best, Normal, Everyday, and Fast Draft. If I select "Every Day" the print out will have letters (and graphs) that are twice the size that they should be. Then if I do the same exact thing, without changing anything except selecting one of the other print quality choices, the resulting print out is normal.