Items tagged with syntax syntax Tagged Items Feed

 

hi all,

How could I write long commands in Maple?

For instance: a long vector in Matlab could be written in this way:

A=[ 3, 4, 5, 6, 6, 45, 37...

5, 4, 67, 39, -967 ];

But what is that in Maple??? 


Trying to build a block matrix. Having a problem getting the syntax correct. Can't add in the predefind matrices to the lower band.

restart

with(LinearAlgebra):

interface(displayprecision = 5)

5

(1)

interface(rtablesize = 81)

10

(2)

S := 2

2

(3)

dmax := 7

7

(4)

CCnew0 := Matrix(2, 2, {(1, 1) = 336750255587/3769550688757, (1, 2) = -14853552191797/1696297809940650, (2, 1) = 665096091/76929605893, (2, 2) = 1328910382993/11539440883950})

CCnew0 := Matrix(2, 2, {(1, 1) = 336750255587/3769550688757, (1, 2) = -14853552191797/1696297809940650, (2, 1) = 665096091/76929605893, (2, 2) = 1328910382993/11539440883950})

(5)

CCnew1 := Matrix(2, 2, {(1, 1) = 49655436033349/56543260331355, (1, 2) = -75647656451147/1413581508283875, (2, 1) = 29849106694/384648029465, (2, 2) = 10591394356218/9616200736625})

CCnew1 := Matrix(2, 2, {(1, 1) = 49655436033349/56543260331355, (1, 2) = -75647656451147/1413581508283875, (2, 1) = 29849106694/384648029465, (2, 2) = 10591394356218/9616200736625})

(6)

CCnew2 := Matrix(2, 2, {(1, 1) = 299962512141959/80776086187650, (1, 2) = -1231816081155781/8481489049703250, (2, 1) = 155175716729/549497184950, (2, 2) = 260449617208489/57697204419750})

CCnew2 := Matrix(2, 2, {(1, 1) = 299962512141959/80776086187650, (1, 2) = -1231816081155781/8481489049703250, (2, 1) = 155175716729/549497184950, (2, 2) = 260449617208489/57697204419750})

(7)

CCnew3 := Matrix(2, 2, {(1, 1) = 50445725001719/5769720441975, (1, 2) = -9065291388901/40388043093825, (2, 1) = 21111399914/39249798925, (2, 2) = 2819495262394/274748592475})

CCnew3 := Matrix(2, 2, {(1, 1) = 50445725001719/5769720441975, (1, 2) = -9065291388901/40388043093825, (2, 1) = 21111399914/39249798925, (2, 2) = 2819495262394/274748592475})

(8)

CCnew4 := Matrix(2, 2, {(1, 1) = 142685068141037/11539440883950, (1, 2) = -116560067351321/565432603313550, (2, 1) = 44654487647/78499597850, (2, 2) = 53741323977599/3846480294650})

CCnew4 := Matrix(2, 2, {(1, 1) = 142685068141037/11539440883950, (1, 2) = -116560067351321/565432603313550, (2, 1) = 44654487647/78499597850, (2, 2) = 53741323977599/3846480294650})

(9)

CCnew5 := Matrix(2, 2, {(1, 1) = 60560690824604/5769720441975, (1, 2) = -88774498025543/848148904970325, (2, 1) = 12484906049/39249798925, (2, 2) = 65745570806567/5769720441975})

CCnew5 := Matrix(2, 2, {(1, 1) = 60560690824604/5769720441975, (1, 2) = -88774498025543/848148904970325, (2, 1) = 12484906049/39249798925, (2, 2) = 65745570806567/5769720441975})

(10)

CCnew6 := Matrix(2, 2, {(1, 1) = 20398649489879/4121228887125, (1, 2) = -5446073753219/242328258562950, (2, 1) = 14465459393/196248994625, (2, 2) = 8502096238511/1648491554850})

CCnew6 := Matrix(2, 2, {(1, 1) = 20398649489879/4121228887125, (1, 2) = -5446073753219/242328258562950, (2, 1) = 14465459393/196248994625, (2, 2) = 8502096238511/1648491554850})

(11)

S*dmax

14

(12)

M1 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity), Matrix(S, S*dmax, [seq(-CCnew || n, n = 0 .. dmax-1)])])

Error, (in Matrix) this entry is too tall or too short: Matrix(2, 14, {(1, 1) = -336750255587/3769550688757, (1, 2) = 14853552191797/1696297809940650, (1, 3) = -49655436033349/56543260331355, (1, 4) = 75647656451147/1413581508283875, (1, 5) = -299962512141959/80776086187650, (1, 6) = 1231816081155781/8481489049703250, (1, 7) = -50445725001719/5769720441975, (1, 8) = 9065291388901/40388043093825, (1, 9) = -142685068141037/11539440883950, (1, 10) = 116560067351321/565432603313550, (1, 11) = -60560690824604/5769720441975, (1, 12) = 88774498025543/848148904970325, (1, 13) = -20398649489879/4121228887125, (1, 14) = 5446073753219/242328258562950, ...

 

M2 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity)])

M2 := Matrix(14, 14, {(1, 1) = 0, (1, 2) = 0, (1, 3) = 1, (1, 4) = 0, (1, 5) = 0, (1, 6) = 0, (1, 7) = 0, (1, 8) = 0, (1, 9) = 0, (1, 10) = 0, (1, 11) = 0, (1, 12) = 0, (1, 13) = 0, (1, 14) = 0, (2, 1) = 0, (2, 2) = 0, (2, 3) = 0, (2, 4) = 1, (2, 5) = 0, (2, 6) = 0, (2, 7) = 0, (2, 8) = 0, (2, 9) = 0, (2, 10) = 0, (2, 11) = 0, (2, 12) = 0, (2, 13) = 0, (2, 14) = 0, (3, 1) = 0, (3, 2) = 0, (3, 3) = 0, (3, 4) = 0, (3, 5) = 1, (3, 6) = 0, (3, 7) = 0, (3, 8) = 0, (3, 9) = 0, (3, 10) = 0, (3, 11) = 0, (3, 12) = 0, (3, 13) = 0, (3, 14) = 0, (4, 1) = 0, (4, 2) = 0, (4, 3) = 0, (4, 4) = 0, (4, 5) = 0, (4, 6) = 1, (4, 7) = 0, (4, 8) = 0, (4, 9) = 0, (4, 10) = 0, (4, 11) = 0, (4, 12) = 0, (4, 13) = 0, (4, 14) = 0, (5, 1) = 0, (5, 2) = 0, (5, 3) = 0, (5, 4) = 0, (5, 5) = 0, (5, 6) = 0, (5, 7) = 1, (5, 8) = 0, (5, 9) = 0, (5, 10) = 0, (5, 11) = 0, (5, 12) = 0, (5, 13) = 0, (5, 14) = 0, (6, 1) = 0, (6, 2) = 0, (6, 3) = 0, (6, 4) = 0, (6, 5) = 0, (6, 6) = 0, (6, 7) = 0, (6, 8) = 1, (6, 9) = 0, (6, 10) = 0, (6, 11) = 0, (6, 12) = 0, (6, 13) = 0, (6, 14) = 0, (7, 1) = 0, (7, 2) = 0, (7, 3) = 0, (7, 4) = 0, (7, 5) = 0, (7, 6) = 0, (7, 7) = 0, (7, 8) = 0, (7, 9) = 1, (7, 10) = 0, (7, 11) = 0, (7, 12) = 0, (7, 13) = 0, (7, 14) = 0, (8, 1) = 0, (8, 2) = 0, (8, 3) = 0, (8, 4) = 0, (8, 5) = 0, (8, 6) = 0, (8, 7) = 0, (8, 8) = 0, (8, 9) = 0, (8, 10) = 1, (8, 11) = 0, (8, 12) = 0, (8, 13) = 0, (8, 14) = 0, (9, 1) = 0, (9, 2) = 0, (9, 3) = 0, (9, 4) = 0, (9, 5) = 0, (9, 6) = 0, (9, 7) = 0, (9, 8) = 0, (9, 9) = 0, (9, 10) = 0, (9, 11) = 1, (9, 12) = 0, (9, 13) = 0, (9, 14) = 0, (10, 1) = 0, (10, 2) = 0, (10, 3) = 0, (10, 4) = 0, (10, 5) = 0, (10, 6) = 0, (10, 7) = 0, (10, 8) = 0, (10, 9) = 0, (10, 10) = 0, (10, 11) = 0, (10, 12) = 1, (10, 13) = 0, (10, 14) = 0, (11, 1) = 0, (11, 2) = 0, (11, 3) = 0, (11, 4) = 0, (11, 5) = 0, (11, 6) = 0, (11, 7) = 0, (11, 8) = 0, (11, 9) = 0, (11, 10) = 0, (11, 11) = 0, (11, 12) = 0, (11, 13) = 1, (11, 14) = 0, (12, 1) = 0, (12, 2) = 0, (12, 3) = 0, (12, 4) = 0, (12, 5) = 0, (12, 6) = 0, (12, 7) = 0, (12, 8) = 0, (12, 9) = 0, (12, 10) = 0, (12, 11) = 0, (12, 12) = 0, (12, 13) = 0, (12, 14) = 1, (13, 1) = 0, (13, 2) = 0, (13, 3) = 0, (13, 4) = 0, (13, 5) = 0, (13, 6) = 0, (13, 7) = 0, (13, 8) = 0, (13, 9) = 0, (13, 10) = 0, (13, 11) = 0, (13, 12) = 0, (13, 13) = 0, (13, 14) = 0, (14, 1) = 0, (14, 2) = 0, (14, 3) = 0, (14, 4) = 0, (14, 5) = 0, (14, 6) = 0, (14, 7) = 0, (14, 8) = 0, (14, 9) = 0, (14, 10) = 0, (14, 11) = 0, (14, 12) = 0, (14, 13) = 0, (14, 14) = 0})

(13)

lowerband := Matrix(S, S*dmax, [seq(-evalf(CCnew || n), n = 0 .. dmax-1)])

lowerband := Matrix(2, 14, {(1, 1) = -0.893343e-1, (1, 2) = 0.875645e-2, (1, 3) = -.878185, (1, 4) = 0.535149e-1, (1, 5) = -3.71351, (1, 6) = .145236, (1, 7) = -8.74318, (1, 8) = .224455, (1, 9) = -12.36499, (1, 10) = .206143, (1, 11) = -10.49630, (1, 12) = .104669, (1, 13) = -4.94965, (1, 14) = 0.224740e-1, (2, 1) = -0.864552e-2, (2, 2) = -.115162, (2, 3) = -0.776011e-1, (2, 4) = -1.10141, (2, 5) = -.282396, (2, 6) = -4.51408, (2, 7) = -.537873, (2, 8) = -10.26209, (2, 9) = -.568850, (2, 10) = -13.97156, (2, 11) = -.318088, (2, 12) = -11.39493, (2, 13) = -0.737097e-1, (2, 14) = -5.15750})

(14)

M3 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity), lowerband])

Error, (in Matrix) this entry is too tall or too short: Matrix(2, 14, {(1, 1) = -0.8933432215e-1, (1, 2) = 0.8756453086e-2, (1, 3) = -.8781848755, (1, 4) = 0.5351488825e-1, (1, 5) = -3.713506389, (1, 6) = .1452358276, (1, 7) = -8.743183575, (1, 8) = .224454831, (1, 9) = -12.36498974, (1, 10) = .2061431666, (1, 11) = -10.49629552, (1, 12) = .1046685287, (1, 13) = -4.949652167, (1, 14) = 0.2247395242e-1, (2, 1) = -0.8645515381e-2, (2, 2) = -.1151624586, (2, 3) = -0.7760109089e-1, (2, 4) = -1.101411529, (2, 5) = -.2823958356, (2, 6) = -4.514076892, (2, 7) = -.537872817, (2, 8) = -10.26209174, (2, 9) = -.5688498906, (2, 10) = -13.97155838, (2, 1...

 

``


Download Test_Block_matrix.mw

restart

with(LinearAlgebra):

interface(displayprecision = 5)

5

(1)

interface(rtablesize = 81)

10

(2)

S := 2

2

(3)

dmax := 7

7

(4)

CCnew0 := Matrix(2, 2, {(1, 1) = 336750255587/3769550688757, (1, 2) = -14853552191797/1696297809940650, (2, 1) = 665096091/76929605893, (2, 2) = 1328910382993/11539440883950})

CCnew0 := Matrix(2, 2, {(1, 1) = 336750255587/3769550688757, (1, 2) = -14853552191797/1696297809940650, (2, 1) = 665096091/76929605893, (2, 2) = 1328910382993/11539440883950})

(5)

CCnew1 := Matrix(2, 2, {(1, 1) = 49655436033349/56543260331355, (1, 2) = -75647656451147/1413581508283875, (2, 1) = 29849106694/384648029465, (2, 2) = 10591394356218/9616200736625})

CCnew1 := Matrix(2, 2, {(1, 1) = 49655436033349/56543260331355, (1, 2) = -75647656451147/1413581508283875, (2, 1) = 29849106694/384648029465, (2, 2) = 10591394356218/9616200736625})

(6)

CCnew2 := Matrix(2, 2, {(1, 1) = 299962512141959/80776086187650, (1, 2) = -1231816081155781/8481489049703250, (2, 1) = 155175716729/549497184950, (2, 2) = 260449617208489/57697204419750})

CCnew2 := Matrix(2, 2, {(1, 1) = 299962512141959/80776086187650, (1, 2) = -1231816081155781/8481489049703250, (2, 1) = 155175716729/549497184950, (2, 2) = 260449617208489/57697204419750})

(7)

CCnew3 := Matrix(2, 2, {(1, 1) = 50445725001719/5769720441975, (1, 2) = -9065291388901/40388043093825, (2, 1) = 21111399914/39249798925, (2, 2) = 2819495262394/274748592475})

CCnew3 := Matrix(2, 2, {(1, 1) = 50445725001719/5769720441975, (1, 2) = -9065291388901/40388043093825, (2, 1) = 21111399914/39249798925, (2, 2) = 2819495262394/274748592475})

(8)

CCnew4 := Matrix(2, 2, {(1, 1) = 142685068141037/11539440883950, (1, 2) = -116560067351321/565432603313550, (2, 1) = 44654487647/78499597850, (2, 2) = 53741323977599/3846480294650})

CCnew4 := Matrix(2, 2, {(1, 1) = 142685068141037/11539440883950, (1, 2) = -116560067351321/565432603313550, (2, 1) = 44654487647/78499597850, (2, 2) = 53741323977599/3846480294650})

(9)

CCnew5 := Matrix(2, 2, {(1, 1) = 60560690824604/5769720441975, (1, 2) = -88774498025543/848148904970325, (2, 1) = 12484906049/39249798925, (2, 2) = 65745570806567/5769720441975})

CCnew5 := Matrix(2, 2, {(1, 1) = 60560690824604/5769720441975, (1, 2) = -88774498025543/848148904970325, (2, 1) = 12484906049/39249798925, (2, 2) = 65745570806567/5769720441975})

(10)

CCnew6 := Matrix(2, 2, {(1, 1) = 20398649489879/4121228887125, (1, 2) = -5446073753219/242328258562950, (2, 1) = 14465459393/196248994625, (2, 2) = 8502096238511/1648491554850})

CCnew6 := Matrix(2, 2, {(1, 1) = 20398649489879/4121228887125, (1, 2) = -5446073753219/242328258562950, (2, 1) = 14465459393/196248994625, (2, 2) = 8502096238511/1648491554850})

(11)

S*dmax

14

(12)

M1 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity), Matrix(S, S*dmax, [seq(-CCnew || n, n = 0 .. dmax-1)])])

Error, (in Matrix) this entry is too tall or too short: Matrix(2, 14, {(1, 1) = -336750255587/3769550688757, (1, 2) = 14853552191797/1696297809940650, (1, 3) = -49655436033349/56543260331355, (1, 4) = 75647656451147/1413581508283875, (1, 5) = -299962512141959/80776086187650, (1, 6) = 1231816081155781/8481489049703250, (1, 7) = -50445725001719/5769720441975, (1, 8) = 9065291388901/40388043093825, (1, 9) = -142685068141037/11539440883950, (1, 10) = 116560067351321/565432603313550, (1, 11) = -60560690824604/5769720441975, (1, 12) = 88774498025543/848148904970325, (1, 13) = -20398649489879/4121228887125, (1, 14) = 5446073753219/242328258562950, ...

 

M2 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity)])

M2 := Matrix(14, 14, {(1, 1) = 0, (1, 2) = 0, (1, 3) = 1, (1, 4) = 0, (1, 5) = 0, (1, 6) = 0, (1, 7) = 0, (1, 8) = 0, (1, 9) = 0, (1, 10) = 0, (1, 11) = 0, (1, 12) = 0, (1, 13) = 0, (1, 14) = 0, (2, 1) = 0, (2, 2) = 0, (2, 3) = 0, (2, 4) = 1, (2, 5) = 0, (2, 6) = 0, (2, 7) = 0, (2, 8) = 0, (2, 9) = 0, (2, 10) = 0, (2, 11) = 0, (2, 12) = 0, (2, 13) = 0, (2, 14) = 0, (3, 1) = 0, (3, 2) = 0, (3, 3) = 0, (3, 4) = 0, (3, 5) = 1, (3, 6) = 0, (3, 7) = 0, (3, 8) = 0, (3, 9) = 0, (3, 10) = 0, (3, 11) = 0, (3, 12) = 0, (3, 13) = 0, (3, 14) = 0, (4, 1) = 0, (4, 2) = 0, (4, 3) = 0, (4, 4) = 0, (4, 5) = 0, (4, 6) = 1, (4, 7) = 0, (4, 8) = 0, (4, 9) = 0, (4, 10) = 0, (4, 11) = 0, (4, 12) = 0, (4, 13) = 0, (4, 14) = 0, (5, 1) = 0, (5, 2) = 0, (5, 3) = 0, (5, 4) = 0, (5, 5) = 0, (5, 6) = 0, (5, 7) = 1, (5, 8) = 0, (5, 9) = 0, (5, 10) = 0, (5, 11) = 0, (5, 12) = 0, (5, 13) = 0, (5, 14) = 0, (6, 1) = 0, (6, 2) = 0, (6, 3) = 0, (6, 4) = 0, (6, 5) = 0, (6, 6) = 0, (6, 7) = 0, (6, 8) = 1, (6, 9) = 0, (6, 10) = 0, (6, 11) = 0, (6, 12) = 0, (6, 13) = 0, (6, 14) = 0, (7, 1) = 0, (7, 2) = 0, (7, 3) = 0, (7, 4) = 0, (7, 5) = 0, (7, 6) = 0, (7, 7) = 0, (7, 8) = 0, (7, 9) = 1, (7, 10) = 0, (7, 11) = 0, (7, 12) = 0, (7, 13) = 0, (7, 14) = 0, (8, 1) = 0, (8, 2) = 0, (8, 3) = 0, (8, 4) = 0, (8, 5) = 0, (8, 6) = 0, (8, 7) = 0, (8, 8) = 0, (8, 9) = 0, (8, 10) = 1, (8, 11) = 0, (8, 12) = 0, (8, 13) = 0, (8, 14) = 0, (9, 1) = 0, (9, 2) = 0, (9, 3) = 0, (9, 4) = 0, (9, 5) = 0, (9, 6) = 0, (9, 7) = 0, (9, 8) = 0, (9, 9) = 0, (9, 10) = 0, (9, 11) = 1, (9, 12) = 0, (9, 13) = 0, (9, 14) = 0, (10, 1) = 0, (10, 2) = 0, (10, 3) = 0, (10, 4) = 0, (10, 5) = 0, (10, 6) = 0, (10, 7) = 0, (10, 8) = 0, (10, 9) = 0, (10, 10) = 0, (10, 11) = 0, (10, 12) = 1, (10, 13) = 0, (10, 14) = 0, (11, 1) = 0, (11, 2) = 0, (11, 3) = 0, (11, 4) = 0, (11, 5) = 0, (11, 6) = 0, (11, 7) = 0, (11, 8) = 0, (11, 9) = 0, (11, 10) = 0, (11, 11) = 0, (11, 12) = 0, (11, 13) = 1, (11, 14) = 0, (12, 1) = 0, (12, 2) = 0, (12, 3) = 0, (12, 4) = 0, (12, 5) = 0, (12, 6) = 0, (12, 7) = 0, (12, 8) = 0, (12, 9) = 0, (12, 10) = 0, (12, 11) = 0, (12, 12) = 0, (12, 13) = 0, (12, 14) = 1, (13, 1) = 0, (13, 2) = 0, (13, 3) = 0, (13, 4) = 0, (13, 5) = 0, (13, 6) = 0, (13, 7) = 0, (13, 8) = 0, (13, 9) = 0, (13, 10) = 0, (13, 11) = 0, (13, 12) = 0, (13, 13) = 0, (13, 14) = 0, (14, 1) = 0, (14, 2) = 0, (14, 3) = 0, (14, 4) = 0, (14, 5) = 0, (14, 6) = 0, (14, 7) = 0, (14, 8) = 0, (14, 9) = 0, (14, 10) = 0, (14, 11) = 0, (14, 12) = 0, (14, 13) = 0, (14, 14) = 0})

(13)

lowerband := Matrix(S, S*dmax, [seq(-evalf(CCnew || n), n = 0 .. dmax-1)])

lowerband := Matrix(2, 14, {(1, 1) = -0.893343e-1, (1, 2) = 0.875645e-2, (1, 3) = -.878185, (1, 4) = 0.535149e-1, (1, 5) = -3.71351, (1, 6) = .145236, (1, 7) = -8.74318, (1, 8) = .224455, (1, 9) = -12.36499, (1, 10) = .206143, (1, 11) = -10.49630, (1, 12) = .104669, (1, 13) = -4.94965, (1, 14) = 0.224740e-1, (2, 1) = -0.864552e-2, (2, 2) = -.115162, (2, 3) = -0.776011e-1, (2, 4) = -1.10141, (2, 5) = -.282396, (2, 6) = -4.51408, (2, 7) = -.537873, (2, 8) = -10.26209, (2, 9) = -.568850, (2, 10) = -13.97156, (2, 11) = -.318088, (2, 12) = -11.39493, (2, 13) = -0.737097e-1, (2, 14) = -5.15750})

(14)

M3 := Matrix(S*dmax, S*dmax, [Matrix(S*(dmax-1), S), Matrix(S*(dmax-1), shape = identity), lowerband])

Error, (in Matrix) this entry is too tall or too short: Matrix(2, 14, {(1, 1) = -0.8933432215e-1, (1, 2) = 0.8756453086e-2, (1, 3) = -.8781848755, (1, 4) = 0.5351488825e-1, (1, 5) = -3.713506389, (1, 6) = .1452358276, (1, 7) = -8.743183575, (1, 8) = .224454831, (1, 9) = -12.36498974, (1, 10) = .2061431666, (1, 11) = -10.49629552, (1, 12) = .1046685287, (1, 13) = -4.949652167, (1, 14) = 0.2247395242e-1, (2, 1) = -0.8645515381e-2, (2, 2) = -.1151624586, (2, 3) = -0.7760109089e-1, (2, 4) = -1.101411529, (2, 5) = -.2823958356, (2, 6) = -4.514076892, (2, 7) = -.537872817, (2, 8) = -10.26209174, (2, 9) = -.5688498906, (2, 10) = -13.97155838, (2, 1...

 

``


Download Test_Block_matrix.mw

hi.please help me for remove error'' 

Error, illegal use of an object as a name''

 

thanks

PLATE.mw

   

Parse:-ConvertTo1D, "first argument to _Inert_ASSIGN must be assignable"

Error, illegal use of an object as a name

"restart:Digits :=15: beta:=10:alpha:=100: xi:=.5: upsilon:=0.2841945289:n:=3: aa:=1:b:=1:N_x:=0.4:N_y:=0.4:N_xy:=0: hl2:=1:mu:=65.8e9:E:=169e9: delta0:=1:delta1:=1: mus:=3:D1:=2;h:=1: lambda:=0.1: D2:=5:A1:=-2:A2:=-2:A3:=-6:A4:=7:A5:=7:A6:=7:A7:=7:A8:=8:A9:=7:A10:=7:A11:=1: A12:=1:tau:=4.730040745:t:=0: g2:=sin(theta):g3:=cos(theta):g1:=cos(theta):a:=0.0:with(Student[Calculus1]): a1:=evalf((A1*ApproximateInt(g3^2,theta=a..1,method=simpson)  ) ) : a2:= evalf(A2*ApproximateInt(g3*((ⅆ)^2)/((ⅆtheta)^2)g3,theta=a..1,method=simpson)): a3:=evalf(A3*ApproximateInt(g3*g3,theta=a..1,method=simpson)) : a4:=evalf(A4*ApproximateInt(g3*g3,theta=a..1,method=simpson)) :a5:=evalf(A5*ApproximateInt(g3^2,theta=a..1,method=simpson)) : a6:=evalf(A6*ApproximateInt(((ⅆ)^2)/((ⅆtheta)^2)g3*g3,theta=a..1,method=simpson)) :a7:=evalf(A7*ApproximateInt(g3*g3,theta=a..1,method=simpson)): a8:=evalf(A8*ApproximateInt(g3^2,theta=a..1,method=simpson)):a9:=evalf(ApproximateInt(A9*(g3*g3 )     ,theta=a..1,method=simpson)) :a10:=evalf(A10*ApproximateInt(g3*g3,theta=a..1,method=simpson)):a11:=evalf(ApproximateInt(1,theta=a..1,method=simpson)):a12:=evalf(ApproximateInt(1*(1-1/2 (1)),theta=a..1,method=simpson)):dsys3 := { f3(x)*(a1)+ f3(x)*(a2)  +((ⅆ)^2)/((ⅆx)^2) f3(x)*(a3) +f3(x)*a4+ f3(x)*(a5) +((ⅆ)^2)/((ⅆx)^2) f3(x)*(a6) +f3(x)*a7= ((ⅆ)^2)/((ⅆx)^2) f3(x) *(a8)   + a9*(ⅆ)/(ⅆx) f3(x) +f3(x)*a10+ a11+a12  , f3(1) =0,f3(0) =0 , D^(1)(f3)(1) = 0, D^(1)(f3)(0)=0,D^(3)(f3)(1) = 0, D^(3)(f3)(0)=0}    :dsol5 := dsolve(dsys3, 'maxmesh'=2024, numeric,abserr=.0001, range=0..1, output=listprocedure):fy3:= eval(f3(x),dsol5):with(CurveFitting):fy33:=PolynomialInterpolation([[0,fy3(0)],[.1,fy3(0.1)],[.2,fy3(0.2)],[0.3,fy3(0.3)],[.4,fy3(0.4)],[.5,fy3(0.5)],[0.6,fy3(0.6)],[0.7,fy3(0.7)],[0.8,fy3(0.8)],[0.9,fy3(0.9)],[1,fy3(1)]],x): d1:=A1*ApproximateInt(((ⅆ)^6)/((ⅆx)^6)fy33*fy33,x=a..1,method=simpson)   :d2:= A2*ApproximateInt(((ⅆ)^4)/((ⅆx)^4)fy33*fy33 ,x=a..1,method=simpson)   :d3:=A3*ApproximateInt(((ⅆ)^2)/((ⅆx)^2)fy33*fy33,x=a..1,method=simpson): d4:= A4*ApproximateInt(fy33*fy33,x=a..1,method=simpson):d5:=A5*ApproximateInt(((ⅆ)^4)/((ⅆx)^4)fy33*fy33,x=a..1,method=simpson)  : d6:=A6*ApproximateInt(((ⅆ)^2)/((ⅆx)^2)fy33*fy33,x=a..1,method=simpson)    :d7:=A7*ApproximateInt(fy33*fy33,x=a..1,method=simpson)  :d8:=A8*ApproximateInt(((ⅆ)^2)/((ⅆx)^2)fy33*fy33,x=a..1,method=simpson)      :d9:=ApproximateInt(A9*(((ⅆ)^1)/((ⅆx)^1)fy33*fy33 )   ,x=a..1,method=simpson) :d10:=A10*ApproximateInt(fy33*fy33,x=a..1,method=simpson)    :d11:=evalf(ApproximateInt(1,theta=a..1,method=simpson)):d12:=evalf(ApproximateInt(1*(1-1/2 (1)),theta=a..1,method=simpson))  : d sys4 := { h3(theta)*(d1)+((ⅆ)^2)/((ⅆtheta)^2) h3(theta)*(d2)+((ⅆ)^4)/((ⅆtheta)^4) h3(theta)*(d3)+ ((ⅆ)^6)/((ⅆtheta)^6) h3(theta)*(d4)+h3(theta) *(d5)+ h3(theta) *(d6) +((ⅆ)^4)/((ⅆtheta)^4) h3(theta)*(d7)= h3(theta)*(d8)  +d9*(ⅆ)/(ⅆtheta) h3(theta)  +((ⅆ)^2)/((ⅆtheta)^2) h3(theta)*(d10)  +d11+d12   ,h3(1) = 0,h3(0) = 0 , D^(1)(h3)(1) = 0, D^(1)(h3)(0)=0,D^(3)(h3)(1) = 0, D^(3)(h3)(0)=0}  :dsol6 := dsolve(dsys4, 'maxmesh'=2024, abserr=.0001, range=0..1, numeric, output=listprocedure):g33:= eval(h3(theta),dsol6):with(CurveFitting):g3:=PolynomialInterpolation([[0,g33(0)],[.1,g33(0.1)],[.2,g33(0.2)],[0.3,g33(0.3)],[.4,g33(0.4)],[.5,g33(0.5)],[0.6,g33(0.6)],[0.7,g33(0.7)],[0.8,g33(0.8)],[0.9,g33(0.9)],[1,g33(1)]],theta):"

 

 

``

 

Download PLATE.mw

I defined a procedure, OrderB(0,b,c), that essentially determines the order of a group that is defined by 2 parameters (the first parameter is always zero), so the output is an integer and the procedure is defined for every integer value of both parameters. I wanted to structure the outputs into a matrix with columns that represent one parameter and rows that represent the other. However, whenever I try to apply a method of defining the matrix, Maple returns the values of the procedure and then gives me an empty matrix.

>f:=proc (i, j) -> OrderB(0, i, j+3);
>Matrix(3, f);
                               1
                               4
                               1
                               1
                               4
                               1
                               1
                               4
                               1
               [NULL,NULL...]


I tried a second method where I defined a set s such that:

s:={(0,0)=OrderB(0,0,0) , (0,1)=OrderB(0,0,1).....}

but upon execution, maple returns:

1
4
1
....
s:={(0,0)=( ), (0,1)=( )...}

Please Help. I don't know what I'm mising in the code that is keeping Maple from putting the outputs of my procedure into the matrix.

When experimenting with Maple 2016.1, I found several issues. One I have seen on MaplePrimes before (regarding "Error, incorrect syntax in parse: `;` unexpected (near 4th character of parsed string)" when evaluating an integral, for example, or trying to plot something), but another I have not seen - it may be related to the previous issue. Below is a document that contains some of the various errors I found. What is going on? It evaluates certain things correctly, but, in the integral, it treats "x^2" like a whole new variable (the integral of x^2 with respect to x from 0 to 2 it says is 2x^2, not 8/3). The same thing results in trying to plot x^2 (not shown), giving the same error if I were to say something like "plot(t,x=0..2)" - it cannot determine the plotting variable.
 

int(x, x = 1 .. 2)`` = 3/2NULL

int(x, x = 0 .. 2) = 2NULL

"(∫)[0]^(Pi)sin(x) ⅆx"Error, incorrect syntax in parse: `;` unexpected (near 4th character of parsed string)"(∫)[0]^Pisin(x) ⅆx"

int(`#msup(mi("x"),mn("2"))`, x = 0 .. 2) = 2*`#msup(mi("x"),mn("2"))`NULL

"(∫)[0]^(2 )(x)^(2) ⅆx"Error, incorrect syntax in parse: `;` unexpected (near 4th character of parsed string)"(∫)[0]^(2 )(x)^2 ⅆx"NULL

int(x*x, x = 0 .. 2) = 8/3``NULL

int(diff(x, x, x), x = 0 .. 2) = 0NULL

``

 

Download bad_maple.mw 

 

Any ideas? Are the two things (the Error, incorrect syntax in parse: `;` unexpected (near 4th character of parsed string) message and the bad integral value) related?

 

How i need to write 

>teksbiasa:=`Hello! Bob`;

in button Action When Clicked at simple graphical interface instead of

Do(teksbiasa=%txtTeksBiasa);

because when i enter Hello! Bob in %txtTeksBiasa, system pop up ERROR

 

Error

Error in Component button with caption "Botton":

(in unknown) incorrect syntax in parse: missing operator or

`;`(near 7th character of parsed string)

 

Thank you~=]]

I have the following problem : plotting with the squareroot function somehow stops showing the whole graph as soon as the range of the input allows values less than -10, I have attached two pictures that show the transition:

 

This is still fine:

 

But here is an example where the graph is cropped:

How can I change this to get the whole graph ? Thanks a lot for your help !!

 

 

I'm trying to solve a system of two differential equations of the second order in Maple. I set it up as a system of four differential equations of the first order, but after calling for the solution, all I get back is what I entered in without receiving a solution of any sort. What do I need to fix?

Here's what I did:

_________________________________________________

> with(plots);
print(`output redirected...`); # input placeholder

> m := 0.46e-1; d := 0.42e-1; v := 60; alpha0 := 12; g := 9.81; pa := 1.205; cd := .2; n := 100; omega := 2*Pi*(1/60);
                            
> p := 6*m/(Pi*d^3);

> k1 := (3/4)*cd*pa/(d*p); k2 := (3/8)*omega*pa/p;
                                        
> gl1 := vx(t) = diff(x(t), t);                   
> gl2 := vy(t) = diff(y(t), t);
                              
> gl3 := diff(vx(t), t) = -k1*vx(t)*(vx(t)^2+vy(t)^2)^(1/2)-k2*vy(t);
 
> gl4 := diff(vy(t), t) = -g-k1*vy(t)*(vx(t)^2+vy(t)^2)^(1/2)+k2*vy(t);


> init1 := x(0) = 0;
> init2 := y(0) = 0;
> init3 := vx(0) = v*cos((1/15)*Pi);                              
> init4 := vy(0) = v*sin((1/15)*Pi);

> sol; dsolve({gl1, gl2, gl3, gl4, init1, init2, init3, init4}, {vx(t), vy(t), x(t), y(t)}, type = numeric);

> sol(.1);
                            sol(0.1)

> odeplot(sol, t, x(t), t, y(t), t = 0 .. 1);
                   Error, (in plots/odeplot) input is not a valid dsolve/numeric solution


____________________________________________________________________________

After calling for the solution at t=0.1, I don't get anything back. I also tried plotting the solution, but then I receive an error message.

So, I am working in a partial differeital equations course and we are doing image processing. I am taking an image and pixel by pixel applying the heat equation to smudge out noise. I created a for loop for the equation and it works, I need to itterate it over and over again. Here is my code:

for t from 1 to 20 do    

for j from 2 to 149 do

for k from 2 to 149 do  

`tile2__j,k`:=dellT/(h^(2))*(`tile__j+1,k`-4*`tile__j,k`+`tile__j-1,k`+`tile__j,k-1`)+`tile__j,k`  

 end do

end do  

for m from 2 to 149 do

for n from 2 to 149 do  

`tile__m,n`:= `tile2__m,n`  

end do

end do  

t := t+1  

end do

 

Sorry, I could not get the Maple Math editor to work so I just copied my code. Apologize. I keep getting the error "Error, Invalid loop statement termination." Help?

 

Hi, I have defined two functions:

ex1 := (x,t,z) -> -1.132*10^(11)* exp(9.9*10^(6)*x)*exp(sqrt(-1)*(1.95*10^6*z-2.98*10^15*t))

 

ex2 := (x,t,z) -> -2.82*10^(12)* exp(2*10^(6)*sqrt(-1)*x)*exp(sqrt(-1)*(1.95e*10^(6)*z-2.98*10^(15)*t));

 

And then tried the command:

 

implicitplot3d( ex1, x = -10..0, t = 0..10, z = 0..10, axes = boxed, style = patchcontour, scaling = constrained, shading =z);

 

But the boxes are entirely blank! What is the problem here?? It should be some kind of sine curve

Hi guys, I'm currently having a lot of trouble with Maple and can't seem to get stuff to work. I have the task of solving and modelling the Klien Gordon equation, with a chosen potential. The equation I'm trying to solve is:

> KGE := diff(psi(x, t), x, x)-(diff(psi(x, t), t, t))-12*psi(x, t)^5+10*psi(x, t)^4+6*psi(x, t)^3-3*psi(x, t)^2-psi(x, t) = 0   

I'm doing this by changing the pde into an ode via a transformation 

>tr := {t = tau, x = c*tau+z, psi(x, t) = U(z)}

>ode1 := dchange(tr, KGE, [z, tau, U(z)])

 >ode1 := collect(ode1, diff(U(z), z, z))

>c := 1/4

>ode2 := subs({U(z) = U, diff(U(z), z, z) = V(U)*(diff(V(U), U))}, ode1)

>sol := dsolve({ode2, V(0) = 0}, V(U))

>sol1:= sol[2]

>z := -c*t+x = int(1/rhs(sol2), U)

>solwave := psi(x, t) = solve(z, U)

 

I then checked if my solution, solwave actually solved the pde via pdetest(solwave,KGE) and it did. Hence this is what I took as one of the kinks. Although the kink solution looks hideous and I have no idea how to try and take the limit as x goes to infinity, as to show it tends to a vacuum of the potential. I've tried taking the limit but all Maple does is replace all the x with infinity signs... 

I then tried animating it to see if it worked, but it just looks wrong, there are breaks within the curve and also very random spikes which I cannot explain at all.. 

I tried this code exactly for the Sine Gordon equation and it works perfectly, it just all goes wrong when I try to change the potential. 

Here is a picture of the frame: 

as you can see it has spikes.. and breaks in the curve as well

----------------------------------------------------------------------------------------------

Another issue I had was with dealing with the potential on it's own, every time I try inputting  

>1/2(u^2)(1-u)^2(1+2u)^2  

into maple it changes the expression into something completely different and wrong, it somehow comes out with an exponential of 8.. This is what I get:

(1/2)*(u(1-u))(1+2*u)^8

 

----------------------------------------------------------------------------------------------

 

I also have a problem integrating, I try and plug in a value, i.e. 

>int(1/(x(1-x))(1+2*x), x)

but all this does is show me what I inputted but with a integral sign...

I'm very very new to Maple and have spent over a week doing this, but it just isn't working out at all :( Please help!! 

Hello, 

I look for a maple function / or a piece of code which enable to do repeated substitutions. In other words, repeat substitutions until there is no more possible substitution.

How can I do to make repeated substitutions ?

Here a example I would like to solve with maple

Equation on which I would like to conduct variables changements: 

Code:
eq := sin(psi[1](t)+gamma0(t))*cf+sin(gamma0(t)+theta[1](t)+psi[1](t))*mf-sin(gamma0(t))*hf-cos(gamma0(t))*lf+xp[1](t) = sin(psi[2](t)+gamma0(t))*cf+sin(gamma0(t)+theta[2](t)+psi[2](t))*mf-sin(gamma0(t))*hf-cos(gamma0(t))*lf+xp[2](t)


Definition of variables changement :

Code:
ChgtVariables:=psi[1](t)=Psi[1](t) - theta[1](t) + gamma[1](t),psi[2](t)=Psi[2](t) - theta[2](t) + gamma[2](t);psi[3](t)=Psi[3](t) - theta[3](t) + gamma[3](t),psi[4](t)=Psi[4](t) - theta[4](t) + gamma[4](t),theta[1](t)=Theta[1](t)+gamma[1](t),theta[2](t)=Theta[2](t)+gamma[2](t),theta[3](t)=Theta[3](t)+gamma[3](t),theta[4](t)=Theta[4](t)+gamma[4](t);


Application of subs function:

Code:
subs(ChgtVariables,eq);

The problem is that only one step of substitutions is conducted.

Here the expected result :

(sin(theta[1](t))-theta[2](t))*cf - (sin(gamma[1](t)-sin(gamma[2](t)))*mf  + xp[2](t) - xp[1](t) = 0

Thanks a lot for your hemp

Here is my Maple 16 code:

 I expected to get outuput

a [a,b,c]

a [a,c,b]

But I get no output.

Why?

 

 

 

Hi,

I'm trying to fill an Array but I don't know the correct syntax, and Maple help isn't much use.

How do I form an Array, A, which has 10 rows and 2 columns. Where one column is say the row number squared and the other column is the row number cubed. 

So A would be:

[1 1]
[4 8]
[9 27] .....

Also, I'm using the square and cube numbers as an example. But is there a general format for doing this, whatever the values I want to put in the array are?

Thanks


Why does "eval(c, [b=1,l=1])" turn out to be "1" not "1/1+x"??? its driving me cracy. THX

restart

 

a:=(1/(1+x/l))

1/(1+x/l)

(1)

eval(a, [l=1])

1/(1+x)

(2)

eval(a, [x=2,l=1])

1/3

(3)

c:=(1/b(1+x/l))

1/b(1+x/l)

(4)

eval(c, [b=1,l=1])

1

(5)

 



 

1 2 3 4 5 6 7 Page 1 of 7