1

If you use Plot like this,

Plot[Sin[x], {x, 1, 5}]

it produces the correct Sin graph with x from 1 to 5. Something that also works is to give the xmin and xmax values as a sequence like this,

Plot[Sin[x], {x, Sequence[1, 5]}]

However when I try to do the same thing for LogPlot (or indeed LogLinearPlot or LogLogPlot),

LogPlot[Sin[x], {x, Sequence[1, 5]}]

it outputs this (I don't believe this is even an error message):

Graphics`LogPlotDump`scaledPlot[]

How do you get LogPlot to accept a sequence for its limits?

gr19
  • 11
  • 2

1 Answers1

2

The same way it should be done for regular plot:

LogPlot[Sin[x], {x, Sequence[1, 5]} // Evaluate]

Or if x has potentially been defined as a global value elsewhere

Block[{x}, LogPlot[Sin[x], {x, Sequence[1, 5]} // Evaluate]]

enter image description here

Feyre
  • 8,597
  • 2
  • 27
  • 46