MaplePrimes Questions

Hi! I'm having doubts about the "automatic spacing" in maple. I would like to know two things:

1-can incorrect spacing ruin my code? (Ex by typing "spacebar" too many times )

2- i know that to type spacebar is obligatory after: proc()" "...end proc;    Is there any other situation in wich to use spacebar isn't optional? Thanks for your answers

In the positive range Maple confirms that this is true.
In the real range Maple fails to provide an answer (see attachments).

Is this identity correct?

restart

kernelopts(version)

`Maple 2022.0, X86 64 WINDOWS, Mar 8 2022, Build ID 1599809`

(1)

NULL

is(arctan(-x) = -arctan(x))

true

(2)

`assuming`([is(arctan(x, y) = -arctan(-x, y))], [x::real, y::real])

FAIL

(3)

`assuming`([is(arctan(x, y) = -arctan(-x, y))], [x::positive, y::positive])

true

(4)

`assuming`([simplify(arctan(-x, y)+arctan(x, y), trig)], [x::real, y::real])

arctan(-x, y)+arctan(x, y)

(5)

But

plot3d([arctan(-x, y)+arctan(x, y)], x = -1000000 .. 1000000, y = -1000000 .. 1000000, title = arctan(-x, y)+arctan(x, y))

 

On a unit circle

x = cos(alpha), y = sin(alpha)

x = cos(alpha), y = sin(alpha)

(6)

subs(x = cos(alpha), y = sin(alpha), arctan(-x, y)+arctan(x, y))

arctan(-cos(alpha), sin(alpha))+arctan(cos(alpha), sin(alpha))

(7)

`assuming`([simplify(%)], [alpha::real])

arctan(-cos(alpha), sin(alpha))+arctan(cos(alpha), sin(alpha))

(8)

`assuming`([simplify(%)], [alpha::positive])

arctan(-cos(alpha), sin(alpha))+arctan(cos(alpha), sin(alpha))

(9)

`assuming`([simplify(%)], [-Pi < alpha and alpha < Pi])

arctan(-cos(alpha), sin(alpha))+arctan(cos(alpha), sin(alpha))

(10)

plot(arctan(-cos(alpha), sin(alpha))+arctan(cos(alpha), sin(alpha)), alpha = -2*Pi .. 2*Pi, axes = boxed, color = red)

 

NULL


Download arctan_xy_simplify.mw

and another maybe related case where simplification does not work

arctan_xy_simplify_2.mw

I'm new to MapleSoft having just acquired MapleFlow 2022 and am making my way through the first few tutorials.
After a few hours I have started to accumulate some questions ...

First ... is the proper forum for Maple Flow 2022? I didn't see "Maple Flow" in the "Tags" so just checking.

Now my questions ...


I - Page Margins: Are their no Page Margins or Rulers?
When looking at print preview my content shows up split vertically with half on page-1 and half on page-2.
How do I easily keep up with what is on Page 1 and what is on Page 2, etc?

II - Draw Tool: Is it true that the  "Draw Tool" only appears when hovering over an imported image? That has been my experience.
In fact I wouldn't have known there was a draw tool except by accident ... after I had imported an image ... then wondered why the image tool appeared then disappeared ... discovering later it appeared when hovering the mouse over an image.
It would be very handy to be able to draw on the canvas without restricting it to drawing on an imported image ...
Is there a way to draw on the canvas without having to import an image ...
If not I guess one could import a blank image and then draw on that ... or what?

iii - Apps to Create Images: What applications do you use for creating images? I've experimented with PC Paint and Inkscape but wondered what image creation software you guys may use.

IV - SVG Files: Are there plans to be able to create or import and manipulate SVG files? (Like fromInkscape? That would be very handy.)

V - Adding Units:
I saw in the video "Introducing Maple Flow: A Freeform Whiteboard for Design Calculations" at minute 15:53 ...
That you can add Units by holding down CTL+Shift and then pressing U as in the example below ...
    Click on the Canvas
    Type 2
    Hold down Ctl+Shift then press U
    Overwrite the unit placeholder with "m"
    Type +
    Type 3
    Hold down Ctl+Shift then press U
    Overwrite the unit placeholder with "ft"
    Press =
    Press Enter, Tab, or the Arrow key
After numerous attempts, I was unable to get this to work ... is this a bug or am I doing something wrong?
(I was able to get units to work using other techniques noted in the examples that came with the program but the above method
would be useful ... if I could get the darn thing to work :-)


I'm excited about learning and using MapleFlow ... so thanks to any kind soul who has the patience to answer some questions for me along the way :-)

System: Windows 10 Pro 64-bit PC
 

Hello everyone,

I am trying to solve an equation using the "solve(...)" function but the coefficients of the equation are changing.

I am using the coefficients as list but the "solve(...)" function gives error: "Error, (in assuming) when calling 'Engine:-Dispatch'. Received: 'badly formed input to solve: not fully algebraic'"

I am attaching the Maple document.

 

However, what I want to achieve, is the solution for each value in the list.

Here is an easy example of what I am saying:

a=3*x+k where k=[list of values], a=[another list of values].

I want to find "x" for each pair of values (a,k) in the list.

 

Thank you !
 

``

``

LCC Resonant Converter - Frequency Finder

 

 

restart``

with(Student[Calculus1])

V__out := 50.0

`&omega;__line` := 2.0*Pi*50

t := [seq(0 .. 10*10^(-3), .1*10^(-3))]

theta := `&omega;__line`*t

v__line := 85*sqrt(2.0)*`~`[sin](theta)

m := 1

Q__s := 3.2*`~`[`^`](`~`[sin](theta), 2)

``

f__n := `assuming`([solve((1/120)*V__out = 1/sqrt((-m*x^2+m+1)^2+(Q__s*(x-1/x))^2), x, useassumptions)], [x::positive])

Error, (in assuming) when calling 'Engine:-Dispatch'. Received: 'badly formed input to solve: not fully algebraic'

 

``


 

Download LCC_gain_freqFinder.mwLCC_gain_freqFinder.mw

ds := DerivedSeries(PermutationGroup({[[2, 3, 5, 4]], [[1, 2, 3, 4, 5]]}))

will get a series group like:

How to get the group by the red line point out? Then I can use GroupOrder to get the order of it. I note GroupOrder[ds[2]] don't work

Hello, i want to do convert numbers to binary code 8 bytes and I want to sum the digits of each number 

For example first number is 0 i want to write 0 0 0 0 0 0 0 0 , sum=0, for 1= 0 0 0 0 0 0 0 1,  sum =1 for 7= 0 0 0 0 0 1 1 1 sum=3 etc.....
my code is this;

for i from 0 to 10 do;
> S(i):=convert(i,binary);
> end do;

and output is 

                              S(0) := 0
                              S(1) := 1
                              S(2) := 10
                            S(3) := 11
                            S(4):=100
                             S(5) := 101
                             S(6) := 110
                            S(7) := 111
                           S(8) := 1000
                             S(9) := 1001
                            S(10) := 1010
                and  Histogram(S(i));  doesnt work.                

I want to reverse a catenated expression (eg. xxtt ->x,x,t,t). I don't know the command to achieve this. Anyone with an idea please help

Thanks

Hey I’m trying to define a variable as the solution to a second order nonhomogeneous differential equation with an initial value problem.

I have tried the method below, but it doesn’t work.

N__1 := dsolve([diff(y(x), x, x) + 3*diff(y(x), x) + 2*y(x) = x^2 + 5, eval(y(x), x = 0) = 1, eval(diff(y(x), x), x = 0) = 1], y(x))

It kind of works it gives me the expression below

N__1 = y(x) = (3*exp(-2*x))/4 + 17/4 - (3*x)/2 + x^2/2 - 4*exp(-x)

But I need the expression for N__1 to define some initial values for N__2 and so on, what I have tried that doesn’t work is.

C := eval(N__1, x = 200)

N__2 := C   - Just because nothing much is happing on this interval

And it gives me the following expression for N2

N__2 := y(200) = (3*exp(-400))/4 + 78817/4 - 4*exp(-200)

I then make a piecewise function to make a function which I can plot, which use to work.                         

N := piecewise(0 <= x and x <= 200, N__1, 200 <= x and x <= 1000, eval(N__2, x = x - 200))

But when I’m trying to plot N maple gives me a warning message.

plot(N, x = 0 .. 1000)

Warning, expecting only range or variable x in expression piecewise ………………..  to be plotted but found name y.

If I define N__1 as the solution to the differential equation, then it works just fine.

N__1 := (3*exp(-2*x))/4 + 17/4 - (3*x)/2 + x^2/2 - 4*exp(-x)

But that I’m not interested in, because that will require a lot of copy paste all the time.

Thank you in advance.

how I can convert this maple code to Matlab ones?

1.mw
 

restart; t1 := time(); with(LinearAlgebra); J := readstat("Please enter integer number J: "); N1 := proc (x) options operator, arrow; piecewise(0 <= x and x <= 1, 1) end proc; N2 := proc (x) options operator, arrow; piecewise(0 <= x and x <= 1, x, 1 < x and x <= 2, 2-x) end proc; N := proc (J, k) options operator, arrow; unapply(N2(2^J*x-k), x) end proc; Phi := proc (J, k) options operator, arrow; evalf((N(J, k))(x))*N1(x) end proc; PhiJ := Vector[column](2^J+1); for k from -1 to 2^J-1 do PhiJ[k+2] := Phi(J, k) end do; P := Matrix(2^J+1, 2^J+1); Map2[proc (i, j) options operator, arrow; evalb(i-j = 1) end proc](proc (x, a) options operator, arrow; x end proc, 1/6, P, inplace); Map2[proc (i, j) options operator, arrow; evalb(j-i = 1) end proc](proc (x, a) options operator, arrow; x end proc, 1/6, P, inplace); Map2[proc (i, j) options operator, arrow; evalb(i = j) end proc](proc (x, a) options operator, arrow; x end proc, 2/3, P, inplace); P[1, 1] := 1/3; P[2^J+1, 2^J+1] := 1/3; P := 2^(-J)*P; E := Matrix(2^J+1, 2^J+1); Map2[proc (i, j) options operator, arrow; evalb(i-j = 1) end proc](proc (x, a) options operator, arrow; x end proc, 1/2, E, inplace); Map2[proc (i, j) options operator, arrow; evalb(j-i = 1) end proc](proc (x, a) options operator, arrow; x end proc, -1/2, E, inplace); E[1, 1] := -1/2; E[2^J+1, 2^J+1] := 1/2; DPhi := E.(1/P); X1 := Vector[column](2^J+1, symbol = x1); X2 := Vector[column](2^J+1, symbol = x2); U := Vector[column](2^J+1, symbol = u); JJ := (1/2)*U^%T.P.U; x1t := X1^%T.PhiJ; x2t := X2^%T.PhiJ; ut := U^%T.PhiJ; for i from 0 to 2^J do PhiJxJ[i+1] := apply(unapply(PhiJ, x), i/2^J) end do; for i to 2^J+1 do eq1[i] := (X1^%T.DPhi-X2^%T).PhiJxJ[i] = 0; eq2[i] := (X2^%T.DPhi-U^%T).PhiJxJ[i] = 0 end do; for i to 2^J+1 do eq3[i] := X1^%T.PhiJxJ[i]-.1, 0 end do; eq1[0] := eval(x1t, x = 0) = 0; eq2[0] := eval(x2t, x = 0)-1 = 0; eq1[2^J+2] := eval(x1t, x = 1) = 0; eq2[2^J+2] := eval(x2t, x = 1) = -1; eqq1 := {seq(eq1[i], i = 0*.2^J+2)}; eqq2 := {seq(eq2[i], i = 0.2^J+2)}; eqq3 := {seq(eq3[i], i = 1.2^J+1)}; eq := `union`(`union`(eqq1, eqq2), eqq3); with(Optimization); S := NLPSolve(JJ, eq); assign(S[2]); uexact := piecewise(0 <= x and x <= .3, (200/9)*x-20/3, .3 <= x and x <= .7, 0, .7 <= x and x <= 1, -(200/9)*x+140/9); x2exact := piecewise(0 <= x and x <= .3, (100/9)*x^2-(20/3)*x+1, .3 <= x and x <= .7, 0, .7 <= x and x <= 1, -(100/9)*x^2+(140/9)*x-49/9); x1exact := piecewise(0 <= x and x <= .3, (100/27)*x^3-(10/3)*x^2+x, .3 <= x and x <= .7, 1/10, .7 <= x and x <= 1, -(100/27)*x^3+(70/9)*x^2-(49/9)*x+37/27); plot([x1exact, x1t], x = 0 .. 1, style = [line, point], legend = ["Exact", "Approximate"], axis = [gridlines = [colour = green, majorlines = 2]], labels = ["t", x[1](t)], labeldirections = ["horizontal", "vertical"])

t1 := 38.500

 

[`&x`, Add, Adjoint, BackwardSubstitute, BandMatrix, Basis, BezoutMatrix, BidiagonalForm, BilinearForm, CARE, CharacteristicMatrix, CharacteristicPolynomial, Column, ColumnDimension, ColumnOperation, ColumnSpace, CompanionMatrix, CompressedSparseForm, ConditionNumber, ConstantMatrix, ConstantVector, Copy, CreatePermutation, CrossProduct, DARE, DeleteColumn, DeleteRow, Determinant, Diagonal, DiagonalMatrix, Dimension, Dimensions, DotProduct, EigenConditionNumbers, Eigenvalues, Eigenvectors, Equal, ForwardSubstitute, FrobeniusForm, FromCompressedSparseForm, FromSplitForm, GaussianElimination, GenerateEquations, GenerateMatrix, Generic, GetResultDataType, GetResultShape, GivensRotationMatrix, GramSchmidt, HankelMatrix, HermiteForm, HermitianTranspose, HessenbergForm, HilbertMatrix, HouseholderMatrix, IdentityMatrix, IntersectionBasis, IsDefinite, IsOrthogonal, IsSimilar, IsUnitary, JordanBlockMatrix, JordanForm, KroneckerProduct, LA_Main, LUDecomposition, LeastSquares, LinearSolve, LyapunovSolve, Map, Map2, MatrixAdd, MatrixExponential, MatrixFunction, MatrixInverse, MatrixMatrixMultiply, MatrixNorm, MatrixPower, MatrixScalarMultiply, MatrixVectorMultiply, MinimalPolynomial, Minor, Modular, Multiply, NoUserValue, Norm, Normalize, NullSpace, OuterProductMatrix, Permanent, Pivot, PopovForm, ProjectionMatrix, QRDecomposition, RandomMatrix, RandomVector, Rank, RationalCanonicalForm, ReducedRowEchelonForm, Row, RowDimension, RowOperation, RowSpace, ScalarMatrix, ScalarMultiply, ScalarVector, SchurForm, SingularValues, SmithForm, SplitForm, StronglyConnectedBlocks, SubMatrix, SubVector, SumBasis, SylvesterMatrix, SylvesterSolve, ToeplitzMatrix, Trace, Transpose, TridiagonalForm, UnitVector, VandermondeMatrix, VectorAdd, VectorAngle, VectorMatrixMultiply, VectorNorm, VectorScalarMultiply, ZeroMatrix, ZeroVector, Zip]

 

J := 4

 

N1 := proc (x) options operator, arrow; piecewise(0 <= x and x <= 1, 1) end proc

 

N2 := proc (x) options operator, arrow; piecewise(0 <= x and x <= 1, x, 1 < x and x <= 2, 2-x) end proc

 

N := proc (J, k) options operator, arrow; unapply(N2(2^J*x-k), x) end proc

 

Phi := proc (J, k) options operator, arrow; evalf((N(J, k))(x))*N1(x) end proc

 

_rtable[36893490566539206892]

 

PhiJ[1] := piecewise(16.*x <= 0. and 0. <= 16.*x+1., 16.*x+1., 0. < 16.*x and 16.*x <= 1., 1.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[2] := piecewise(0. <= 16.*x and 16.*x <= 1., 16.*x, 1. < 16.*x and 16.*x <= 2., 2.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[3] := piecewise(`and`(0. <= 16.*x-1., 16.*x <= 2.), 16.*x-1., `and`(0. < 16.*x-2., 16.*x <= 3.), 3.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[4] := piecewise(`and`(0. <= 16.*x-2., 16.*x <= 3.), 16.*x-2., `and`(0. < 16.*x-3., 16.*x <= 4.), 4.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[5] := piecewise(`and`(0. <= 16.*x-3., 16.*x <= 4.), 16.*x-3., `and`(0. < 16.*x-4., 16.*x <= 5.), 5.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[6] := piecewise(`and`(0. <= 16.*x-4., 16.*x <= 5.), 16.*x-4., `and`(0. < 16.*x-5., 16.*x <= 6.), 6.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[7] := piecewise(`and`(0. <= 16.*x-5., 16.*x <= 6.), 16.*x-5., `and`(0. < 16.*x-6., 16.*x <= 7.), 7.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[8] := piecewise(`and`(0. <= 16.*x-6., 16.*x <= 7.), 16.*x-6., `and`(0. < 16.*x-7., 16.*x <= 8.), 8.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[9] := piecewise(`and`(0. <= 16.*x-7., 16.*x <= 8.), 16.*x-7., `and`(0. < 16.*x-8., 16.*x <= 9.), 9.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[10] := piecewise(`and`(0. <= 16.*x-8., 16.*x <= 9.), 16.*x-8., `and`(0. < 16.*x-9., 16.*x <= 10.), 10.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[11] := piecewise(`and`(0. <= 16.*x-9., 16.*x <= 10.), 16.*x-9., `and`(0. < 16.*x-10., 16.*x <= 11.), 11.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[12] := piecewise(`and`(0. <= 16.*x-10., 16.*x <= 11.), 16.*x-10., `and`(0. < 16.*x-11., 16.*x <= 12.), 12.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[13] := piecewise(`and`(0. <= 16.*x-11., 16.*x <= 12.), 16.*x-11., `and`(0. < 16.*x-12., 16.*x <= 13.), 13.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[14] := piecewise(`and`(0. <= 16.*x-12., 16.*x <= 13.), 16.*x-12., `and`(0. < 16.*x-13., 16.*x <= 14.), 14.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[15] := piecewise(`and`(0. <= 16.*x-13., 16.*x <= 14.), 16.*x-13., `and`(0. < 16.*x-14., 16.*x <= 15.), 15.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[16] := piecewise(`and`(0. <= 16.*x-14., 16.*x <= 15.), 16.*x-14., `and`(0. < 16.*x-15., 16.*x <= 16.), 16.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

PhiJ[17] := piecewise(`and`(0. <= 16.*x-15., 16.*x <= 16.), 16.*x-15., `and`(0. < 16.*x-16., 16.*x <= 17.), 17.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

_rtable[36893490566536466172]

 

_rtable[36893490566536466172]

 

_rtable[36893490566536466172]

 

_rtable[36893490566536466172]

 

P[1, 1] := 1/3

 

P[17, 17] := 1/3

 

_rtable[36893490566563670004]

 

_rtable[36893490566563682652]

 

_rtable[36893490566563682652]

 

_rtable[36893490566563682652]

 

E[1, 1] := -1/2

 

E[17, 17] := 1/2

 

_rtable[36893490566592433196]

 

_rtable[36893490566592446084]

 

_rtable[36893490566592458492]

 

_rtable[36893490566592462708]

 

JJ := ((1/96)*u[1]+(1/192)*u[2])*u[1]+((1/192)*u[1]+(1/48)*u[2]+(1/192)*u[3])*u[2]+((1/192)*u[2]+(1/48)*u[3]+(1/192)*u[4])*u[3]+((1/192)*u[3]+(1/48)*u[4]+(1/192)*u[5])*u[4]+((1/192)*u[4]+(1/48)*u[5]+(1/192)*u[6])*u[5]+((1/192)*u[5]+(1/48)*u[6]+(1/192)*u[7])*u[6]+((1/192)*u[6]+(1/48)*u[7]+(1/192)*u[8])*u[7]+((1/192)*u[7]+(1/48)*u[8]+(1/192)*u[9])*u[8]+((1/192)*u[8]+(1/48)*u[9]+(1/192)*u[10])*u[9]+((1/192)*u[9]+(1/48)*u[10]+(1/192)*u[11])*u[10]+((1/192)*u[10]+(1/48)*u[11]+(1/192)*u[12])*u[11]+((1/192)*u[11]+(1/48)*u[12]+(1/192)*u[13])*u[12]+((1/192)*u[12]+(1/48)*u[13]+(1/192)*u[14])*u[13]+((1/192)*u[13]+(1/48)*u[14]+(1/192)*u[15])*u[14]+((1/192)*u[14]+(1/48)*u[15]+(1/192)*u[16])*u[15]+((1/192)*u[15]+(1/48)*u[16]+(1/192)*u[17])*u[16]+((1/192)*u[16]+(1/96)*u[17])*u[17]

 

x1t := x1[1]*piecewise(16.*x <= 0. and 0. <= 16.*x+1., 16.*x+1., 0. < 16.*x and 16.*x <= 1., 1.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[2]*piecewise(0. <= 16.*x and 16.*x <= 1., 16.*x, 1. < 16.*x and 16.*x <= 2., 2.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[3]*piecewise(`and`(0. <= 16.*x-1., 16.*x <= 2.), 16.*x-1., `and`(0. < 16.*x-2., 16.*x <= 3.), 3.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[4]*piecewise(`and`(0. <= 16.*x-2., 16.*x <= 3.), 16.*x-2., `and`(0. < 16.*x-3., 16.*x <= 4.), 4.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[5]*piecewise(`and`(0. <= 16.*x-3., 16.*x <= 4.), 16.*x-3., `and`(0. < 16.*x-4., 16.*x <= 5.), 5.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[6]*piecewise(`and`(0. <= 16.*x-4., 16.*x <= 5.), 16.*x-4., `and`(0. < 16.*x-5., 16.*x <= 6.), 6.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[7]*piecewise(`and`(0. <= 16.*x-5., 16.*x <= 6.), 16.*x-5., `and`(0. < 16.*x-6., 16.*x <= 7.), 7.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[8]*piecewise(`and`(0. <= 16.*x-6., 16.*x <= 7.), 16.*x-6., `and`(0. < 16.*x-7., 16.*x <= 8.), 8.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[9]*piecewise(`and`(0. <= 16.*x-7., 16.*x <= 8.), 16.*x-7., `and`(0. < 16.*x-8., 16.*x <= 9.), 9.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[10]*piecewise(`and`(0. <= 16.*x-8., 16.*x <= 9.), 16.*x-8., `and`(0. < 16.*x-9., 16.*x <= 10.), 10.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[11]*piecewise(`and`(0. <= 16.*x-9., 16.*x <= 10.), 16.*x-9., `and`(0. < 16.*x-10., 16.*x <= 11.), 11.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[12]*piecewise(`and`(0. <= 16.*x-10., 16.*x <= 11.), 16.*x-10., `and`(0. < 16.*x-11., 16.*x <= 12.), 12.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[13]*piecewise(`and`(0. <= 16.*x-11., 16.*x <= 12.), 16.*x-11., `and`(0. < 16.*x-12., 16.*x <= 13.), 13.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[14]*piecewise(`and`(0. <= 16.*x-12., 16.*x <= 13.), 16.*x-12., `and`(0. < 16.*x-13., 16.*x <= 14.), 14.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[15]*piecewise(`and`(0. <= 16.*x-13., 16.*x <= 14.), 16.*x-13., `and`(0. < 16.*x-14., 16.*x <= 15.), 15.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[16]*piecewise(`and`(0. <= 16.*x-14., 16.*x <= 15.), 16.*x-14., `and`(0. < 16.*x-15., 16.*x <= 16.), 16.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x1[17]*piecewise(`and`(0. <= 16.*x-15., 16.*x <= 16.), 16.*x-15., `and`(0. < 16.*x-16., 16.*x <= 17.), 17.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

x2t := x2[1]*piecewise(16.*x <= 0. and 0. <= 16.*x+1., 16.*x+1., 0. < 16.*x and 16.*x <= 1., 1.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[2]*piecewise(0. <= 16.*x and 16.*x <= 1., 16.*x, 1. < 16.*x and 16.*x <= 2., 2.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[3]*piecewise(`and`(0. <= 16.*x-1., 16.*x <= 2.), 16.*x-1., `and`(0. < 16.*x-2., 16.*x <= 3.), 3.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[4]*piecewise(`and`(0. <= 16.*x-2., 16.*x <= 3.), 16.*x-2., `and`(0. < 16.*x-3., 16.*x <= 4.), 4.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[5]*piecewise(`and`(0. <= 16.*x-3., 16.*x <= 4.), 16.*x-3., `and`(0. < 16.*x-4., 16.*x <= 5.), 5.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[6]*piecewise(`and`(0. <= 16.*x-4., 16.*x <= 5.), 16.*x-4., `and`(0. < 16.*x-5., 16.*x <= 6.), 6.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[7]*piecewise(`and`(0. <= 16.*x-5., 16.*x <= 6.), 16.*x-5., `and`(0. < 16.*x-6., 16.*x <= 7.), 7.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[8]*piecewise(`and`(0. <= 16.*x-6., 16.*x <= 7.), 16.*x-6., `and`(0. < 16.*x-7., 16.*x <= 8.), 8.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[9]*piecewise(`and`(0. <= 16.*x-7., 16.*x <= 8.), 16.*x-7., `and`(0. < 16.*x-8., 16.*x <= 9.), 9.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[10]*piecewise(`and`(0. <= 16.*x-8., 16.*x <= 9.), 16.*x-8., `and`(0. < 16.*x-9., 16.*x <= 10.), 10.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[11]*piecewise(`and`(0. <= 16.*x-9., 16.*x <= 10.), 16.*x-9., `and`(0. < 16.*x-10., 16.*x <= 11.), 11.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[12]*piecewise(`and`(0. <= 16.*x-10., 16.*x <= 11.), 16.*x-10., `and`(0. < 16.*x-11., 16.*x <= 12.), 12.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[13]*piecewise(`and`(0. <= 16.*x-11., 16.*x <= 12.), 16.*x-11., `and`(0. < 16.*x-12., 16.*x <= 13.), 13.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[14]*piecewise(`and`(0. <= 16.*x-12., 16.*x <= 13.), 16.*x-12., `and`(0. < 16.*x-13., 16.*x <= 14.), 14.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[15]*piecewise(`and`(0. <= 16.*x-13., 16.*x <= 14.), 16.*x-13., `and`(0. < 16.*x-14., 16.*x <= 15.), 15.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[16]*piecewise(`and`(0. <= 16.*x-14., 16.*x <= 15.), 16.*x-14., `and`(0. < 16.*x-15., 16.*x <= 16.), 16.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+x2[17]*piecewise(`and`(0. <= 16.*x-15., 16.*x <= 16.), 16.*x-15., `and`(0. < 16.*x-16., 16.*x <= 17.), 17.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

ut := u[1]*piecewise(16.*x <= 0. and 0. <= 16.*x+1., 16.*x+1., 0. < 16.*x and 16.*x <= 1., 1.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[2]*piecewise(0. <= 16.*x and 16.*x <= 1., 16.*x, 1. < 16.*x and 16.*x <= 2., 2.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[3]*piecewise(`and`(0. <= 16.*x-1., 16.*x <= 2.), 16.*x-1., `and`(0. < 16.*x-2., 16.*x <= 3.), 3.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[4]*piecewise(`and`(0. <= 16.*x-2., 16.*x <= 3.), 16.*x-2., `and`(0. < 16.*x-3., 16.*x <= 4.), 4.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[5]*piecewise(`and`(0. <= 16.*x-3., 16.*x <= 4.), 16.*x-3., `and`(0. < 16.*x-4., 16.*x <= 5.), 5.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[6]*piecewise(`and`(0. <= 16.*x-4., 16.*x <= 5.), 16.*x-4., `and`(0. < 16.*x-5., 16.*x <= 6.), 6.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[7]*piecewise(`and`(0. <= 16.*x-5., 16.*x <= 6.), 16.*x-5., `and`(0. < 16.*x-6., 16.*x <= 7.), 7.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[8]*piecewise(`and`(0. <= 16.*x-6., 16.*x <= 7.), 16.*x-6., `and`(0. < 16.*x-7., 16.*x <= 8.), 8.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[9]*piecewise(`and`(0. <= 16.*x-7., 16.*x <= 8.), 16.*x-7., `and`(0. < 16.*x-8., 16.*x <= 9.), 9.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[10]*piecewise(`and`(0. <= 16.*x-8., 16.*x <= 9.), 16.*x-8., `and`(0. < 16.*x-9., 16.*x <= 10.), 10.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[11]*piecewise(`and`(0. <= 16.*x-9., 16.*x <= 10.), 16.*x-9., `and`(0. < 16.*x-10., 16.*x <= 11.), 11.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[12]*piecewise(`and`(0. <= 16.*x-10., 16.*x <= 11.), 16.*x-10., `and`(0. < 16.*x-11., 16.*x <= 12.), 12.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[13]*piecewise(`and`(0. <= 16.*x-11., 16.*x <= 12.), 16.*x-11., `and`(0. < 16.*x-12., 16.*x <= 13.), 13.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[14]*piecewise(`and`(0. <= 16.*x-12., 16.*x <= 13.), 16.*x-12., `and`(0. < 16.*x-13., 16.*x <= 14.), 14.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[15]*piecewise(`and`(0. <= 16.*x-13., 16.*x <= 14.), 16.*x-13., `and`(0. < 16.*x-14., 16.*x <= 15.), 15.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[16]*piecewise(`and`(0. <= 16.*x-14., 16.*x <= 15.), 16.*x-14., `and`(0. < 16.*x-15., 16.*x <= 16.), 16.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)+u[17]*piecewise(`and`(0. <= 16.*x-15., 16.*x <= 16.), 16.*x-15., `and`(0. < 16.*x-16., 16.*x <= 17.), 17.-16.*x)*piecewise(0 <= x and x <= 1, 1, 0)

 

_rtable[36893490566593511164]

 

_rtable[36893490566474385156]

 

_rtable[36893490566474387196]

 

_rtable[36893490566474274564]

 

_rtable[36893490566474276604]

 

_rtable[36893490566471927556]

 

_rtable[36893490566471929596]

 

_rtable[36893490566439466756]

 

_rtable[36893490566439468796]

 

_rtable[36893490566581483268]

 

_rtable[36893490566581485308]

 

_rtable[36893490566581487364]

 

_rtable[36893490566581489404]

 

_rtable[36893490566581491460]

 

_rtable[36893490566581493500]

 

_rtable[36893490566581561092]

 

_rtable[36893490566581563132]

 

eq1[1] := -20.28718708*x1[1]+25.72312247*x1[2]-6.892489894*x1[3]+1.846837101*x1[4]-.4948585097*x1[5]+.1325969380*x1[6]-0.3552924247e-1*x1[7]+0.9520031827e-2*x1[8]-0.2550884838e-2*x1[9]+0.6835075261e-3*x1[10]-0.1831452664e-3*x1[11]+0.4907353932e-4*x1[12]-0.1314889092e-4*x1[13]+3.522024353*10^(-6)*x1[14]-9.392064942*10^(-7)*x1[15]+2.348016235*10^(-7)*x1[16]-3.913360392*10^(-8)*x1[17]-1.*x2[1] = 0

 

eq2[1] := -20.28718708*x2[1]+25.72312247*x2[2]-6.892489894*x2[3]+1.846837101*x2[4]-.4948585097*x2[5]+.1325969380*x2[6]-0.3552924247e-1*x2[7]+0.9520031827e-2*x2[8]-0.2550884838e-2*x2[9]+0.6835075261e-3*x2[10]-0.1831452664e-3*x2[11]+0.4907353932e-4*x2[12]-0.1314889092e-4*x2[13]+3.522024353*10^(-6)*x2[14]-9.392064942*10^(-7)*x2[15]+2.348016235*10^(-7)*x2[16]-3.913360392*10^(-8)*x2[17]-1.*u[1] = 0

 

eq1[2] := -7.425625842*x1[1]-3.446244947*x1[2]+13.78497979*x1[3]-3.693674202*x1[4]+.9897170194*x1[5]-.2651938761*x1[6]+0.7105848494e-1*x1[7]-0.1904006365e-1*x1[8]+0.5101769676e-2*x1[9]-0.1367015052e-2*x1[10]+0.3662905327e-3*x1[11]-0.9814707864e-4*x1[12]+0.2629778184e-4*x1[13]-7.044048706*10^(-6)*x1[14]+1.878412988*10^(-6)*x1[15]-4.696032471*10^(-7)*x1[16]+7.826720785*10^(-8)*x1[17]-1.000000000*x2[2] = 0

 

eq2[2] := -7.425625842*x2[1]-3.446244947*x2[2]+13.78497979*x2[3]-3.693674202*x2[4]+.9897170194*x2[5]-.2651938761*x2[6]+0.7105848494e-1*x2[7]-0.1904006365e-1*x2[8]+0.5101769676e-2*x2[9]-0.1367015052e-2*x2[10]+0.3662905327e-3*x2[11]-0.9814707864e-4*x2[12]+0.2629778184e-4*x2[13]-7.044048706*10^(-6)*x2[14]+1.878412988*10^(-6)*x2[15]-4.696032471*10^(-7)*x2[16]+7.826720785*10^(-8)*x2[17]-1.000000000*u[2] = 0

 

eq1[3] := 1.989690448*x1[1]-11.93814269*x1[2]-.2474292549*x1[3]+12.92785971*x1[4]-3.464009568*x1[5]+.9281785663*x1[6]-.2487046973*x1[7]+0.6664022279e-1*x1[8]-0.1785619387e-1*x1[9]+0.4784552683e-2*x1[10]-0.1282016864e-2*x1[11]+0.3435147752e-3*x1[12]-0.9204223643e-4*x1[13]+0.2465417047e-4*x1[14]-6.574445459*10^(-6)*x1[15]+1.643611365*10^(-6)*x1[16]-2.739352275*10^(-7)*x1[17]-1.000000000*x2[3] = 0

 

eq2[3] := 1.989690448*x2[1]-11.93814269*x2[2]-.2474292549*x2[3]+12.92785971*x2[4]-3.464009568*x2[5]+.9281785663*x2[6]-.2487046973*x2[7]+0.6664022279e-1*x2[8]-0.1785619387e-1*x2[9]+0.4784552683e-2*x2[10]-0.1282016864e-2*x2[11]+0.3435147752e-3*x2[12]-0.9204223643e-4*x2[13]+0.2465417047e-4*x2[14]-6.574445459*10^(-6)*x2[15]+1.643611365*10^(-6)*x2[16]-2.739352275*10^(-7)*x2[17]-1.000000000*u[3] = 0

 

eq1[4] := -.5331359486*x1[1]+3.198815692*x1[2]-12.79526277*x1[3]-0.1776462123e-1*x1[4]+12.86632125*x1[5]-3.447520389*x1[6]+.9237603042*x1[7]-.2475208275*x1[8]+0.6632300579e-1*x1[9]-0.1777119568e-1*x1[10]+0.4761776926e-2*x1[11]-0.1275912022e-2*x1[12]+0.3418711639e-3*x1[13]-0.9157263318e-4*x1[14]+0.2441936885e-4*x1[15]-6.104842212*10^(-6)*x1[16]+1.017473702*10^(-6)*x1[17]-1.000000000*x2[4] = 0

 

eq2[4] := -.5331359486*x2[1]+3.198815692*x2[2]-12.79526277*x2[3]-0.1776462123e-1*x2[4]+12.86632125*x2[5]-3.447520389*x2[6]+.9237603042*x2[7]-.2475208275*x2[8]+0.6632300579e-1*x2[9]-0.1777119568e-1*x2[10]+0.4761776926e-2*x2[11]-0.1275912022e-2*x2[12]+0.3418711639e-3*x2[13]-0.9157263318e-4*x2[14]+0.2441936885e-4*x2[15]-6.104842212*10^(-6)*x2[16]+1.017473702*10^(-6)*x2[17]-1.000000000*u[4] = 0

 

eq1[5] := .1428533469*x1[1]-.8571200814*x1[2]+3.428480326*x1[3]-12.85680122*x1[4]-0.1275442419e-2*x1[5]+12.86190299*x1[6]-3.446336519*x1[7]+.9234430872*x1[8]-.2474358293*x1[9]+0.6630023004e-1*x1[10]-0.1776509084e-1*x1[11]+0.4760133314e-2*x1[12]-0.1275442419e-2*x1[13]+0.3416363623e-3*x1[14]-0.9110302994e-4*x1[15]+0.2277575748e-4*x1[16]-3.795959581*10^(-6)*x1[17]-1.000000000*x2[5] = 0

 

eq2[5] := .1428533469*x2[1]-.8571200814*x2[2]+3.428480326*x2[3]-12.85680122*x2[4]-0.1275442419e-2*x2[5]+12.86190299*x2[6]-3.446336519*x2[7]+.9234430872*x2[8]-.2474358293*x2[9]+0.6630023004e-1*x2[10]-0.1776509084e-1*x2[11]+0.4760133314e-2*x2[12]-0.1275442419e-2*x2[13]+0.3416363623e-3*x2[14]-0.9110302994e-4*x2[15]+0.2277575748e-4*x2[16]-3.795959581*10^(-6)*x2[17]-1.000000000*u[5] = 0

 

eq1[6] := -0.3827743894e-1*x1[1]+.2296646336*x1[2]-.9186585345*x1[3]+3.444969504*x1[4]-12.86121948*x1[5]-0.9157263318e-4*x1[6]+12.86158577*x1[7]-3.446251521*x1[8]+.9234203114*x1[9]-.2474297245*x1[10]+0.6629858642e-1*x1[11]-0.1776462123e-1*x1[12]+0.4759898512e-2*x1[13]-0.1274972816e-2*x1[14]+0.3399927509e-3*x1[15]-0.8499818772e-4*x1[16]+0.1416636462e-4*x1[17]-1.000000000*x2[6] = 0

 

eq2[6] := -0.3827743894e-1*x2[1]+.2296646336*x2[2]-.9186585345*x2[3]+3.444969504*x2[4]-12.86121948*x2[5]-0.9157263318e-4*x2[6]+12.86158577*x2[7]-3.446251521*x2[8]+.9234203114*x2[9]-.2474297245*x2[10]+0.6629858642e-1*x2[11]-0.1776462123e-1*x2[12]+0.4759898512e-2*x2[13]-0.1274972816e-2*x2[14]+0.3399927509e-3*x2[15]-0.8499818772e-4*x2[16]+0.1416636462e-4*x2[17]-1.000000000*u[6] = 0

 

eq1[7] := 0.1025640885e-1*x1[1]-0.6153845311e-1*x1[2]+.2461538124*x1[3]-.9230767966*x1[4]+3.446153374*x1[5]-12.86153670*x1[6]-6.574445459*10^(-6)*x1[7]+12.86156300*x1[8]-3.446245416*x1[9]+.9234186678*x1[10]-.2474292549*x1[11]+0.6629835162e-1*x1[12]-0.1776415163e-1*x1[13]+0.4758254901e-2*x1[14]-0.1268867974e-2*x1[15]+0.3172169934e-3*x1[16]-0.5286949890e-4*x1[17]-1.000000000*x2[7] = 0

 

eq2[7] := 0.1025640885e-1*x2[1]-0.6153845311e-1*x2[2]+.2461538124*x2[3]-.9230767966*x2[4]+3.446153374*x2[5]-12.86153670*x2[6]-6.574445459*10^(-6)*x2[7]+12.86156300*x2[8]-3.446245416*x2[9]+.9234186678*x2[10]-.2474292549*x2[11]+0.6629835162e-1*x2[12]-0.1776415163e-1*x2[13]+0.4758254901e-2*x2[14]-0.1268867974e-2*x2[15]+0.3172169934e-3*x2[16]-0.5286949890e-4*x2[17]-1.000000000*u[7] = 0

 

eq1[8] := -0.2748196469e-2*x1[1]+0.1648917882e-1*x1[2]-0.6595671526e-1*x1[3]+.2473376822*x1[4]-.9233940136*x1[5]+3.446238372*x1[6]-12.86155948*x1[7]-4.696032471*10^(-7)*x1[8]+12.86156135*x1[9]-3.446244947*x1[10]+.9234184330*x1[11]-.2474287852*x1[12]+0.6629670801e-1*x1[13]-0.1775804679e-1*x1[14]+0.4735479144e-2*x1[15]-0.1183869786e-2*x1[16]+0.1973116310e-3*x1[17]-1.000000000*x2[8] = 0

 

eq2[8] := -0.2748196469e-2*x2[1]+0.1648917882e-1*x2[2]-0.6595671526e-1*x2[3]+.2473376822*x2[4]-.9233940136*x2[5]+3.446238372*x2[6]-12.86155948*x2[7]-4.696032471*10^(-7)*x2[8]+12.86156135*x2[9]-3.446244947*x2[10]+.9234184330*x2[11]-.2474287852*x2[12]+0.6629670801e-1*x2[13]-0.1775804679e-1*x2[14]+0.4735479144e-2*x2[15]-0.1183869786e-2*x2[16]+0.1973116310e-3*x2[17]-1.000000000*u[8] = 0

 

eq1[9] := 0.7363770250e-3*x1[1]-0.4418262150e-2*x1[2]+0.1767304860e-1*x1[3]-0.6627393225e-1*x1[4]+.2474226804*x1[5]-.9234167894*x1[6]+3.446244477*x1[7]-12.86156112*x1[8]+12.86156112*x1[10]-3.446244477*x1[11]+.9234167894*x1[12]-.2474226804*x1[13]+0.6627393225e-1*x1[14]-0.1767304860e-1*x1[15]+0.4418262150e-2*x1[16]-0.7363770250e-3*x1[17]-1.000000000*x2[9] = 0

 

eq2[9] := 0.7363770250e-3*x2[1]-0.4418262150e-2*x2[2]+0.1767304860e-1*x2[3]-0.6627393225e-1*x2[4]+.2474226804*x2[5]-.9234167894*x2[6]+3.446244477*x2[7]-12.86156112*x2[8]+12.86156112*x2[10]-3.446244477*x2[11]+.9234167894*x2[12]-.2474226804*x2[13]+0.6627393225e-1*x2[14]-0.1767304860e-1*x2[15]+0.4418262150e-2*x2[16]-0.7363770250e-3*x2[17]-1.000000000*u[9] = 0

 

eq1[10] := -0.1973116310e-3*x1[1]+0.1183869786e-2*x1[2]-0.4735479144e-2*x1[3]+0.1775804679e-1*x1[4]-0.6629670801e-1*x1[5]+.2474287852*x1[6]-.9234184330*x1[7]+3.446244947*x1[8]-12.86156135*x1[9]+4.696032471*10^(-7)*x1[10]+12.86155948*x1[11]-3.446238372*x1[12]+.9233940136*x1[13]-.2473376822*x1[14]+0.6595671526e-1*x1[15]-0.1648917882e-1*x1[16]+0.2748196469e-2*x1[17]-1.000000000*x2[10] = 0

 

eq2[10] := -0.1973116310e-3*x2[1]+0.1183869786e-2*x2[2]-0.4735479144e-2*x2[3]+0.1775804679e-1*x2[4]-0.6629670801e-1*x2[5]+.2474287852*x2[6]-.9234184330*x2[7]+3.446244947*x2[8]-12.86156135*x2[9]+4.696032471*10^(-7)*x2[10]+12.86155948*x2[11]-3.446238372*x2[12]+.9233940136*x2[13]-.2473376822*x2[14]+0.6595671526e-1*x2[15]-0.1648917882e-1*x2[16]+0.2748196469e-2*x2[17]-1.000000000*u[10] = 0

 

eq1[11] := 0.5286949890e-4*x1[1]-0.3172169934e-3*x1[2]+0.1268867974e-2*x1[3]-0.4758254901e-2*x1[4]+0.1776415163e-1*x1[5]-0.6629835162e-1*x1[6]+.2474292549*x1[7]-.9234186678*x1[8]+3.446245416*x1[9]-12.86156300*x1[10]+6.574445459*10^(-6)*x1[11]+12.86153670*x1[12]-3.446153374*x1[13]+.9230767966*x1[14]-.2461538124*x1[15]+0.6153845311e-1*x1[16]-0.1025640885e-1*x1[17]-1.00000000*x2[11] = 0

 

eq2[11] := 0.5286949890e-4*x2[1]-0.3172169934e-3*x2[2]+0.1268867974e-2*x2[3]-0.4758254901e-2*x2[4]+0.1776415163e-1*x2[5]-0.6629835162e-1*x2[6]+.2474292549*x2[7]-.9234186678*x2[8]+3.446245416*x2[9]-12.86156300*x2[10]+6.574445459*10^(-6)*x2[11]+12.86153670*x2[12]-3.446153374*x2[13]+.9230767966*x2[14]-.2461538124*x2[15]+0.6153845311e-1*x2[16]-0.1025640885e-1*x2[17]-1.00000000*u[11] = 0

 

eq1[12] := -0.1416636462e-4*x1[1]+0.8499818772e-4*x1[2]-0.3399927509e-3*x1[3]+0.1274972816e-2*x1[4]-0.4759898512e-2*x1[5]+0.1776462123e-1*x1[6]-0.6629858642e-1*x1[7]+.2474297245*x1[8]-.9234203114*x1[9]+3.446251521*x1[10]-12.86158577*x1[11]+0.9157263318e-4*x1[12]+12.86121948*x1[13]-3.444969504*x1[14]+.9186585345*x1[15]-.2296646336*x1[16]+0.3827743894e-1*x1[17]-1.00000000*x2[12] = 0

 

eq2[12] := -0.1416636462e-4*x2[1]+0.8499818772e-4*x2[2]-0.3399927509e-3*x2[3]+0.1274972816e-2*x2[4]-0.4759898512e-2*x2[5]+0.1776462123e-1*x2[6]-0.6629858642e-1*x2[7]+.2474297245*x2[8]-.9234203114*x2[9]+3.446251521*x2[10]-12.86158577*x2[11]+0.9157263318e-4*x2[12]+12.86121948*x2[13]-3.444969504*x2[14]+.9186585345*x2[15]-.2296646336*x2[16]+0.3827743894e-1*x2[17]-1.00000000*u[12] = 0

 

eq1[13] := 3.795959581*10^(-6)*x1[1]-0.2277575748e-4*x1[2]+0.9110302994e-4*x1[3]-0.3416363623e-3*x1[4]+0.1275442419e-2*x1[5]-0.4760133314e-2*x1[6]+0.1776509084e-1*x1[7]-0.6630023004e-1*x1[8]+.2474358293*x1[9]-.9234430872*x1[10]+3.446336519*x1[11]-12.86190299*x1[12]+0.1275442419e-2*x1[13]+12.85680122*x1[14]-3.428480326*x1[15]+.8571200814*x1[16]-.1428533469*x1[17]-1.00000000*x2[13] = 0

 

eq2[13] := 3.795959581*10^(-6)*x2[1]-0.2277575748e-4*x2[2]+0.9110302994e-4*x2[3]-0.3416363623e-3*x2[4]+0.1275442419e-2*x2[5]-0.4760133314e-2*x2[6]+0.1776509084e-1*x2[7]-0.6630023004e-1*x2[8]+.2474358293*x2[9]-.9234430872*x2[10]+3.446336519*x2[11]-12.86190299*x2[12]+0.1275442419e-2*x2[13]+12.85680122*x2[14]-3.428480326*x2[15]+.8571200814*x2[16]-.1428533469*x2[17]-1.00000000*u[13] = 0

 

eq1[14] := -1.017473702*10^(-6)*x1[1]+6.104842212*10^(-6)*x1[2]-0.2441936885e-4*x1[3]+0.9157263318e-4*x1[4]-0.3418711639e-3*x1[5]+0.1275912022e-2*x1[6]-0.4761776926e-2*x1[7]+0.1777119568e-1*x1[8]-0.6632300579e-1*x1[9]+.2475208275*x1[10]-.9237603042*x1[11]+3.447520389*x1[12]-12.86632125*x1[13]+0.1776462123e-1*x1[14]+12.79526277*x1[15]-3.198815692*x1[16]+.5331359486*x1[17]-1.00000000*x2[14] = 0

 

eq2[14] := -1.017473702*10^(-6)*x2[1]+6.104842212*10^(-6)*x2[2]-0.2441936885e-4*x2[3]+0.9157263318e-4*x2[4]-0.3418711639e-3*x2[5]+0.1275912022e-2*x2[6]-0.4761776926e-2*x2[7]+0.1777119568e-1*x2[8]-0.6632300579e-1*x2[9]+.2475208275*x2[10]-.9237603042*x2[11]+3.447520389*x2[12]-12.86632125*x2[13]+0.1776462123e-1*x2[14]+12.79526277*x2[15]-3.198815692*x2[16]+.5331359486*x2[17]-1.00000000*u[14] = 0

 

eq1[15] := 2.739352275*10^(-7)*x1[1]-1.643611365*10^(-6)*x1[2]+6.574445459*10^(-6)*x1[3]-0.2465417047e-4*x1[4]+0.9204223643e-4*x1[5]-0.3435147752e-3*x1[6]+0.1282016864e-2*x1[7]-0.4784552683e-2*x1[8]+0.1785619387e-1*x1[9]-0.6664022279e-1*x1[10]+.2487046973*x1[11]-.9281785663*x1[12]+3.464009568*x1[13]-12.92785971*x1[14]+.2474292549*x1[15]+11.93814269*x1[16]-1.989690448*x1[17]-1.00000000*x2[15] = 0

 

eq2[15] := 2.739352275*10^(-7)*x2[1]-1.643611365*10^(-6)*x2[2]+6.574445459*10^(-6)*x2[3]-0.2465417047e-4*x2[4]+0.9204223643e-4*x2[5]-0.3435147752e-3*x2[6]+0.1282016864e-2*x2[7]-0.4784552683e-2*x2[8]+0.1785619387e-1*x2[9]-0.6664022279e-1*x2[10]+.2487046973*x2[11]-.9281785663*x2[12]+3.464009568*x2[13]-12.92785971*x2[14]+.2474292549*x2[15]+11.93814269*x2[16]-1.989690448*x2[17]-1.00000000*u[15] = 0

 

eq1[16] := -7.826720785*10^(-8)*x1[1]+4.696032471*10^(-7)*x1[2]-1.878412988*10^(-6)*x1[3]+7.044048706*10^(-6)*x1[4]-0.2629778184e-4*x1[5]+0.9814707864e-4*x1[6]-0.3662905327e-3*x1[7]+0.1367015052e-2*x1[8]-0.5101769676e-2*x1[9]+0.1904006365e-1*x1[10]-0.7105848494e-1*x1[11]+.2651938761*x1[12]-.9897170194*x1[13]+3.693674202*x1[14]-13.78497979*x1[15]+3.446244947*x1[16]+7.425625842*x1[17]-1.00000000*x2[16] = 0

 

eq2[16] := -7.826720785*10^(-8)*x2[1]+4.696032471*10^(-7)*x2[2]-1.878412988*10^(-6)*x2[3]+7.044048706*10^(-6)*x2[4]-0.2629778184e-4*x2[5]+0.9814707864e-4*x2[6]-0.3662905327e-3*x2[7]+0.1367015052e-2*x2[8]-0.5101769676e-2*x2[9]+0.1904006365e-1*x2[10]-0.7105848494e-1*x2[11]+.2651938761*x2[12]-.9897170194*x2[13]+3.693674202*x2[14]-13.78497979*x2[15]+3.446244947*x2[16]+7.425625842*x2[17]-1.00000000*u[16] = 0

 

eq1[17] := 3.913360392*10^(-8)*x1[1]-2.348016235*10^(-7)*x1[2]+9.392064942*10^(-7)*x1[3]-3.522024353*10^(-6)*x1[4]+0.1314889092e-4*x1[5]-0.4907353932e-4*x1[6]+0.1831452664e-3*x1[7]-0.6835075261e-3*x1[8]+0.2550884838e-2*x1[9]-0.9520031827e-2*x1[10]+0.3552924247e-1*x1[11]-.1325969380*x1[12]+.4948585097*x1[13]-1.846837101*x1[14]+6.892489894*x1[15]-25.72312247*x1[16]+20.28718708*x1[17]-1.*x2[17] = 0

 

eq2[17] := 3.913360392*10^(-8)*x2[1]-2.348016235*10^(-7)*x2[2]+9.392064942*10^(-7)*x2[3]-3.522024353*10^(-6)*x2[4]+0.1314889092e-4*x2[5]-0.4907353932e-4*x2[6]+0.1831452664e-3*x2[7]-0.6835075261e-3*x2[8]+0.2550884838e-2*x2[9]-0.9520031827e-2*x2[10]+0.3552924247e-1*x2[11]-.1325969380*x2[12]+.4948585097*x2[13]-1.846837101*x2[14]+6.892489894*x2[15]-25.72312247*x2[16]+20.28718708*x2[17]-1.*u[17] = 0

 

eq3[1] := 1.*x1[1]-.1, 0

 

eq3[2] := 1.000000000*x1[2]-.1, 0

 

eq3[3] := 1.000000000*x1[3]-.1, 0

 

eq3[4] := 1.000000000*x1[4]-.1, 0

 

eq3[5] := 1.000000000*x1[5]-.1, 0

 

eq3[6] := 1.000000000*x1[6]-.1, 0

 

eq3[7] := 1.000000000*x1[7]-.1, 0

 

eq3[8] := 1.000000000*x1[8]-.1, 0

 

eq3[9] := 1.000000000*x1[9]-.1, 0

 

eq3[10] := 1.000000000*x1[10]-.1, 0

 

eq3[11] := 1.00000000*x1[11]-.1, 0

 

eq3[12] := 1.00000000*x1[12]-.1, 0

 

eq3[13] := 1.00000000*x1[13]-.1, 0

 

eq3[14] := 1.00000000*x1[14]-.1, 0

 

eq3[15] := 1.00000000*x1[15]-.1, 0

 

eq3[16] := 1.00000000*x1[16]-.1, 0

 

eq3[17] := 1.*x1[17]-.1, 0

 

eq1[0] := 1.*x1[1] = 0

 

eq2[0] := 1.*x2[1]-1 = 0

 

eq1[18] := 1.*x1[17] = 0

 

eq2[18] := 1.*x2[17] = -1

 

eqq1 := {-7.425625842*x1[1]-3.446244947*x1[2]+13.78497979*x1[3]-3.693674202*x1[4]+.9897170194*x1[5]-.2651938761*x1[6]+0.7105848494e-1*x1[7]-0.1904006365e-1*x1[8]+0.5101769676e-2*x1[9]-0.1367015052e-2*x1[10]+0.3662905327e-3*x1[11]-0.9814707864e-4*x1[12]+0.2629778184e-4*x1[13]-7.044048706*10^(-6)*x1[14]+1.878412988*10^(-6)*x1[15]-4.696032471*10^(-7)*x1[16]+7.826720785*10^(-8)*x1[17]-1.000000000*x2[2] = 0}

 

eqq2 := {-7.425625842*x2[1]-3.446244947*x2[2]+13.78497979*x2[3]-3.693674202*x2[4]+.9897170194*x2[5]-.2651938761*x2[6]+0.7105848494e-1*x2[7]-0.1904006365e-1*x2[8]+0.5101769676e-2*x2[9]-0.1367015052e-2*x2[10]+0.3662905327e-3*x2[11]-0.9814707864e-4*x2[12]+0.2629778184e-4*x2[13]-7.044048706*10^(-6)*x2[14]+1.878412988*10^(-6)*x2[15]-4.696032471*10^(-7)*x2[16]+7.826720785*10^(-8)*x2[17]-1.000000000*u[2] = 0}

 

eqq3 := {0, 1.*x1[17]-.1}

 

eq := {0, 1.*x1[17]-.1, -7.425625842*x1[1]-3.446244947*x1[2]+13.78497979*x1[3]-3.693674202*x1[4]+.9897170194*x1[5]-.2651938761*x1[6]+0.7105848494e-1*x1[7]-0.1904006365e-1*x1[8]+0.5101769676e-2*x1[9]-0.1367015052e-2*x1[10]+0.3662905327e-3*x1[11]-0.9814707864e-4*x1[12]+0.2629778184e-4*x1[13]-7.044048706*10^(-6)*x1[14]+1.878412988*10^(-6)*x1[15]-4.696032471*10^(-7)*x1[16]+7.826720785*10^(-8)*x1[17]-1.000000000*x2[2] = 0, -7.425625842*x2[1]-3.446244947*x2[2]+13.78497979*x2[3]-3.693674202*x2[4]+.9897170194*x2[5]-.2651938761*x2[6]+0.7105848494e-1*x2[7]-0.1904006365e-1*x2[8]+0.5101769676e-2*x2[9]-0.1367015052e-2*x2[10]+0.3662905327e-3*x2[11]-0.9814707864e-4*x2[12]+0.2629778184e-4*x2[13]-7.044048706*10^(-6)*x2[14]+1.878412988*10^(-6)*x2[15]-4.696032471*10^(-7)*x2[16]+7.826720785*10^(-8)*x2[17]-1.000000000*u[2] = 0}

 

[ImportMPS, Interactive, LPSolve, LSSolve, Maximize, Minimize, NLPSolve, QPSolve]

 

Error, (in Optimization:-NLPSolve) constraints must be specified as a set or list of equalities and inequalities

 

uexact := piecewise(0 <= x and x <= .3, 200*x*(1/9)-20/3, .3 <= x and x <= .7, 0, .7 <= x and x <= 1, -200*x*(1/9)+140/9)

 

x2exact := piecewise(0 <= x and x <= .3, (100/9)*x^2-(20/3)*x+1, .3 <= x and x <= .7, 0, .7 <= x and x <= 1, -(100/9)*x^2+(140/9)*x-49/9)

 

piecewise(0 <= x and x <= .3, (100/27)*x^3-(10/3)*x^2+x, .3 <= x and x <= .7, 1/10, .7 <= x and x <= 1, -(100/27)*x^3+(70/9)*x^2-(49/9)*x+37/27)

 

Warning, expecting only range variable x in expression x1[1]*piecewise(0. <= 16.*x+1. and 16.*x <= 0.,16.*x+1.,0. < 16.*x and 16.*x <= 1.,1.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[2]*piecewise(0. <= 16.*x and 16.*x <= 1.,16.*x,1. < 16.*x and 16.*x <= 2.,2.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[3]*piecewise(0. <= 16.*x-1. and 16.*x <= 2.,16.*x-1.,0. < 16.*x-2. and 16.*x <= 3.,3.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[4]*piecewise(0. <= 16.*x-2. and 16.*x <= 3.,16.*x-2.,0. < 16.*x-3. and 16.*x <= 4.,4.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[5]*piecewise(0. <= 16.*x-3. and 16.*x <= 4.,16.*x-3.,0. < 16.*x-4. and 16.*x <= 5.,5.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[6]*piecewise(0. <= 16.*x-4. and 16.*x <= 5.,16.*x-4.,0. < 16.*x-5. and 16.*x <= 6.,6.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[7]*piecewise(0. <= 16.*x-5. and 16.*x <= 6.,16.*x-5.,0. < 16.*x-6. and 16.*x <= 7.,7.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[8]*piecewise(0. <= 16.*x-6. and 16.*x <= 7.,16.*x-6.,0. < 16.*x-7. and 16.*x <= 8.,8.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[9]*piecewise(0. <= 16.*x-7. and 16.*x <= 8.,16.*x-7.,0. < 16.*x-8. and 16.*x <= 9.,9.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[10]*piecewise(0. <= 16.*x-8. and 16.*x <= 9.,16.*x-8.,0. < 16.*x-9. and 16.*x <= 10.,10.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[11]*piecewise(0. <= 16.*x-9. and 16.*x <= 10.,16.*x-9.,0. < 16.*x-10. and 16.*x <= 11.,11.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[12]*piecewise(0. <= 16.*x-10. and 16.*x <= 11.,16.*x-10.,0. < 16.*x-11. and 16.*x <= 12.,12.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[13]*piecewise(0. <= 16.*x-11. and 16.*x <= 12.,16.*x-11.,0. < 16.*x-12. and 16.*x <= 13.,13.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[14]*piecewise(0. <= 16.*x-12. and 16.*x <= 13.,16.*x-12.,0. < 16.*x-13. and 16.*x <= 14.,14.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[15]*piecewise(0. <= 16.*x-13. and 16.*x <= 14.,16.*x-13.,0. < 16.*x-14. and 16.*x <= 15.,15.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[16]*piecewise(0. <= 16.*x-14. and 16.*x <= 15.,16.*x-14.,0. < 16.*x-15. and 16.*x <= 16.,16.-16.*x)*piecewise(0 <= x and x <= 1,1)+x1[17]*piecewise(0. <= 16.*x-15. and 16.*x <= 16.,16.*x-15.,0. < 16.*x-16. and 16.*x <= 17.,17.-16.*x)*piecewise(0 <= x and x <= 1,1) to be plotted but found names [x1[1], x1[2], x1[3], x1[4], x1[5], x1[6], x1[7], x1[8], x1[9], x1[10], x1[11], x1[12], x1[13], x1[14], x1[15], x1[16], x1[17]]

 

 

``


 

Download 1.mw

 

Hello Everyone;

Hope you are fine. I am applying rk-4 and Runge-Kutta-Fehlberg method for system of odes but there is no difference in the result of these method. Can anybody guide about that for my problem. I have uploaded the code. Thanks in advance.

Question#3.mw

 

Hello!

How do I solve this system? could someone help me please.

restart;
eqns := {x(t+1) = (1+10^(-6)*(0.4e-2-0.6e-2)/(0.1e-3))*x(t)+0.7e-1*10^(-6)*y(t),

y(t+1) = 0.6e-2*10^(-6)*x(t)/(0.1e-3)+(1-0.7e-1*10^(-6))*y(t)};

with:
x(0) = 1
y(0) =
y(0) = 857.1428571

restart

eqns := {x(t+1) = (1+10^(-6)*(0.4e-2-0.6e-2)/(0.1e-3))*x(t)+0.7e-1*10^(-6)*y(t), y(t+1) = 0.6e-2*10^(-6)*x(t)/(0.1e-3)+(1-0.7e-1*10^(-6))*y(t)};

{x(t+1) = .9999800000*x(t)+0.7000000000e-7*y(t), y(t+1) = 0.6000000000e-4*x(t)+.9999999300*y(t)}

(1)

x(0) = 1

x(0) = 1

(2)

y(0) = 0.6e-2/(0.1e-3*0.7e-1)

y(0) = 857.1428571

(3)

``

Download SystemRecursive.mw

Good day all.

My particular question concerns a Traveling Salesman-type problem.

Suppose I wish to move along the x-y plane and visit specific nodes (see the attached worksheet).

Starting at the origin, A, I intend to visit four locations, B to E, and finally return to the origin point. These nodes may be visited in any order - but, my total distance travelled must be a minimum.
However, my direction of travel is restricted; namely:

1. Movement is limited to the x and y-directions only (up and down as well as left and right)
2. Horizontal (left or right) movement is permitten only at y=1 and y=10

This second rule restricts me from turning left or right in between y= 1 and 10.
The Traveling Salesman routine (attached) is constructed to select a tour that is confined to orthogonal movement but it does not observe the second restriction (i.e. move left or right when you reach y=1 or y=10).

Is there any way in which I can build this condition into the routine so that the movement along the circuit observes the restrictions? 

If so - is it possible to graphically illustrate the order of travel (using arrows from point-to-point) on a point plot?

I appreciate you taking the time to read this.

MaplePrimes_May_6.mw

I tried to graph the function f(x)=x^(1/3) but it only gives me a graph for non-negative x's, when the function f has all real numbers as its domain.

Maybe I'm doing it wrong.

Thank you.

ac-dc-dc1.msim

When i click off the "Plot events", the figure of Probe2 is pretty different comparing with "Plot events" is turned on. Here is my assumption: the simulation duration is 500 seconds and the plot points are 2000. Considering the frequency of sine current is 40HZ, many points cannot be ploted in the figure. So it is not a big deal for curve like Probe1 and Probe5 because  they tend to be a constant and Probe2 just reflect the tendency.

Hey I’m trying to shift a function horizontally to the right.

I have the following 3 functions:

V1 := -x

V2:= -2*x + 4.95

V3:= -x + 1.665

Function V2 I want to shift l_1 to the right, and V3 I want to shift l_1 + l_2 to the right.

I know I can do this manually by define the functions:

V2:= -2*(x-l_1) + 4.95

V3:= -(x-l_1-l_2) + 1.665

Where l_1:=1.665 and l_2:=4.95

Is there a way to do this without typing it manually?

By the way it’s only for plotting, so it’s not necessary for me to actually define them, if there is a way to do it within a plot some how.

Thank you in advance.

First 194 195 196 197 198 199 200 Last Page 196 of 2308