Group Abstract Group Abstract

Message Boards Message Boards

1
|
2.9K Views
|
3 Replies
|
1 Total Like
View groups...
Share
Share this post:

Obtain precise numerical values of an expanded Harmonic number?

Posted 10 years ago

Thank you for opening this thread. I am a university student.
Could anyone help me to calculate the following summation numerically under a certain precision?
enter image description here
This is an expansion of Harmonic Number by introducing the parameter m. Setting m=1 implies

HarmonicNumber[n].

PROBLEM:
If n is not so big, e.g., n<=40, I can obtain the correct results with m=10/9 (see, Figure 1).
But when n goes to large, the numerical results behave not stable (see, Figure 2).

Figure 1


enter image description here


How can I avoid this abnormal results technically? Actually I need to calculate the case of n=100 and m>1.
Thank you in advance.

POSTED BY: Koichi Yoshi
3 Replies
Posted 10 years ago

Thank you for your replies.
Actually DiscretePlot with WorkingPrecision->50 did worked.
To show the value, I used the N operator suggested by Gianluca.
Thank you!

POSTED BY: Koichi Yoshi

The imprecision may be due to floating-point arithmetic. You can switch to arbitrary precision arithmetic by giving N with an explicit number of digits for the output:

DiscretePlot[N[s[10/9, n], 16], {n, 40, 80}]
POSTED BY: Gianluca Gorni

I did not try, because you did submit any copy-paste-able code:

but try adding

 WorkingPrecision -> 50 

at the end of your plot command.

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