New answers tagged

4

I am not sure I understand your question 100%, do you mean something like this: r = RegionDifference[ RegionDifference[Cuboid[{-1, -1, -1}, {1, 1, 1}], Cylinder[{{0, 0, -1/4}, {0, 0, -1/2}}, 1/2]], Cylinder[{{0, 0, 1/4}, {0, 0, 1/2}}, 1/2]]; Needs["NDSolve`FEM`"] (mesh = ToElementMesh[r, "RegionHoles" -> {{0, 0, 3/8}, {0, 0, -3/8}}])["...


1

I think something is not quite right with way you process the equations. If you use this you get what you expect: b = 1; c = 1; h[x_] = -b x + c Cos[2 x]/2; Lh[l_, x_] := D[l[x], x, x] - (1/4) (D[h[x], x])^2 l[x] {vals, funs} = NDEigensystem[{-Lh[l, x], l[0] == l[Pi]}, l, {x, 0, Pi}, 6, Method -> {"PDEDiscretization" -> {"FiniteElement", {"...


2

For NDEigensystem[], only homogeneous boundary conditions can be set. In this case, we have b = 1; c = 1; h[x_] := -b x + c Cos[2 x]/2 eq = -(D[l[z], z, z] - (1/4) (D[h[z], z])^2 l[z]); {vals, funs} = NDEigensystem[{eq, DirichletCondition[l[z] == 0, z == 0 || z == Pi]}, l[z], {z, 0, Pi}, 5] Table[Plot[{eq /. l[z] -> funs[[i]], vals[[i]] funs[[i]]...


Top 50 recent answers are included