MaplePrimes Questions

Dear maple users

A fine day wishes to all 

In my problem, L(z) is a piecewise condition.

L(z):

I have to calculate the f(x,t) value at x=0.71,t=1.12 and z=0.71 for L(z)=0..1.

How to calculate the f(x,t) value.JVB1.mw
 

restart:

with(PDEtools):

with(plots):

fcns := {f(x,t)};

{f(x, t)}

(1)

b1:=1.41:d:=0.5/1:xi:=0.1:ea:=0.5:ra:=2:

L:=z->piecewise(d<=z,1-2*xi*(cos((2*3.14)*((z-d)*(1/2))-1/4)-(7/100)*cos((32*3.14)*(z-d-1/2))),z<=d+1,1-2*xi*(cos((2*3.14)*((z-d)*(1/2))-1/4)-(7/100)*cos((32*3.14)*(z-d-1/2))),1);

proc (z) options operator, arrow; piecewise(d <= z, 1-2*xi*(cos(2*3.14*((1/2)*z-(1/2)*d)-1/4)-(7/100)*cos(32*3.14*(z-d-1/2))), z <= d+1, 1-2*xi*(cos(2*3.14*((1/2)*z-(1/2)*d)-1/4)-(7/100)*cos(32*3.14*(z-d-1/2))), 1) end proc

(2)

PDE1 :=ra*(diff(f(x,t),t))=+b1*(1+ea*cos(t))+(1/(L(z)^2))*((diff(f(x,t),x,x))+(1/x)*diff(f(x,t),x));

PDE1 := 2*(diff(f(x, t), t)) = 1.41+.705*cos(t)+(diff(f(x, t), x, x)+(diff(f(x, t), x))/x)/piecewise(.5 <= z, 1-.2*cos(3.140000000*z-1.820000000)+0.1400000000e-1*cos(100.48*z-100.4800000), z <= 1.5, 1-.2*cos(3.140000000*z-1.820000000)+0.1400000000e-1*cos(100.48*z-100.4800000), 1)^2

(3)

IBC := {D[1](f)(0,t)=0,f(1,t)=0,f(x,0)=0};

{f(1, t) = 0, f(x, 0) = 0, (D[1](f))(0, t) = 0}

(4)

z:=0.71;

.71

(5)

sol:=pdsolve(eval([PDE1]),IBC ,numeric, time = t,spacestep = 0.025, timestep=0.0001):
sol:-value(f(x,t), output=listprocedure);

[x = proc () option `Copyright (c) 2000 by Waterloo Maple Inc. All rights reserved.`; evalf(args[1]) end proc, t = proc () option `Copyright (c) 2000 by Waterloo Maple Inc. All rights reserved.`; evalf(args[2]) end proc, f(x, t) = proc () local tv, xv, solnproc, stype, ndsol, vals; option `Copyright (c) 2001 by Waterloo Maple Inc. All rights reserved.`; Digits := trunc(evalhf(Digits)); solnproc := proc (tv, xv) local INFO, errest, nd, dvars, dary, daryt, daryx, vals, msg, i, j; option `Copyright (c) 2001 by Waterloo Maple Inc. All rights reserved.`; table( [( "soln_procedures" ) = array( 1 .. 1, [( 1 ) = (4337711746)  ] ) ] ) INFO := table( [( "indepvars" ) = [x, t], ( "depshift" ) = [1], ( "spacestep" ) = 0.250000000000000e-1, ( "depeqn" ) = [1], ( "solmat_is" ) = 0, ( "solvec3" ) = Vector(41, {(1) = .0, (2) = .0, (3) = .0, (4) = .0, (5) = .0, (6) = .0, (7) = .0, (8) = .0, (9) = .0, (10) = .0, (11) = .0, (12) = .0, (13) = .0, (14) = .0, (15) = .0, (16) = .0, (17) = .0, (18) = .0, (19) = .0, (20) = .0, (21) = .0, (22) = .0, (23) = .0, (24) = .0, (25) = .0, (26) = .0, (27) = .0, (28) = .0, (29) = .0, (30) = .0, (31) = .0, (32) = .0, (33) = .0, (34) = .0, (35) = .0, (36) = .0, (37) = .0, (38) = .0, (39) = .0, (40) = .0, (41) = .0}, datatype = float[8]), ( "theta" ) = 1/2, ( "matrixhf" ) = true, ( "eqndep" ) = [1], ( "errorest" ) = false, ( "vectorhf" ) = true, ( "spaceadaptive" ) = false, ( "solspace" ) = Vector(41, {(1) = .0, (2) = .0, (3) = .0, (4) = .0, (5) = .0, (6) = .0, (7) = .0, (8) = .0, (9) = .0, (10) = .0, (11) = .0, (12) = .0, (13) = .0, (14) = .0, (15) = .0, (16) = .0, (17) = .0, (18) = .0, (19) = .0, (20) = .0, (21) = .0, (22) = .0, (23) = .0, (24) = .0, (25) = .0, (26) = .0, (27) = .0, (28) = .0, (29) = .0, (30) = .0, (31) = .0, (32) = .0, (33) = .0, (34) = .0, (35) = .0, (36) = .0, (37) = .0, (38) = .0, (39) = .0, (40) = .0, (41) = 1.0}, datatype = float[8]), ( "multidep" ) = [false, false], ( "solvec2" ) = Vector(41, {(1) = .0, (2) = .0, (3) = .0, (4) = .0, (5) = .0, (6) = .0, (7) = .0, (8) = .0, (9) = .0, (10) = .0, (11) = .0, (12) = .0, (13) = .0, (14) = .0, (15) = .0, (16) = .0, (17) = .0, (18) = .0, (19) = .0, (20) = .0, (21) = .0, (22) = .0, (23) = .0, (24) = .0, (25) = .0, (26) = .0, (27) = .0, (28) = .0, (29) = .0, (30) = .0, (31) = .0, (32) = .0, (33) = .0, (34) = .0, (35) = .0, (36) = .0, (37) = .0, (38) = .0, (39) = .0, (40) = .0, (41) = .0}, datatype = float[8]), ( "solmat_i2" ) = 0, ( "intspace" ) = Matrix(41, 1, {(1, 1) = .0, (2, 1) = .0, (3, 1) = .0, (4, 1) = .0, (5, 1) = .0, (6, 1) = .0, (7, 1) = .0, (8, 1) = .0, (9, 1) = .0, (10, 1) = .0, (11, 1) = .0, (12, 1) = .0, (13, 1) = .0, (14, 1) = .0, (15, 1) = .0, (16, 1) = .0, (17, 1) = .0, (18, 1) = .0, (19, 1) = .0, (20, 1) = .0, (21, 1) = .0, (22, 1) = .0, (23, 1) = .0, (24, 1) = .0, (25, 1) = .0, (26, 1) = .0, (27, 1) = .0, (28, 1) = .0, (29, 1) = .0, (30, 1) = .0, (31, 1) = .0, (32, 1) = .0, (33, 1) = .0, (34, 1) = .0, (35, 1) = .0, (36, 1) = .0, (37, 1) = .0, (38, 1) = .0, (39, 1) = .0, (40, 1) = .0, (41, 1) = .0}, datatype = float[8], order = C_order), ( "solmat_i1" ) = 0, ( "erroraccum" ) = true, ( "solmatrix" ) = Matrix(41, 7, {(1, 1) = .0, (1, 2) = .0, (1, 3) = .0, (1, 4) = .0, (1, 5) = .0, (1, 6) = .0, (1, 7) = .0, (2, 1) = .0, (2, 2) = .0, (2, 3) = .0, (2, 4) = .0, (2, 5) = .0, (2, 6) = .0, (2, 7) = .0, (3, 1) = .0, (3, 2) = .0, (3, 3) = .0, (3, 4) = .0, (3, 5) = .0, (3, 6) = .0, (3, 7) = .0, (4, 1) = .0, (4, 2) = .0, (4, 3) = .0, (4, 4) = .0, (4, 5) = .0, (4, 6) = .0, (4, 7) = .0, (5, 1) = .0, (5, 2) = .0, (5, 3) = .0, (5, 4) = .0, (5, 5) = .0, (5, 6) = .0, (5, 7) = .0, (6, 1) = .0, (6, 2) = .0, (6, 3) = .0, (6, 4) = .0, (6, 5) = .0, (6, 6) = .0, (6, 7) = .0, (7, 1) = .0, (7, 2) = .0, (7, 3) = .0, (7, 4) = .0, (7, 5) = .0, (7, 6) = .0, (7, 7) = .0, (8, 1) = .0, (8, 2) = .0, (8, 3) = .0, (8, 4) = .0, (8, 5) = .0, (8, 6) = .0, (8, 7) = .0, (9, 1) = .0, (9, 2) = .0, (9, 3) = .0, (9, 4) = .0, (9, 5) = .0, (9, 6) = .0, (9, 7) = .0, (10, 1) = .0, (10, 2) = .0, (10, 3) = .0, (10, 4) = .0, (10, 5) = .0, (10, 6) = .0, (10, 7) = .0, (11, 1) = .0, (11, 2) = .0, (11, 3) = .0, (11, 4) = .0, (11, 5) = .0, (11, 6) = .0, (11, 7) = .0, (12, 1) = .0, (12, 2) = .0, (12, 3) = .0, (12, 4) = .0, (12, 5) = .0, (12, 6) = .0, (12, 7) = .0, (13, 1) = .0, (13, 2) = .0, (13, 3) = .0, (13, 4) = .0, (13, 5) = .0, (13, 6) = .0, (13, 7) = .0, (14, 1) = .0, (14, 2) = .0, (14, 3) = .0, (14, 4) = .0, (14, 5) = .0, (14, 6) = .0, (14, 7) = .0, (15, 1) = .0, (15, 2) = .0, (15, 3) = .0, (15, 4) = .0, (15, 5) = .0, (15, 6) = .0, (15, 7) = .0, (16, 1) = .0, (16, 2) = .0, (16, 3) = .0, (16, 4) = .0, (16, 5) = .0, (16, 6) = .0, (16, 7) = .0, (17, 1) = .0, (17, 2) = .0, (17, 3) = .0, (17, 4) = .0, (17, 5) = .0, (17, 6) = .0, (17, 7) = .0, (18, 1) = .0, (18, 2) = .0, (18, 3) = .0, (18, 4) = .0, (18, 5) = .0, (18, 6) = .0, (18, 7) = .0, (19, 1) = .0, (19, 2) = .0, (19, 3) = .0, (19, 4) = .0, (19, 5) = .0, (19, 6) = .0, (19, 7) = .0, (20, 1) = .0, (20, 2) = .0, (20, 3) = .0, (20, 4) = .0, (20, 5) = .0, (20, 6) = .0, (20, 7) = .0, (21, 1) = .0, (21, 2) = .0, (21, 3) = .0, (21, 4) = .0, (21, 5) = .0, (21, 6) = .0, (21, 7) = .0, (22, 1) = .0, (22, 2) = .0, (22, 3) = .0, (22, 4) = .0, (22, 5) = .0, (22, 6) = .0, (22, 7) = .0, (23, 1) = .0, (23, 2) = .0, (23, 3) = .0, (23, 4) = .0, (23, 5) = .0, (23, 6) = .0, (23, 7) = .0, (24, 1) = .0, (24, 2) = .0, (24, 3) = .0, (24, 4) = .0, (24, 5) = .0, (24, 6) = .0, (24, 7) = .0, (25, 1) = .0, (25, 2) = .0, (25, 3) = .0, (25, 4) = .0, (25, 5) = .0, (25, 6) = .0, (25, 7) = .0, (26, 1) = .0, (26, 2) = .0, (26, 3) = .0, (26, 4) = .0, (26, 5) = .0, (26, 6) = .0, (26, 7) = .0, (27, 1) = .0, (27, 2) = .0, (27, 3) = .0, (27, 4) = .0, (27, 5) = .0, (27, 6) = .0, (27, 7) = .0, (28, 1) = .0, (28, 2) = .0, (28, 3) = .0, (28, 4) = .0, (28, 5) = .0, (28, 6) = .0, (28, 7) = .0, (29, 1) = .0, (29, 2) = .0, (29, 3) = .0, (29, 4) = .0, (29, 5) = .0, (29, 6) = .0, (29, 7) = .0, (30, 1) = .0, (30, 2) = .0, (30, 3) = .0, (30, 4) = .0, (30, 5) = .0, (30, 6) = .0, (30, 7) = .0, (31, 1) = .0, (31, 2) = .0, (31, 3) = .0, (31, 4) = .0, (31, 5) = .0, (31, 6) = .0, (31, 7) = .0, (32, 1) = .0, (32, 2) = .0, (32, 3) = .0, (32, 4) = .0, (32, 5) = .0, (32, 6) = .0, (32, 7) = .0, (33, 1) = .0, (33, 2) = .0, (33, 3) = .0, (33, 4) = .0, (33, 5) = .0, (33, 6) = .0, (33, 7) = .0, (34, 1) = .0, (34, 2) = .0, (34, 3) = .0, (34, 4) = .0, (34, 5) = .0, (34, 6) = .0, (34, 7) = .0, (35, 1) = .0, (35, 2) = .0, (35, 3) = .0, (35, 4) = .0, (35, 5) = .0, (35, 6) = .0, (35, 7) = .0, (36, 1) = .0, (36, 2) = .0, (36, 3) = .0, (36, 4) = .0, (36, 5) = .0, (36, 6) = .0, (36, 7) = .0, (37, 1) = .0, (37, 2) = .0, (37, 3) = .0, (37, 4) = .0, (37, 5) = .0, (37, 6) = .0, (37, 7) = .0, (38, 1) = .0, (38, 2) = .0, (38, 3) = .0, (38, 4) = .0, (38, 5) = .0, (38, 6) = .0, (38, 7) = .0, (39, 1) = .0, (39, 2) = .0, (39, 3) = .0, (39, 4) = .0, (39, 5) = .0, (39, 6) = .0, (39, 7) = .0, (40, 1) = .0, (40, 2) = .0, (40, 3) = .0, (40, 4) = .0, (40, 5) = .0, (40, 6) = .0, (40, 7) = .0, (41, 1) = .0, (41, 2) = .0, (41, 3) = .0, (41, 4) = .0, (41, 5) = .0, (41, 6) = .0, (41, 7) = .0}, datatype = float[8], order = C_order), ( "leftwidth" ) = 1, ( "adjusted" ) = false, ( "totalwidth" ) = 7, ( "solmat_v" ) = Vector(287, {(1) = .0, (2) = .0, (3) = .0, (4) = .0, (5) = .0, (6) = .0, (7) = .0, (8) = .0, (9) = .0, (10) = .0, (11) = .0, (12) = .0, (13) = .0, (14) = .0, (15) = .0, (16) = .0, (17) = .0, (18) = .0, (19) = .0, (20) = .0, (21) = .0, (22) = .0, (23) = .0, (24) = .0, (25) = .0, (26) = .0, (27) = .0, (28) = .0, (29) = .0, (30) = .0, (31) = .0, (32) = .0, (33) = .0, (34) = .0, (35) = .0, (36) = .0, (37) = .0, (38) = .0, (39) = .0, (40) = .0, (41) = .0, (42) = .0, (43) = .0, (44) = .0, (45) = .0, (46) = .0, (47) = .0, (48) = .0, (49) = .0, (50) = .0, (51) = .0, (52) = .0, (53) = .0, (54) = .0, (55) = .0, (56) = .0, (57) = .0, (58) = .0, (59) = .0, (60) = .0, (61) = .0, (62) = .0, (63) = .0, (64) = .0, (65) = .0, (66) = .0, (67) = .0, (68) = .0, (69) = .0, (70) = .0, (71) = .0, (72) = .0, (73) = .0, (74) = .0, (75) = .0, (76) = .0, (77) = .0, (78) = .0, (79) = .0, (80) = .0, (81) = .0, (82) = .0, (83) = .0, (84) = .0, (85) = .0, (86) = .0, (87) = .0, (88) = .0, (89) = .0, (90) = .0, (91) = .0, (92) = .0, (93) = .0, (94) = .0, (95) = .0, (96) = .0, (97) = .0, (98) = .0, (99) = .0, (100) = .0, (101) = .0, (102) = .0, (103) = .0, (104) = .0, (105) = .0, (106) = .0, (107) = .0, (108) = .0, (109) = .0, (110) = .0, (111) = .0, (112) = .0, (113) = .0, (114) = .0, (115) = .0, (116) = .0, (117) = .0, (118) = .0, (119) = .0, (120) = .0, (121) = .0, (122) = .0, (123) = .0, (124) = .0, (125) = .0, (126) = .0, (127) = .0, (128) = .0, (129) = .0, (130) = .0, (131) = .0, (132) = .0, (133) = .0, (134) = .0, (135) = .0, (136) = .0, (137) = .0, (138) = .0, (139) = .0, (140) = .0, (141) = .0, (142) = .0, (143) = .0, (144) = .0, (145) = .0, (146) = .0, (147) = .0, (148) = .0, (149) = .0, (150) = .0, (151) = .0, (152) = .0, (153) = .0, (154) = .0, (155) = .0, (156) = .0, (157) = .0, (158) = .0, (159) = .0, (160) = .0, (161) = .0, (162) = .0, (163) = .0, (164) = .0, (165) = .0, (166) = .0, (167) = .0, (168) = .0, (169) = .0, (170) = .0, (171) = .0, (172) = .0, (173) = .0, (174) = .0, (175) = .0, (176) = .0, (177) = .0, (178) = .0, (179) = .0, (180) = .0, (181) = .0, (182) = .0, (183) = .0, (184) = .0, (185) = .0, (186) = .0, (187) = .0, (188) = .0, (189) = .0, (190) = .0, (191) = .0, (192) = .0, (193) = .0, (194) = .0, (195) = .0, (196) = .0, (197) = .0, (198) = .0, (199) = .0, (200) = .0, (201) = .0, (202) = .0, (203) = .0, (204) = .0, (205) = .0, (206) = .0, (207) = .0, (208) = .0, (209) = .0, (210) = .0, (211) = .0, (212) = .0, (213) = .0, (214) = .0, (215) = .0, (216) = .0, (217) = .0, (218) = .0, (219) = .0, (220) = .0, (221) = .0, (222) = .0, (223) = .0, (224) = .0, (225) = .0, (226) = .0, (227) = .0, (228) = .0, (229) = .0, (230) = .0, (231) = .0, (232) = .0, (233) = .0, (234) = .0, (235) = .0, (236) = .0, (237) = .0, (238) = .0, (239) = .0, (240) = .0, (241) = .0, (242) = .0, (243) = .0, (244) = .0, (245) = .0, (246) = .0, (247) = .0, (248) = .0, (249) = .0, (250) = .0, (251) = .0, (252) = .0, (253) = .0, (254) = .0, (255) = .0, (256) = .0, (257) = .0, (258) = .0, (259) = .0, (260) = .0, (261) = .0, (262) = .0, (263) = .0, (264) = .0, (265) = .0, (266) = .0, (267) = .0, (268) = .0, (269) = .0, (270) = .0, (271) = .0, (272) = .0, (273) = .0, (274) = .0, (275) = .0, (276) = .0, (277) = .0, (278) = .0, (279) = .0, (280) = .0, (281) = .0, (282) = .0, (283) = .0, (284) = .0, (285) = .0, (286) = .0, (287) = .0}, datatype = float[8], order = C_order, attributes = [source_rtable = (Matrix(41, 7, {(1, 1) = .0, (1, 2) = .0, (1, 3) = .0, (1, 4) = .0, (1, 5) = .0, (1, 6) = .0, (1, 7) = .0, (2, 1) = .0, (2, 2) = .0, (2, 3) = .0, (2, 4) = .0, (2, 5) = .0, (2, 6) = .0, (2, 7) = .0, (3, 1) = .0, (3, 2) = .0, (3, 3) = .0, (3, 4) = .0, (3, 5) = .0, (3, 6) = .0, (3, 7) = .0, (4, 1) = .0, (4, 2) = .0, (4, 3) = .0, (4, 4) = .0, (4, 5) = .0, (4, 6) = .0, (4, 7) = .0, (5, 1) = .0, (5, 2) = .0, (5, 3) = .0, (5, 4) = .0, (5, 5) = .0, (5, 6) = .0, (5, 7) = .0, (6, 1) = .0, (6, 2) = .0, (6, 3) = .0, (6, 4) = .0, (6, 5) = .0, (6, 6) = .0, (6, 7) = .0, (7, 1) = .0, (7, 2) = .0, (7, 3) = .0, (7, 4) = .0, (7, 5) = .0, (7, 6) = .0, (7, 7) = .0, (8, 1) = .0, (8, 2) = .0, (8, 3) = .0, (8, 4) = .0, (8, 5) = .0, (8, 6) = .0, (8, 7) = .0, (9, 1) = .0, (9, 2) = .0, (9, 3) = .0, (9, 4) = .0, (9, 5) = .0, (9, 6) = .0, (9, 7) = .0, (10, 1) = .0, (10, 2) = .0, (10, 3) = .0, (10, 4) = .0, (10, 5) = .0, (10, 6) = .0, (10, 7) = .0, (11, 1) = .0, (11, 2) = .0, (11, 3) = .0, (11, 4) = .0, (11, 5) = .0, (11, 6) = .0, (11, 7) = .0, (12, 1) = .0, (12, 2) = .0, (12, 3) = .0, (12, 4) = .0, (12, 5) = .0, (12, 6) = .0, (12, 7) = .0, (13, 1) = .0, (13, 2) = .0, (13, 3) = .0, (13, 4) = .0, (13, 5) = .0, (13, 6) = .0, (13, 7) = .0, (14, 1) = .0, (14, 2) = .0, (14, 3) = .0, (14, 4) = .0, (14, 5) = .0, (14, 6) = .0, (14, 7) = .0, (15, 1) = .0, (15, 2) = .0, (15, 3) = .0, (15, 4) = .0, (15, 5) = .0, (15, 6) = .0, (15, 7) = .0, (16, 1) = .0, (16, 2) = .0, (16, 3) = .0, (16, 4) = .0, (16, 5) = .0, (16, 6) = .0, (16, 7) = .0, (17, 1) = .0, (17, 2) = .0, (17, 3) = .0, (17, 4) = .0, (17, 5) = .0, (17, 6) = .0, (17, 7) = .0, (18, 1) = .0, (18, 2) = .0, (18, 3) = .0, (18, 4) = .0, (18, 5) = .0, (18, 6) = .0, (18, 7) = .0, (19, 1) = .0, (19, 2) = .0, (19, 3) = .0, (19, 4) = .0, (19, 5) = .0, (19, 6) = .0, (19, 7) = .0, (20, 1) = .0, (20, 2) = .0, (20, 3) = .0, (20, 4) = .0, (20, 5) = .0, (20, 6) = .0, (20, 7) = .0, (21, 1) = .0, (21, 2) = .0, (21, 3) = .0, (21, 4) = .0, (21, 5) = .0, (21, 6) = .0, (21, 7) = .0, (22, 1) = .0, (22, 2) = .0, (22, 3) = .0, (22, 4) = .0, (22, 5) = .0, (22, 6) = .0, (22, 7) = .0, (23, 1) = .0, (23, 2) = .0, (23, 3) = .0, (23, 4) = .0, (23, 5) = .0, (23, 6) = .0, (23, 7) = .0, (24, 1) = .0, (24, 2) = .0, (24, 3) = .0, (24, 4) = .0, (24, 5) = .0, (24, 6) = .0, (24, 7) = .0, (25, 1) = .0, (25, 2) = .0, (25, 3) = .0, (25, 4) = .0, (25, 5) = .0, (25, 6) = .0, (25, 7) = .0, (26, 1) = .0, (26, 2) = .0, (26, 3) = .0, (26, 4) = .0, (26, 5) = .0, (26, 6) = .0, (26, 7) = .0, (27, 1) = .0, (27, 2) = .0, (27, 3) = .0, (27, 4) = .0, (27, 5) = .0, (27, 6) = .0, (27, 7) = .0, (28, 1) = .0, (28, 2) = .0, (28, 3) = .0, (28, 4) = .0, (28, 5) = .0, (28, 6) = .0, (28, 7) = .0, (29, 1) = .0, (29, 2) = .0, (29, 3) = .0, (29, 4) = .0, (29, 5) = .0, (29, 6) = .0, (29, 7) = .0, (30, 1) = .0, (30, 2) = .0, (30, 3) = .0, (30, 4) = .0, (30, 5) = .0, (30, 6) = .0, (30, 7) = .0, (31, 1) = .0, (31, 2) = .0, (31, 3) = .0, (31, 4) = .0, (31, 5) = .0, (31, 6) = .0, (31, 7) = .0, (32, 1) = .0, (32, 2) = .0, (32, 3) = .0, (32, 4) = .0, (32, 5) = .0, (32, 6) = .0, (32, 7) = .0, (33, 1) = .0, (33, 2) = .0, (33, 3) = .0, (33, 4) = .0, (33, 5) = .0, (33, 6) = .0, (33, 7) = .0, (34, 1) = .0, (34, 2) = .0, (34, 3) = .0, (34, 4) = .0, (34, 5) = .0, (34, 6) = .0, (34, 7) = .0, (35, 1) = .0, (35, 2) = .0, (35, 3) = .0, (35, 4) = .0, (35, 5) = .0, (35, 6) = .0, (35, 7) = .0, (36, 1) = .0, (36, 2) = .0, (36, 3) = .0, (36, 4) = .0, (36, 5) = .0, (36, 6) = .0, (36, 7) = .0, (37, 1) = .0, (37, 2) = .0, (37, 3) = .0, (37, 4) = .0, (37, 5) = .0, (37, 6) = .0, (37, 7) = .0, (38, 1) = .0, (38, 2) = .0, (38, 3) = .0, (38, 4) = .0, (38, 5) = .0, (38, 6) = .0, (38, 7) = .0, (39, 1) = .0, (39, 2) = .0, (39, 3) = .0, (39, 4) = .0, (39, 5) = .0, (39, 6) = .0, (39, 7) = .0, (40, 1) = .0, (40, 2) = .0, (40, 3) = .0, (40, 4) = .0, (40, 5) = .0, (40, 6) = .0, (40, 7) = .0, (41, 1) = .0, (41, 2) = .0, (41, 3) = .0, (41, 4) = .0, (41, 5) = .0, (41, 6) = .0, (41, 7) = .0}, datatype = float[8], order = C_order))]), ( "stages" ) = 1, ( "solmat_ne" ) = 0, ( "allocspace" ) = 41, ( "PDEs" ) = [2*(diff(f(x, t), t))-141/100-(141/200)*cos(t)-(1533816497/1000000000)*(diff(diff(f(x, t), x), x))-(1533816497/1000000000)*(diff(f(x, t), x))/x], ( "method" ) = theta, ( "minspcpoints" ) = 4, ( "vectorproc" ) = proc (v, vp, vpp, t, x, k, h, n, vec) local _s1, _s2, _s3, _s4, _s5, _s6, _s7, _s8, xi; _s1 := cos(t+(1/2)*k); _s4 := 3067632994*k; _s5 := 8000000000*h^2; _s6 := 1533816497*h*k; _s7 := 4000000000*k*h^2; _s8 := 2820000000*k*h^2*(_s1+2); vec[1] := 0; vec[n] := 0; for xi from 2 to n-1 do _s2 := -vp[xi-1]+vp[xi+1]; _s3 := vp[xi-1]-2*vp[xi]+vp[xi+1]; vec[xi] := (_s3*_s4*x[xi]+_s5*vp[xi]*x[xi]+_s2*_s6+_s8*x[xi])/(_s7*x[xi]) end do end proc, ( "t0" ) = 0, ( "rightwidth" ) = 0, ( "solvec1" ) = Vector(41, {(1) = .0, (2) = .0, (3) = .0, (4) = .0, (5) = .0, (6) = .0, (7) = .0, (8) = .0, (9) = .0, (10) = .0, (11) = .0, (12) = .0, (13) = .0, (14) = .0, (15) = .0, (16) = .0, (17) = .0, (18) = .0, (19) = .0, (20) = .0, (21) = .0, (22) = .0, (23) = .0, (24) = .0, (25) = .0, (26) = .0, (27) = .0, (28) = .0, (29) = .0, (30) = .0, (31) = .0, (32) = .0, (33) = .0, (34) = .0, (35) = .0, (36) = .0, (37) = .0, (38) = .0, (39) = .0, (40) = .0, (41) = .0}, datatype = float[8]), ( "linear" ) = true, ( "timeidx" ) = 2, ( "spacevar" ) = x, ( "timeadaptive" ) = false, ( "startup_only" ) = false, ( "initialized" ) = false, ( "solvec4" ) = 0, ( "solution" ) = Array(1..3, 1..41, 1..1, {(1, 1, 1) = .0, (1, 2, 1) = .0, (1, 3, 1) = .0, (1, 4, 1) = .0, (1, 5, 1) = .0, (1, 6, 1) = .0, (1, 7, 1) = .0, (1, 8, 1) = .0, (1, 9, 1) = .0, (1, 10, 1) = .0, (1, 11, 1) = .0, (1, 12, 1) = .0, (1, 13, 1) = .0, (1, 14, 1) = .0, (1, 15, 1) = .0, (1, 16, 1) = .0, (1, 17, 1) = .0, (1, 18, 1) = .0, (1, 19, 1) = .0, (1, 20, 1) = .0, (1, 21, 1) = .0, (1, 22, 1) = .0, (1, 23, 1) = .0, (1, 24, 1) = .0, (1, 25, 1) = .0, (1, 26, 1) = .0, (1, 27, 1) = .0, (1, 28, 1) = .0, (1, 29, 1) = .0, (1, 30, 1) = .0, (1, 31, 1) = .0, (1, 32, 1) = .0, (1, 33, 1) = .0, (1, 34, 1) = .0, (1, 35, 1) = .0, (1, 36, 1) = .0, (1, 37, 1) = .0, (1, 38, 1) = .0, (1, 39, 1) = .0, (1, 40, 1) = .0, (1, 41, 1) = .0, (2, 1, 1) = .0, (2, 2, 1) = .0, (2, 3, 1) = .0, (2, 4, 1) = .0, (2, 5, 1) = .0, (2, 6, 1) = .0, (2, 7, 1) = .0, (2, 8, 1) = .0, (2, 9, 1) = .0, (2, 10, 1) = .0, (2, 11, 1) = .0, (2, 12, 1) = .0, (2, 13, 1) = .0, (2, 14, 1) = .0, (2, 15, 1) = .0, (2, 16, 1) = .0, (2, 17, 1) = .0, (2, 18, 1) = .0, (2, 19, 1) = .0, (2, 20, 1) = .0, (2, 21, 1) = .0, (2, 22, 1) = .0, (2, 23, 1) = .0, (2, 24, 1) = .0, (2, 25, 1) = .0, (2, 26, 1) = .0, (2, 27, 1) = .0, (2, 28, 1) = .0, (2, 29, 1) = .0, (2, 30, 1) = .0, (2, 31, 1) = .0, (2, 32, 1) = .0, (2, 33, 1) = .0, (2, 34, 1) = .0, (2, 35, 1) = .0, (2, 36, 1) = .0, (2, 37, 1) = .0, (2, 38, 1) = .0, (2, 39, 1) = .0, (2, 40, 1) = .0, (2, 41, 1) = .0, (3, 1, 1) = .0, (3, 2, 1) = .0, (3, 3, 1) = .0, (3, 4, 1) = .0, (3, 5, 1) = .0, (3, 6, 1) = .0, (3, 7, 1) = .0, (3, 8, 1) = .0, (3, 9, 1) = .0, (3, 10, 1) = .0, (3, 11, 1) = .0, (3, 12, 1) = .0, (3, 13, 1) = .0, (3, 14, 1) = .0, (3, 15, 1) = .0, (3, 16, 1) = .0, (3, 17, 1) = .0, (3, 18, 1) = .0, (3, 19, 1) = .0, (3, 20, 1) = .0, (3, 21, 1) = .0, (3, 22, 1) = .0, (3, 23, 1) = .0, (3, 24, 1) = .0, (3, 25, 1) = .0, (3, 26, 1) = .0, (3, 27, 1) = .0, (3, 28, 1) = .0, (3, 29, 1) = .0, (3, 30, 1) = .0, (3, 31, 1) = .0, (3, 32, 1) = .0, (3, 33, 1) = .0, (3, 34, 1) = .0, (3, 35, 1) = .0, (3, 36, 1) = .0, (3, 37, 1) = .0, (3, 38, 1) = .0, (3, 39, 1) = .0, (3, 40, 1) = .0, (3, 41, 1) = .0}, datatype = float[8], order = C_order), ( "norigdepvars" ) = 1, ( "mixed" ) = false, ( "bandwidth" ) = [1, 3], ( "extrabcs" ) = [0], ( "depdords" ) = [[[2, 1]]], ( "solvec5" ) = 0, ( "spacepts" ) = 41, ( "spaceidx" ) = 1, ( "timestep" ) = 0.1e-3, ( "inputargs" ) = [[2*(diff(f(x, t), t)) = 1.41+.705*cos(t)+1.533816497*(diff(diff(f(x, t), x), x))+1.533816497*(diff(f(x, t), x))/x], {f(1, t) = 0, f(x, 0) = 0, (D[1](f))(0, t) = 0}, time = t, spacestep = 0.25e-1, timestep = 0.1e-3], ( "maxords" ) = [2, 1], ( "timevar" ) = t, ( "BCS", 1 ) = {[[1, 0, 1], b[1, 0, 1]], [[1, 1, 0], b[1, 1, 0]]}, ( "eqnords" ) = [[2, 1]], ( "soltimes" ) = Vector(3, {(1) = .0, (2) = .0, (3) = .0}, datatype = float[8]), ( "periodic" ) = false, ( "depords" ) = [[2, 1]], ( "ICS" ) = [0], ( "fdepvars" ) = [f(x, t)], ( "depvars" ) = [f], ( "dependson" ) = [{1}], ( "autonomous" ) = true, ( "matrixproc" ) = proc (v, vp, vpp, t, x, k, h, n, mat) local _s1, _s2, _s3, xi; _s1 := -1533816497*h; _s2 := 4000000000*h^2; _s3 := (1/1000000000)*(2000000000*h^2+1533816497*k)/(k*h^2); mat[3] := -(3/2)/h; mat[4] := 2/h; mat[5] := -(1/2)/h; mat[7*n-4] := 1; for xi from 2 to n-1 do mat[7*xi-4] := _s3; mat[7*xi-5] := -(_s1+3067632994*x[xi])/(_s2*x[xi]); mat[7*xi-3] := (_s1-3067632994*x[xi])/(_s2*x[xi]) end do end proc, ( "explicit" ) = false, ( "banded" ) = true, ( "pts", x ) = [0, 1], ( "IBC" ) = b ] ); if xv = "left" then return INFO["solspace"][1] elif xv = "right" then return INFO["solspace"][INFO["spacepts"]] elif tv = "start" then return INFO["t0"] elif not (type(tv, 'numeric') and type(xv, 'numeric')) then error "non-numeric input" end if; if xv < INFO["solspace"][1] or INFO["solspace"][INFO["spacepts"]] < xv then error "requested %1 value must be in the range %2..%3", INFO["spacevar"], INFO["solspace"][1], INFO["solspace"][INFO["spacepts"]] end if; dary := Vector(3, {(1) = .0, (2) = .0, (3) = .0}, datatype = float[8]); daryt := 0; daryx := 0; dvars := [proc (t, x, u) u[1] end proc]; errest := false; nd := nops(INFO["depvars"]); if dary[nd+1] <> tv then try `pdsolve/numeric/evolve_solution`(INFO, tv) catch: msg := StringTools:-FormatMessage(lastexception[2 .. -1]); if tv < INFO["t0"] then error cat("unable to compute solution for %1<%2:
", msg), INFO["timevar"], INFO["failtime"] else error cat("unable to compute solution for %1>%2:
", msg), INFO["timevar"], INFO["failtime"] end if end try end if; if dary[nd+1] <> tv or dary[nd+2] <> xv then `pdsolve/interp2dto0d`(3, INFO["soltimes"], INFO["spacepts"], INFO["solspace"], nops(INFO["depvars"]), INFO["solution"], true, tv, xv, dary); if errest then `pdsolve/interp2dto0d`(3, INFO["soltimes"], INFO["spacepts"], INFO["err_t"], nops(INFO["depvars"]), INFO["solution"], true, tv, xv, daryt); `pdsolve/interp2dto0d`(3, INFO["soltimes"], INFO["spacepts"], INFO["err_x"], nops(INFO["depvars"]), INFO["solution"], true, tv, xv, daryx) end if end if; dary[nd+1] := tv; dary[nd+2] := xv; if dvars = [] then [seq(dary[i], i = 1 .. INFO["norigdepvars"])] else vals := NULL; for i to nops(dvars) do j := eval(dvars[i]); try if errest then vals := vals, evalhf(j(tv, xv, dary, daryt, daryx)) else vals := vals, evalhf(j(tv, xv, dary)) end if catch: userinfo(5, `pdsolve/numeric`, `evalhf failure`); try if errest then vals := vals, j(tv, xv, dary, daryt, daryx) else vals := vals, j(tv, xv, dary) end if catch: vals := vals, undefined end try end try end do; [vals] end if end proc; stype := "2nd"; if nargs = 1 then if args[1] = "left" then return solnproc(0, "left") elif args[1] = "right" then return solnproc(0, "right") elif args[1] = "start" then return solnproc("start", 0) else error "too few arguments to solution procedure" end if elif nargs = 2 then if stype = "1st" then tv := evalf(args[1]); xv := evalf(args[2]) else tv := evalf(args[2]); xv := evalf(args[1]) end if; if not (type(tv, 'numeric') and type(xv, 'numeric')) then if procname <> unknown then return ('procname')(args[1 .. nargs]) else ndsol := pointto(solnproc("soln_procedures")[1]); return ('ndsol')(args[1 .. nargs]) end if end if else error "incorrect arguments to solution procedure" end if; vals := solnproc(tv, xv); vals[1] end proc]

(6)

fN:=eval( f(x,t), sol:-value(f(x,t), output=listprocedure)):

 


 

Download JVB1.mw

 

 

I am brand new to Maple, both as a specific program and as an example of symbolic mathematical software (although years ago I spent some time with MathCad).

I am interested in referrals to online resources which can help me progress down the learning curve. I have a substantial background in application computer programming, mostly in C#.

So if there's such a thing as "Maple for Programmers" that might be ideal...particularly since I find Maple's syntax and semantics to be "just similar enough" to coding that it causes me a lot of frustration. As in, simply entering the examples from the online manual Just Doesn't Work :).

Thanx!

- Mark

Is there a reason why maple can't directly integrate over iterable objects (lists, vectors, matrices, etc.)?
From a first glance I would think doing 

int(<sin(x), cos(x)>, x=0..2)

should be equivalent to:

map(int, <sin(x), cos(x)>, x=0..2)

Is there a good reason why this would be a bad idea?  (for whatever it's worth, that's what mathematica does by default).

 

Dear Maple community,

I'm trying to calculate a Steady State Vector of the attached matrix using this Maple routine, but, unfortunately, don't get any solution even after a 30 min calculation on a 64Gb machine. Am I doing something wrong and, if so, could you please give me a hand how to conduct this calculation? Thanks!

Maple_SteadyStateVector.mw

Hello all,

at the beginning of my document I need to assign a value to my variable, for example 0.4, so I can calculate a number of material pararamters for this exact value. At the end I want to include a plot that demonstrates the material behaviour for the variable ranging from 0 to 1. 

However, I have found that I can not plot a graph if I have assigned a value to that variable before. The "unassign" command sadly does not work. 

I am a beginner in Maple so i am probably missing something obvious, but I would appreciate any help.

Thank you!

Hello,

I have a quite big program designed with packages and subpackages.

I realized that i'm not to well understand the operation of local/ global/ export variables in this case.

Let's detail the issue.

I consider a package like this :

MAIN PACKAGE:=module()

local XM

global YM

export ZM

      SUBPACKAGE1:=module()

      local X1

      global Y1

      export Z1

      end module;

      SUBPACKAGE2:=module()

      local X2

      global Y2

      export Z2

      end module;

end module;

Question:

Can you describe in the simpliest way the rules for accessing to the variables in the case the variables are local/ global/ export and in the case you are writting procedures inside the MAINPACKAGE or the SUBPACKAGEs ?

In others words may you help me to answer to these questions  ?

Is the local variable XM accessible to the procedures used in SUBPACKAGE1? no
Is the local variable X1 accessible to the procedure used in MAINPACKAGE ? no

Is the global variable YM accessible to the procedures used in SUBPACKAGE1? yes
Is the global variable Y1 accessible to the procedure used in MAINPACKAGE ? yes

Is the export variable ZM accessible to the procedures used in SUBPACKAGE1? yes
Is the export variable Z1 accessible to the procedure used in MAINPACKAGE ? yes with the syntax SUBPACKAGE:-Z1

I let my opinion but i need certainty on these points...

I attach a first draft that i would like you help me.

AboutModuleLocalGlobalExport.mw

I thank you in advance for your help.

I could not find a function in StringTools package which removes all substrings (not single characters) from one long string directly. 

For example given a Latex string 

s:=" \\left \\int x \\,dx \\left";

And I want to remove all "\\left"  from it, which results in "  \\int x \\,dx "

In Mathematica, there is a function called StringDelete which removes all occurances of the substring in one call. Like this

s = " \\left \\int x \\,dx \\left";
StringDelete[s, "\\left"]

In Maple, I tried StringTools:-Remove(x->evalb(x="\\left"),s) and this did not work.Also tried

s:=" \\left \\int x \\,dx \\left";
StringTools:-Remove(x->StringTools:-Compare(x,"\\left"),s)

But this returned "leftintxdxleft"

And StringTools:-Delete needs a range, which one then has to first find.

I found this:

s:=" \\left \\int x \\,dx \\left";
idx:=[StringTools:-SearchAll("\\left",s)]; #returns index of first character in the string
StringTools:-Delete(s,idx[1]..idx[1]+4); #this only remove the first one. Need to loop to remove all.

Which returns the first substring. So one has to make a loop and keep removing all substrings found from the call to StringTools:-SearchAll

This is all too much work. But can be done.

The question is: What is the simplist way to remove all substrings from one string? All substrings are the same and the substrings can be more than one character.

Here is another example

s:="1234566X6Y67890A6BC66DEFGH";

And want to remove all "66" substrings, so the result will be

"12345X6Y67890A6BCDEFGH";

I am sure there must be an easier way to do this in Maple than having to call 2 or 3 functions and using a loop, but I could not find it so far. 

What would be the closest function in Maple to Mathematica's StringDelete? 

 

Requesting a code to compute (and graph) the following self referencing sequence:

a(1)=1. If a(n) is a novel term (seen for the first time) then a(n+1)= d(a(n)) where d(k) is the number of divisors of k. 
if a(n) has been seen before then a(n+1) = a(n)+m where m is the least prior term which has not already been used in this way (once m is used it cannot be used again).

Sequence starts:

1,1,2,2,3,2,4,3,5,2,4,6,4,7,2,5,7,11,2...,

note that there are often multiple copies of the least unused term, which might make accounting for them tricky. 

Thanks in advance 

 

 

hello dear maple maple users.

I'm trying to solve this system of equations using fsolve but i'm geting this unrealistic curve.

I don't know exactly how, can help me understand!!!!!.

fsolve.mw

I am working with the JetCalculus package along with the DifferentialGeometry package. Notation: if there are 2 independent variables (x,y), then u[1,2] would now represent the 3rd mixed partial derivative of u, once with respect to x and twice with respect to y. Please check Example 3 here, https://de.maplesoft.com/support/help/Maple/view.aspx?path=DifferentialGeometry/JetCalculus/TotalDiff

If I have an expression like u[1,0]+f(u[0,0])*u[0,1]+u[1,1]*u[0,3], then I am looking for a procedure which gives me the Lead derivative term. In the example above, it is u[1,1]*u[0,3], and then I can find the lead coefficient, i.e u[1,1].
Please note that the Lead derivative is not unique and can have several terms. For example, orders are the same for u[1,1] and u[0,2].

Idea: If I can find a way to extract the subscripts and do operations on them, then it would be very helpful. 
Any help/guidance is much appreciated. Thanks.
EDIT 1: LeadingDerivative command is not the solution for me.

Dear maple users,

A fine day wishes to all.

How to replace a value in already computed data value.

In my problem, I have evaluated a set of values (with help of #ma1 := evalf(seq((A4(t)), t = 0.0..1, 0.1));)  

ma1 := 0., .1941703021, .3203871063, .4089371834, .4712881303, .5145114133, .5435036431, .5617715009, .5718586242, .5756277760, .5744585726

I need to change 0 value as a 1.

I have used subs(ma[1]=1,ma1), but its coming wrong.

 

diff(w(r, theta), r)/r + diff(w(r, theta), r, r) + diff(w(r, theta), theta, theta)/r^2 = r^3*cos(3*theta)

 

Can it be solved without boundary conditions?

Hi there.

Following by https://www.mapleprimes.com/questions/232199-Bug-In-EllipticCPi

there is some strange behavior of EllipticPi - this function return complex answer when nu>1

WolframAlpha and some another online calculators return real values - just real part of Maple's value.

Why Maple's EllipticPi return complex answer?

help.mw

How to solve Linear first-order PDE by the Lagrange method?

dx/(x) =dy/0=dt/0=du/3=dv/v=dw/w, where x,y,t are independent variables and u,v,w are dependent variables.

hello guys,

I want to plot the phase plane between F and m when:

F := 736*R^4/sqrt((-1380*Pi*R*m(r)^3 + 368*R^4 - 1587*m(r)^2*R^2 + 1280*m(r)^2*a)^2);
R := X^(1/3)/(-l^2 + 4*a) - 3*l^2*m(r)^2/X^(1/3);
X := m(r)*l^2*(sqrt((27*l^2*m(r)^4 - 16*a^2*l^2 + 64*a^3)/(-l^2 + 4*a)) + 4*a)*(-l^2 + 4*a)^2;
 

and

m := (l^2*r^2 + r^4 + a*l^2)/(2*l^2*r)

for positive constant a and l

please guide me,

thanks

First 288 289 290 291 292 293 294 Last Page 290 of 2308