New answers tagged

0

I rewrote this without the subscripts, I added NumericQ in places where it was needed, I used SetDelayed (:=) for some of your functions, and I assumed by i you meant I the imaginary number: Z = 6; n = 6; K1 = 1.55; fpn1[q_?NumericQ] := (18.25974896615874*(1 - 0.8748275119106319*I)*I)/E^(0.2115*q^2) Fpn1[q_?NumericQ] := ((4*Pi)/q)*NIntegrate[ρn[r]*Sin[q*r]*...


0

I resolved the issue by re-defining ublb1 as follows. ublb1[α_, H_, L_] := Piecewise[{{ 1/2 (2 H - H^2 - 2 L + H L - H α + 2 L α - H L α) - 1/2 Sqrt[-4 H^3 + H^4 + 4 H^2 L - 2 H^3 L + H^2 L^2 + 4 H^2 α + 2 H^3 α - 6 H^2 L α + 2 H^3 L α - 2 H^2 L^2 α - 3 H^2 α^2 + 2 H^2 L α^2 + H^2 L^2 α^2], Im[ 1/2 (...


1

An MWE is helpful. Here's my stab at it: SeedRandom[0]; evals = Eigenvalues[ RandomReal[1, {5, 5}] + DiagonalMatrix[Ca Range@4, 1]]; Block[{x = Range@3}, evals[[1]] /. Ca -> x ] Root::npoly: {-1.01544-1.93459 #1-0.974557 #1^2-0.234265 #1^3-0.121439 #1^4+0.0463375 #1^5,<<9>>+<<20>> #1^5,<<1>>} is not a polynomial ...


3

You need to tell PadRight up to what dimension to pad. In your case you would want something of dimension {2,9}, so this should work: Normalxp = {0.314695, 0.202724, 0.445823, 0.137051, 0.340344, 0.210384, 0.0014843, -0.00337419, 0.115197}; Normalyp = {0.525304, 0.0501755, 0.796942, 0.167022}; Firstraw = {"Normalx+", "Normaly+"}; ...


Top 50 recent answers are included