# Get the list of (x,y) point of a graphic

I have a function like this:

E^(-t/0.001)*Cos[t] + E^(-t/0.01)*Cos[1000 t]


I used the code below as suggested in the forum to obtain the x,y values for points

data = Cases[Plot[Exp@(-1000 x)*Cos@ x + Exp@(-100 x)*Cos@ (1000 x), {x, 0, 0.1}], Line[data_] :> data, -4, 1][[1]]


However, it works (plotting back the list of number obtained I generete the original function) only when inside the exp functions I insert numbers such as (2, 3), (1000, 10) and so on, but not if I use (1000,100) or (10000, 1000) and so on. Can someone help me to understand what is the problem. Thank you

Clear["Global*"]


The default PlotRange can truncate the curve resulting in multiple lines.

plt = Plot[Exp[-1000 x]*Cos@x + Exp[-100 x]*Cos[1000 x], {x, 0, 0.1}]


Note that with the PlotRange truncated, there are multiple separate lines

ListLinePlot[
Cases[plt, Line[data_] :> data, Infinity],
PlotLegends -> Automatic]


When the PlotRange does not truncate the curve, there is a single line

plt2 = Plot[Exp[-1000 x]*Cos@x + Exp[-100 x]*Cos[1000 x], {x, 0, 0.1},
PlotRange -> Full]


The resulting single line can be displayed fully

ListLinePlot[
Cases[plt2, Line[data_] :> data, Infinity],
PlotRange -> Full]


or truncated by the PlotRange

ListLinePlot[
Cases[plt2, Line[data_] :> data, Infinity]]
`