Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QB64 Phoenix Edition v3.9.0 Released!
#51
(10-07-2023, 03:37 AM)BSpinoza Wrote: This is one of my programs:

Code: (Select All)

'! PROGRAM: GAMMA.BAS
'! This Programm calculates the gammafunction for a specified value.
'! created April 04, 2017 by Bruno Schaefer, Losheim am See, Germany
'! last review: March 28, 2018

Input "Input value: "; value##
result## = gamma##(value##)
Print result##


Function gamma## (x##)
    n = 550
    a## = (x## + n)
    b## = x##
    For I = 1 To (n - 1)
        b## = b## * (x## + I)
    Next I
    Let gamma## = Sqr((2 * _Pi(1)) / a##) * a## ^ a## * Exp(a## * (-1) + (1 / (12 * a##)) - (1 / (360 * a## ^ 3))) / b##
End Function

Input values i.e. :  3  ->   result :  2
                             8  ->   result: 5040

 It worked fine in QBPE64 version 3.8.0 and older versions. 

Since QBPE64 version 3.9.0 the result is: inf

Whats wrong?

Whoa!! I thought. How in the world did he get in my PC and grab my Gamma program?

Then I noticed it wasn't actually the same program. Whew.
Reply
#52
https://qb64phoenix.com/forum/showthread...3#pid20413

I found the mistake. It can also be seen in the picture.  Rolleyes
https://imgbb.com/vqB7vY7

Here again:
[Image: Fehler-in-Compiler-Settings.jpg]
Reply




Users browsing this thread: 2 Guest(s)