0
$\begingroup$

I am using Table to get values for some expressions (see code below):

table1 = Re[
Table[(1/(2*Pi))*
NIntegrate[{(k*(e^2)*(1 - UndefPDefinedR\[Sigma]h[e, k, p] - 
       UndefPDefinedR\[Sigma]e[e, k, p])/(T*
       Cosh[e/(2*T)]^2))}, {k, 0, 1}, {e, -100, 100}], {p, 0, 
                 0.9, 0.1}, {T, 0.01, 1.01, 0.1}]]

Running this gives me:

{{{{0.}}, {{0.0126698}}, {{0.0461803}}, {{0.100635}}, {{0.176033}}, \
{{0.272375}}, {{0.389661}}, {{0.527891}}, {{0.687066}}, {{0.867184}}, \
{{1.06825}}}, {{{0.}}, {{0.00597356}}, {{0.04509}}, {{0.0990807}}, \
{{0.174307}}, {{0.270645}}, {{0.388006}}, {{0.526338}}, {{0.685602}}, \
{{0.865824}}, {{1.06697}}}, {{{0.}}, {{0.00566179}}, {{0.0440592}}, \
{{0.0976428}}, {{0.172697}}, {{0.268999}}, {{0.386386}}, \
{{0.524769}}, {{0.684111}}, {{0.864391}}, {{1.0656}}}, {{{0.}}, \
{{0.0054278}}, {{0.0430948}}, {{0.0962714}}, {{0.171089}}, \
{{0.26728}}, {{0.384637}}, {{0.523034}}, {{0.682409}}, {{0.862733}}, \
{{1.06399}}}, {{{0.}}, {{0.00527582}}, {{0.0422016}}, {{0.094919}}, \
{{0.169389}}, {{0.265368}}, {{0.382621}}, {{0.520977}}, {{0.680358}}, \
{{0.860706}}, {{1.06199}}}, {{{0.}}, {{0.0108081}}, {{0.0413989}}, \
{{0.093545}}, {{0.16754}}, {{0.263202}}, {{0.380267}}, {{0.518532}}, \
{{0.677874}}, {{0.858221}}, {{1.05953}}}, {{{0.}}, {{0.00519358}}, \
{{0.0406858}}, {{0.0921486}}, {{0.165534}}, {{0.260758}}, \
{{0.377543}}, {{0.515649}}, {{0.674903}}, {{0.855231}}, {{1.05655}}}, \
{{{0.}}, {{0.0104626}}, {{0.040048}}, {{0.0907166}}, {{0.163354}}, \
{{0.258007}}, {{0.37441}}, {{0.512281}}, {{0.671414}}, {{0.851671}}, \
{{1.05297}}}, {{{0.}}, {{0.0103941}}, {{0.0394585}}, {{0.0892579}}, \
{{0.161032}}, {{0.254994}}, {{0.370911}}, {{0.508464}}, {{0.667403}}, \
{{0.847556}}, {{1.04881}}}, {{{0.}}, {{0.0103512}}, {{0.0388989}}, \
{{0.0877943}}, {{0.158599}}, {{0.251747}}, {{0.367053}}, \
{{0.504193}}, {{0.662863}}, {{0.84286}}, {{1.04403}}}}

Now, I want to plot this for a given p (lets say p = 0), and T going from 0.01 to 1.01 with steps of 0.1. However, I have not been able to do so using ListPlot or ListLinePlot. May I ask if you have any more ideas as to how I can fix this issue?

$\endgroup$
  • 1
    $\begingroup$ does ListPlot[Flatten@table1[[1]]] give what you need? $\endgroup$ – kglr Jan 22 at 15:51
  • $\begingroup$ One cannot arrive upon the values you provided because some definitions in the code producing table1 are missing. Are you simply looking for Flatten to come up with a simple list? $\endgroup$ – gwr Jan 22 at 15:51
  • $\begingroup$ .. or ListPlot[table1[[1, All, 1, 1]]]? $\endgroup$ – kglr Jan 22 at 15:54
  • $\begingroup$ ListPlot[Flatten@table1[[1]]] worked, but how can I change the values on the x-axis (want 0.01, 0.11, ..., 1.01)? $\endgroup$ – user61819 Jan 24 at 10:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.