Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > calculating of square roots ?
2006-06-29 00:59
Trifox
Account closed

Registered: Mar 2006
Posts: 108
calculating of square roots ?

hi all, for my newest project i am in urgent need to calculate the length of a 2d vector, reminding pythagorian math i remember that i have to calculate the roots of a fixed point (8bits.8bits) number, how can that be mastered in a convenient way ?!?!?!

thx
 
... 92 posts hidden. Click here to view all posts....
 
2006-07-07 11:06
_V_
Account closed

Registered: Jan 2002
Posts: 124
WVL :)

Quantum theory: Copenhagen all the way, because statistics basically can be interpreted as "many worlds" already ("if I repeat this experiment in an infinity of worlds, half those worlds will have this outcome, the others this one"). Also, after seeing that you can create metrics in general relativity which allow for a "portal" to an infinity of worlds in the singularity of a black hole, I've had my fill of "many worlds" :).
2006-07-07 11:18
enthusi

Registered: May 2004
Posts: 675
"seeing that you can create metrics in general relativity which allow for a "portal" to an infinity of worlds in the singularity of a black hole"

Hehe, that's less obvious I'd say.

And infinity is an idea or maybe concept, not a value.

Lets rather focus on something to apply 16->8.8 square roots to :)

'We' dont need wondering morons (me included :) but code :)
2006-07-07 11:31
_V_
Account closed

Registered: Jan 2002
Posts: 124
Graham: Actually, I can calculate that series without needing to prove convergence and whatnot.

Let s = lim (n->+Inf) 1 + (1/2) + ... + (1/2)^n
= sum (n:0->+Inf) (1/2)^n

Now,

s = sum (n:0->+Inf) (1/2)^n
= 1 + sum (n:1->+Inf) (1/2)^n
= 1 + sum (n-1:0->+Inf) (1/2)^[(n-1)+1]
= 1 + (1/2) * sum (n-1:0->+Inf) (1/2)^(n-1)

That's the same series as before, except that we have (n-1) as an index rather than n. And thus the infinite series we're looking at has the amazing property that

s = 1 + (1/2) * s

Which leads to

s = 2.

I have never said that infinity is a number in the conventional sense (neither is 0 actually - ever tried dividing by it?), but even numberless numbers are there nonetheless and we have to take them into account. Mathematically speaking, infinity is a conceptual step you have to take and when you do, some fun things can be done.

But, you're not alone on this. From Wikipedia:

"Leopold Kronecker rejected the notion of infinity and began a school of thought, in the philosophy of mathematics called finitism, which led to the philosophical and mathematical school of mathematical constructivism." :)
2006-07-07 14:26
Graham
Account closed

Registered: Dec 2002
Posts: 990
@_V_: Nopes, you have not calculated the result with the series, you have just proven equivalence of the series with another formula and then used that to calculate :)
2006-07-07 22:01
Cybernator

Registered: Jun 2002
Posts: 154
_V_ wrote:

> I agree that this is getting out-of-topic,
> which started because I was defending an 80s
> math teacher

What's wrong with going off-topic? How else would you start a conversation like this? ;) To tell the truth, to me it seems more interesting than calculating square roots on C64. (yeah, something's definitely wrong with me)

Cruzer wrote:

> Or maybe I'm just making up excuses why I had so low math grades in school. :)

Nice to know I'm not alone at this. ;)
2006-07-08 00:08
_V_
Account closed

Registered: Jan 2002
Posts: 124
Graham: Nopes, I have used the fact that this is an infinite series in order to *obtain* the equivalence, because extracting terms the way I did still yields the same series and thus I can complete the calculation. If the series were finite, the equivalence would never be possible as there wouldn't be *enough* terms. As you reject infinity, you can't do my calculation and thus not obtain the result. All you can do is get as close as possible for some resolution and settle for that, while I *am* there and get the exact result immediately. You probably dislike infinitesimals too - dang those integrals and differentials. Or functions in general, which exist in an infinite-dimensional (Hilbert) space, the workspace of quantum mechanics. Or projective geometry, which introduces the "line at infinity". Bahh, outdated stuff, all of it :).

Anyway, we're in an interpretation war here, one which neither of us can win because only time will tell which interpretation will become more popular. Finitism versus, ehh, infinitism. I extend the real number set with +Inf, -Inf and calculate stuff with them as if they were numbers, you will seek ways to avoid this. Finding a way around it is harder, but not impossible. Just think about Dirac, who introduced the Dirac Delta function and bra/ket notation in quantum mechanics, and von Neumann disliking Dirac's "intuitive" ideas to such a point that he invented spectral analysis (one of the most infuriating theories *ever made* - I remember even the strongest maths students sweating hard when this theory was given) just to prove a point :).

In the end, both viewpoints have been proven to complement eachother extremely well. However, Dirac's work is the more user-friendly one, so guess which is the most popular choice? Same criterion for Copenhagen vs Many Worlds. Or Heisenberg's elegant matrix theory vs Schrödinger's godawful wave function.

You know, I will find you at X and we'll discuss this to no avail a little more. WVL, be sure to keep us apart when the c64s start flying around ;). I don't think we have to burden the thread with this ping pong match any longer.
2006-07-08 03:20
Graham
Account closed

Registered: Dec 2002
Posts: 990
You still used equivalence and not infinity. You didn't use the series to calculate 2 but another formula.

This is also the reason why there is an arrow towards infinity and not some equal-to-infinity stuff. The series cannot be infinite, infinity does not exist.
2006-07-08 09:22
WVL

Registered: Mar 2002
Posts: 886
Quote: Graham: Nopes, I have used the fact that this is an infinite series in order to *obtain* the equivalence, because extracting terms the way I did still yields the same series and thus I can complete the calculation. If the series were finite, the equivalence would never be possible as there wouldn't be *enough* terms. As you reject infinity, you can't do my calculation and thus not obtain the result. All you can do is get as close as possible for some resolution and settle for that, while I *am* there and get the exact result immediately. You probably dislike infinitesimals too - dang those integrals and differentials. Or functions in general, which exist in an infinite-dimensional (Hilbert) space, the workspace of quantum mechanics. Or projective geometry, which introduces the "line at infinity". Bahh, outdated stuff, all of it :).

Anyway, we're in an interpretation war here, one which neither of us can win because only time will tell which interpretation will become more popular. Finitism versus, ehh, infinitism. I extend the real number set with +Inf, -Inf and calculate stuff with them as if they were numbers, you will seek ways to avoid this. Finding a way around it is harder, but not impossible. Just think about Dirac, who introduced the Dirac Delta function and bra/ket notation in quantum mechanics, and von Neumann disliking Dirac's "intuitive" ideas to such a point that he invented spectral analysis (one of the most infuriating theories *ever made* - I remember even the strongest maths students sweating hard when this theory was given) just to prove a point :).

In the end, both viewpoints have been proven to complement eachother extremely well. However, Dirac's work is the more user-friendly one, so guess which is the most popular choice? Same criterion for Copenhagen vs Many Worlds. Or Heisenberg's elegant matrix theory vs Schrödinger's godawful wave function.

You know, I will find you at X and we'll discuss this to no avail a little more. WVL, be sure to keep us apart when the c64s start flying around ;). I don't think we have to burden the thread with this ping pong match any longer.


keep you guys apart? :) I don't have a problem with a chickfight at X ;)
2006-07-08 13:13
_V_
Account closed

Registered: Jan 2002
Posts: 124
Graham: (pong)

>You still used equivalence and not infinity. You didn't
>use the series to calculate 2 but another formula.

I *did* use infinity because if I hadn't used the fact that the series has an infinite amount of terms, then I wouldn't have obtained the equivalence and hence the result. You can't see it due to the power of notation, but it's there.

>This is also the reason why there is an arrow towards
>infinity and not some equal-to-infinity stuff.

Uh, no, the arrow has nothing to do with the existence of an element. Because then I could also argue that 4 doesn't exist because I can write stuff like lim (n->4) 1/n. "Look, there's an arrow pointing at 4, thus 4 doesn't exist."

>The series cannot be infinite, infinity does not exist.

Okay. That is your viewpoint as a finitist. I have mine as an "infinitist". Now if you want to make me a believer, then prove formally that the element "infinity" doesn't exist. And don't do it just for me, because if you can really show this, then you will change the face of mathematics forever. Things like measure theory (which lead to integrals), Hilbert space (and thus quantum mechanics), projective geometry, statistics, fractals and extended number spaces will become entirely obsolete.
2006-07-08 15:53
Copyfault

Registered: Dec 2001
Posts: 466
It's funny to read these ping-pong-posts from "the finitist" Graham and "the infinitist" _V_.

I somehow have the feeling that "math" has a different meaning for you two. While Graham seems to argue like an "applied scientist", _V_ seems to be the "pure mathmatician". What were you two guys doing irl ;) ?

In applied science, infinity is rather a concept than some "serious element" of whatever set. A term like

lim_{n -> +inf} f(n) = g

more or less means "ok, the bigger n is chosen, the smaller the difference between my calculations and the desired value g will be". At least this is what I was told during all my physics_stuff at the university, and, this is absolutely alright irl! And it will stay that way as long as no "infinitesimal precise" measurements can be done, which is a real problem if we take quantum mechanics for granted!

In "pure math", things turn out to be slightly different;) There is no prob in defining an element called "infinity" if the definition is coherent with the setting in which we're willing to define it! For mathmaticians, such socalled "welldefined" objects exist. There are even examples for proofs that show existance of some objects without being constructive! For me, I have to admit, is this the beautiful part of math;))

Looking forward to seeing more ping-pongs from you - damn it I'll for sure won't make it to X this year:/

CF
Previous - 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Didi/Laxity
MAT64
csabanw
TheEnemy/TREX/THD
MWR/Visdom
The Syndrom/TIA/Pret..
soci/Singular
LDX#40
Mibri/ATL^MSL^PRX
DeeKay/Crest
sln.pixelrat
Guests online: 110
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Wonderland XIV  (9.6)
9 Memento Mori  (9.6)
10 Bromance  (9.5)
Top onefile Demos
1 It's More Fun to Com..  (9.7)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 TRSAC, Gabber & Pebe..  (9.5)
6 Rainbow Connection  (9.5)
7 Dawnfall V1.1  (9.5)
8 Quadrants  (9.5)
9 Daah, Those Acid Pil..  (9.5)
10 Birth of a Flower  (9.5)
Top Groups
1 Nostalgia  (9.3)
2 Oxyron  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top Crackers
1 Mr. Z  (9.9)
2 Antitrack  (9.8)
3 OTD  (9.8)
4 S!R  (9.7)
5 Faayd  (9.7)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.052 sec.