## How do I define a polynomial with an arbitrary num...

Right now I am going through Bishop's ML book and as a part of the first exercise I need to define a polynomial that goes like this.

y(x,w) = w_0 + w_1 * x + w_2 * x^2 ... + w_m * x^m = sum (k=0 to m) w_k * x^k

Here is how I've written it out in Maple.

f := proc (x, w) options operator, arrow; sum(w[k]*x^k, k = 0 .. nops(w)) end proc

Sorry for the raw code, Maple Math won't accept the code I've written as a valid Maple expression for some reason. When I try to use this I get an error that says too many levels of recursion.

f(2, [a, b, c]);
Error, (in limit/mrv/limsimpl) too many levels of recursion

Where am I going wrong here?

## problem with Programming...

i cant understand the idea of how maple works with parameters...

if u watch it exactly u can see that first maple understands that diff(a__1,t) is equall 1; but anfter that it couldnt load the value 1.
why?

what is hapening?

what can i do for this problem. its not the main code. i just send u an example of what  i want and what maple does. plz help me. tnx

Hi,

When multiple request to DocumentTools:-Tabulate(...) are enclosed in the same group of commands (which typically happens when they are within a procedure), only the last one is displayed.
Is it possible to overcome this behaviour?

## How to change the style of vertex of graph to pol...

Hello, everyone: I have a question of drawing graph。
restart:
with(GraphTheory):
with(SpecialGraphs):
H := HypercubeGraph(3):
DrawGraph(H,
style = spring);

How  do I change  the vertex style   to polygon without line.
the aim graph  like figure below:

Thank you very much!

## How to plot gyroid surface by Maple...

Greeting for all

, How to plot gyroid surface by Maple where its equation is

Amr

## How expand in perturbation series in maple?...

I have the following ODE perturbation problem which I want maple to solve for me:

q'(\tau)=f(p(eps*\tau)+eps*q(\tau),r(eps*\tau)+s(\tau))-f(p(eps*\tau,r(eps*\tau)+s(\tau))-f(p(eps*\tau),r(eps*\tau))

where q(\tau)=q_0(\tau)+eps*q_1(\tau)

p(eps*\tau)=p_0(eps*\tau)+eps*p_1(eps*\tau)

s(\tau)=s_0(\tau)+eps*s_1(\tau)

r(eps*\tau)=r_0(eps*\tau)+eps*r_1(eps*\tau)

I want maple to expand every function that depends on eps in its arguments by a Taylor series around eps=0, i.e h(eps)=h(0)+eps*h'(0)

and also expand the difference above the fs with an eps-expansion around eps=0.

I did all this manually now I want to check if my calculations are correct, eventaully I want to equate same powers of eps of the RHS and LHS of the first ODE I wrote above.

Then how to use maple for this?

Thnaks.

## residual standard error command?...

Does there exist a Maple command that on its own calculates the residual standard error of two regression lists?

## Need help on this ...

Given the following functions, graph them and identify relative and absolute extrema (if any).

f(x)=3x^3-2x^2+5x-7     [-3,6]

## Doing some Substitution ...

How I can do ?

Thank you.

Substitution of . 5,6,7) into Eqs. 1–(4), gives the new equation as functions of the generalized coordinates,
u_m,n(t);  v_m,n ( t), and w_m,n ( t). These expressions are then inserted in the Lagrange equations (see Eq. 8)) a set of N second-order coupled ordinary differential equations with both quadratic   and cubic nonlinearities.

In Eq (8) q are generalized coordinate such as uvw  and .

\where the elements of the vector, are the time-dependent generalized coordinates.

 >
 (1)
 >
 (2)
 >
 (3)
 >
 (4)
 >
 (5)
 >
 (6)
 >
 (7)
 >
 (8)
 >

## How to calculate Vector[row] y2 using spline fit F...

Hi,

I was able to determine a cubic spline fit, F(v), to x1 and y1. Now I have vector x2 which I would like to use F(v) to calculate y2 as another Vector[row]. I am having trouble accomplishing this task. Any help is greatly appreciated. Thanks.

x1 := Vector[row]([0.8e-1, .28, .48, .68, .88, 1, 1.2, 1.4, 1.6, 1.8, 2, 2.2, 2.4, 2.6, 2.8, 3, 3.2, 3.4, 3.6, 3.8, 4, 4.2]);

y1 := Vector[row]([-10.081, -10.054, -10.018, -9.982, -9.939, -9.911, -9.861, -9.8, -9.734, -9.659, -9.601, -9.509, -9.4, -9.293, -9.183, -9.057, -8.931, -8.806, -8.676, -8.542, -8.405, -8.265]);

m := ArrayTools[Dimensions](x1);

maxx := rhs(m[1]);

F := proc (v) options operator, arrow; CurveFitting:-Spline(x1, y1, v, degree = 3) end proc;

x2 := Vector[row]([seq(log10(2*10^x1[k]), k = 1 .. maxx)])

y2:=?

Pts1 := plot(x1, y1, style = point, symbol = diamond, gridlines = true, color = red);

plt_sp := plot(F(v), v = x1[1] .. x1[maxx], color = blue);

plots:-display(Pts1, plt_sp)

## Why am I getting this strange result when calculat...

In Maple 2018, I was playing around with some sums of infinite series, and I came across a result that made me wonder if Maple was perhaps using some other definition or understanding of the sum of a series in its calculation. Take a look at the screenshot linked below:

https://ibb.co/hMdkQHn

That first series is most certainly divergent since the limit as n approaches infinity of n^2/(n+1) is not equal to 0. And just to confirm my own sanity, I even checked some of the partial sums of the series, which sure enough are diverging. And yet for the infinite sum, Maple is giving this finite result.

I even checked a more familiar alternating series, the alternating harmonic series, which Maple does correctly calculate to be ln(2).

What am I missing here? Is Maple using a different definition for the sum of the series than the limit of the partial sums as n approaches infinity? Or is there a mistake with how I've written something that I'm not noticing?

## algebraic equations...

 >
 >
 (1)
 >
 (2)
 >
 (3)
 >

How can I find A and B explicitly

## Derivative and Differentiability ...

Using the definition of a derivative as a limit i.e., lim h->0  f(x+h)-f(x)/h  .Find the derivative of the following functions:

a) f(x)=3x^3-2x^2+5x-7

## Plot graph from array...

Hi, I've created an array from a do loop, where the number in the array is the number of degrees for which I've calculated the answer, I now wish to graph the angle against the value in the array. i.e. the value a[50]=156.21 should graph to the point (50,156.21). Ideally as well I'd like for it to be joined up by a smooth curve of best fit, but I'll take what I can get, I can't seem to figure out how to plot it at all at the moment.

See code below:

restart;

for i from 50 by 5 to 85 do
ThetaBn := (1/180)*i*Pi;
s := cos(2*ThetaBn)*x+(2*sin(ThetaBn)*sin(ThetaBn))*sin(x);
a[i] := 180.0*fsolve(s = 0, x, 1 .. 6)*(1/Pi)
end do;

Thanks