Message Boards Message Boards

0
|
3335 Views
|
3 Replies
|
0 Total Likes
View groups...
Share
Share this post:

Plot a function with large number of digits?

Posted 3 years ago

Here is my problem. I could see the yvalue or range of pnp on the graph when it was a four-digit number. Now I am factoring a 100-digit number and the plot is hard to read. It disappears. I need to know for p3 where the graph ranges from zero to one on the range yvalue. And for p5 I need to know where the range equals pnp. I researched previous posts but I think my problem is unique. So if you could graph p5 where the range equals pnp. I am waiting to solve this problem. So I can factor this 100 digit number. Because where y = pnp then x at that value is the smaller factor.

In[15]:= Clear pnp
pnp = 1522605027922533360535618378132637429718068114961380688657908494\
580122963258952897654000350692006139

p3 = Plot[{((pnp^2 + x^3)/
      pnp) - ((pnp + (x^2/(pnp^2 + x)) * pnp)) }, {x, 0, pnp}, 
  PlotRange -> 1]


p5 = Plot[{(pnp^2 + x^3)/pnp + (x^3/pnp)}, {x, 0, 2*10^45}, 
  PlotRange -> {1.515*10^99, pnp}]
show[ p5, {x, 0, pnp},  p5 -> pnp]

Out[15]= 1522605027922533360535618378132637429718068114961380688657908\
494580122963258952897654000350692006139 Clear

Out[16]= 1522605027922533360535618378132637429718068114961380688657908\
494580122963258952897654000350692006139
POSTED BY: Bobby Joe Snyder
3 Replies

I have used smaller numbers and the graph appeared to work. I post the test here below.

I have to use float point. I don’t know the max value an Mathematica type integer can hold. But pnp is an integer, but what I am comparing it too is not. It worked with smaller values. I thought that I could plot it and then use show to change the range. Thanks for the sample code I will try and use it.

I will use less than and greater than. I thought there was a calculation for this. Yes it is a float point comparison but is there no way to use some sort of analysis on the plot to find a given range. It would be invaluable if it were possible.

If I can read the graph, I can factor pnp in seconds.

pnp = 1847*2393

p3 = Plot[{((pnp^2 + x^3)/
pnp) - ((pnp + (x^2/(pnp^2 + x)) * pnp)) }, {x, 0, pnp}, 
PlotRange -> All]


p5 = Plot[{(pnp^2 + x^3)/pnp + (x^3/pnp)}, {x, 0, 1847}, 
PlotRange -> All]
POSTED BY: Bobby Joe Snyder

Floating point numbers are not very suitable for this calculation. I would do it with exact numbers:

Reduce[0 < ((pnp^2 + x^3)/pnp) - ((pnp + (x^2/(pnp^2 + x))*pnp)) < 1]
N[%, 700]
POSTED BY: Gianluca Gorni
Posted 3 years ago

I would first try to normalize the axes and not to work with such large numbers as 210^45 or 1.510^99.

POSTED BY: Ehud Behar
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract