## 509 Reputation

12 years, 28 days

## assign...

Because assume and additionally, the variable a changed.

You can do like this:

expr1:=sqrt(a);

expr2:=sqrt(a);

subs(a=2,expr1); #gives correct answer of sqrt(2)

assign(a=2);

expr2;

## One way...

One way

h:=[seq(2*i,i=1..10)];

Or

restart: for i from 1 to 10 do u[i]:=2*i; end do;h:=[seq(u[i],i=1..10)];

## Perhaps like this: for i from 1 to nops...

Perhaps like this:

for i from 1 to nops(t1) do
u[i]:=t1[i];

res[i]:=residue(f(s),s=u[i]);
end do;

## Digits:=2...

restart:Digits;

10

10.0/50.0;

0.2000000000

Digits:=2:10.0/50.0;

0.20

## An opinion...

The points which you have do not represent a curve and points are in very desordre (pointplot).
You can may be delete some points (in accordance whith your physical measure) and then do the polynomial interpolation or other interpolation.

With those points, it's not possible to get any correct interpolation (also Spline). I think.

## Interpolation...

For the first points, you can modify just the last digit of 3.43799 as:

points:=[[2.612499,16.24096],[3.437498,14.21687],[3.437499,11.22891],[3.437497,8.192769],[4.262496,6.361444],[5.224999,7.662649]];

h := PolynomialInterpolation(points, x);

I you want to do the interpolation without modifying your data, you can use:

BSplineCurve(points,x);

The second points, you should modify the list as:

points := [[0, 1], [1, 2], [3, -7], [4, -3]];

i := PolynomialInterpolation(points, x)

## A way...

restart:Sys:=[sin(x) = 0.5, 0 < x, x < 10]:a:=solve(Sys,[x],allsolutions, explicit=true);

sol:=[seq(rhs(a[i][1]),i=1..nops(a))];

## pointplot...

restart:with(plots):

a := t->(-1)*.12*t^4+12*t^3-380*t^2+4100*t+220;
v := t->(-1)*.48*t^3+36*t^2-760*t+4100;

A:=<seq(a(t),t=1..48)>;

V:=<seq(v(t),t=1..48)>;

t := <seq(1 .. 48)>;

pointplot(t,A,color = red, symbol = circle, symbolsize = 15);

pointplot(t,V,color = red, symbol = circle, symbolsize = 15);

## singular matrix...

Your Matrix A is singular and then has not an Inverse

Determinant(A);

0

## diff(eta[i](x),x)...

f:=unapply(diff(eta[i](x),x)=k[i]*e[i], i);

## A way...

You can do like this

implicitplot([op(myEqns), y+x=0], x=-10..10, y=-10..10, colour=[red,red, red, red, red,blue]);

or

p1:=implicitplot([op(myEqns)], x=-10..10, y=-10..10, colour=red):

p2:=implicitplot([y+x=0], x=-10..10, y=-10..10,colour=blue):

display(p1,p2);

## Variables...

Change x* to xx, y* to yy, etc..

Maple don't accept x* to be a variable

## Some details...

You have nonzero elements, you store those elements non-zero in a vector

A[1000000] for exemple, each nonzero element it situation in the matrix gm defined by it position in a colon and a line. stor those position in jcol[10000000] and iline[1000000]. and write those maple programe to reconstituate the matrix and solve it

s:={(iline[i],jcol[i])=A[i],(iline[i+1],icol[i+1])=A[i+1]}:   # for example or with  do

M := Matrix(55000,55000,s,storage=sparse);

LinearSolve(M, t, method='SparseDirect');   # t is a second member of the system

## FixedPointIteration...

Thanks, This give solution

FixedPointIteration(fixedpointiterator=g(x), x=.2, tolerance=10^(-2));

## Storing in Vectors...

The same problem exist in other laguage (Matlab, fortran, etc...)

You should store your matrice in vectors where maple can store more bytes

restart: Vector(1000000);

 2 3 4 5 6 7 8 Page 4 of 9
﻿