(A little bit of [an attempt at]) relativistic SUVAT

9 11 2008

Not sure if this is correct, but I thought this was quite good (done while procrastinating about doing Mr Miller’s Cosmology prep):

Consider an object whose initial speed, u or v0, is zero. A constant force F then acts on it (and continues acting on it). I will (attempt) to find an expression for the speed v(t) of the object. I will use u’ to mean du/dt. Please ignore terrible interchanges between functions of stuff and such like - don’t really know what I’m doing.

Remember, v0 is zero.

First, use the crunched version Newton’s second law: F = ma, so a = F/m, so v’ = F/m. Integrating both sides with respect to t gives v(t) = Ft/m + k. Since v(0) = 0, k = 0 so v = tv’ (cf. suvat stuff, v = u + at when u = 0… it’s all fine so far).

Now consider the relativistically tweaked version of Newton II: F = ma/sqrt(1-(v/c)^2). Using the same juggling as before, this gives:

v’ = Fsqrt(1-(v/c)^2)/m

Rearrange and use separation of variables/whatever to get:

int(1/sqrt(1-(v/c)^2))dv = int(F/m)dt

which gives (remembering the boundary condition v(0) = 0)

csin-1(v/c) = Ft/m

sin-1(v/c) = Ft/mc

v/c = sin(Ft/mc)

finally:

v(t) = csin(Ft/mc)

This looked promising (note the maximum value of v is c)…

To try to convince myself that this was correct, consider the sin small angle approximation: sin(x) is approx. equal to x for small values of x. Well, Ft/mc is certainly small for most F and t when you consider how large c is, so: for values of F that are small compared to c (and small t but not sure what that means physically), we get v(t) is approx. equal to c*Ft/mc = Ft/m (which = at for small v as this means we can ignore the Lorentz factor), which is the Newtonian one… which seems quite interesting. Tell me where I’ve messed up.

I almost did it with a non-zero initial speed but I saw a bunch of sqrt(1-(v0/c)^2) blah (because of the trig addition formulae and Pythagorean identities) in there so I avoided that and then gave up entirely (good times).

Pax



Java

9 07 2008

I tried to teach myself some Java from a book I’ve had for years (I remember buying it at Waterstone’s in Ealing Broadway back when I didn’t exclusively use the internet to accumulate stuff). I’ve done some simple things like porting binary (which wasn’t too hard), making a program for finding the arithmetic, geometric or harmonic mean of an indefinitely long list of numbers (will adjust that to perform a quick iteration to find the arithmetic-geometric mean) and an iterative factorial thing.

What I want to do eventually is write some routines to a) solve a system of linear equations in 3 variables via matrices b) absorb plotter and c) do splines.

I’ve made headway with the algorithmic techniques already. I made a spreadsheet to solve the equations in a way similar to my sum of r4 thing so when you enter two points (x co-ord, y co-ord, gradient at that point), it tells you the coefficents of the cubic required to draw smoothly through those points.

I tested it with Grapher (a superb application). For people unfamiliar with cubic splines, a different function is plotted between each pair of points that joins up with the next one at the same gradient, so as to create the appearance of a smooth curve. For this, the gradient at each point, as explained in the picture, was just the gradient between that point and the next. Probably not the best way to do it, but it seemed to work, kind of… I believe you can do some magic with the second derivative too. I’ll look into it. Have a look.

If the gradient at the point (xn, yn) is mn, maybe I should’ve said:

mn = ((yn - yn-1)/(xn - xn-1) + (yn+1 - yn)/((xn+1 - xn))/2

That is, the mean of the gradient between the previous point and this one, and the gradient between this one and the next.

I played around a little with Swing but have so far only made an infinite number of replicating, unclosable windows.

I’m also finding Coda even more useful than before. I can just work from a split-screen of its inbuilt terminal and the .java file I’m working on (it highlights Java syntax - how nice!).

Pax



Imperial College Open Day + New Scientist Visions of the Future talk

26 06 2008

This blog post will grow as I remember more details.

Imperial College (or Imperial Lollege, as it was when my dad was there, reading Mechanical Engineering and putting the lulz in Lulz…ondon) was pretty awesome. Four year course with industry placement looked awesome.

They coincidentally brought up Richard Hayden, whose CV I had read online previously. I lulzed up the talk with some banter about stochastic fluid flow. Hot female Japanese CS applicants were in awe of me, or at least noticed me in order to be contemptuous. Halls of residence full of lulz: Southside and Eastside. Talked to Dr Jeremy Bradley (DoC admissions tutor) about quantum computing and mathematical preparation; he suggested that if I have “any maths ability whatsoever” I should do JMC (Joint maths and computing) - he essentially said “don’t believe the prospectus; it’s actually the entire maths and computing undergrad in one”.

Met guy applying for physics. He plays Command & Conquer. Was from Wales; friendly. Also met Yen-Ming and his father. His father was doing his PhD - all research, no teaching - at Imperial while my dad was undergrad. How interconnected of him.

Saw some projects. Fantastic. Eye tracking, torso modelling, game playing lulz ensued. Dad saw that one of his professors from 198x was still a member of the mech eng faculty (lulz).

Ray Hammond and James Bellini were shockingly down-to-earth and non-speculative. Predictable themes included delocalisation of working environment, epic lulz, “conscious internet”, ubiquitous computing etc.. Hammond talked about what was essentially The Wired. Reminded me of Masami Eiri when he said, and I quote, “The next step in human evolution is merging with our creations”.

Audience was mostly pretentious pseudo-intellectuals like me. No-one else under 18 had entered (or made an entry decent enough to get an invitation). I guess young people don’t care about future. Short-sighted info addiction stuff. Lulz. Highlights included tipsy Tesla fanboy rambling about something no-one cares about, man whose life goal is to make jokes about Microsoft and Drunk Freelance Philosopher (one of the runners-up, in fact). I thought the winning entries were okay - not as great as Hammond and Bellini, though.

May remember other stuff. Cambridge had better be good, after that.

I like quantum computing. I like internet. I like artificial intelligence. I plan to lulz stuff up. Throw off crushing weight of friends with superior mathematical ability with attitudes ranging from condescending to hostile. Now irrelevant. Before I cried! NOW I LAUGH IN THE FACE OF ANTI-LULZ!

Ha ha; lulz!

Pax

P.S. News from Cambridge:

Dear Farhan,

Thanks for your query. Although it will depend on the College to which
you’re applying, the Faculty expects that you will be interviewed as a
computer scientist and will have one extra interview by the
mathematicians to check your mathematical ability. The Faculty also
expects that, should you be made an offer and then fail just the STEP
requirement, you would still be able to come to read Computer Science
with one of the other six options.

I hope this helps,
Fiona Billingsley

======================================
Mrs Fiona Billingsley
Student Administrator
University of Cambridge
Computer Laboratory
William Gates Building
JJ Thomson Ave
Cambridge CB3 0FD, UK

Tel: +44 (0)1223 763505
Fax: +44 (0)1223 334678
Email: fmb37@cl.cam.ac.uk
======================================

—–Original Message—–
From: Farhan Mannan [mailto:farhanmannan@mac.com]
Sent: 25 June 2008 21:48
To: undergraduate.admissions@cl.cam.ac.uk
Subject: Computer science with mathematics

I was planning to apply for computer science in 2009 but recently
decided that I may apply for the 50% maths option in the first year.
Does this mean my interview will essentially be a maths interview and
devalue the books I’ve read, or will it still be a computer science
interview with the proviso that I do well in STEP?

Thanks,

Farhan Mannan



?

19 06 2008

Now:

  • Made it to final of Aerospace Challenge - team meant to be called “The Pauli Effect”, listed as “Pauli”
  • Doing terrible, terrible physics competition
  • Used distribution of points in a square and circle to approximate pi
  • Watched 2001: A Space Odyssey - totally awesome. Combination of pacing and philosophy reminded me of SEL - wonder whether Rokison liked 2001?
  • Had fencing epiphany (remembered how to fence)
  • Working on iSAMS MySQL JavaScript plugin thing

Over the summer:

  • Fabric stuff
  • University of Arizona stuff
  • Science essay (applied computer science)
  • Philosophy essay (Baudrillard)
  • Revision for TSA and (horror!) STEP…
  • Become a good fencer

Pax



Anti-lulz

1 06 2008

Those other things are still up (plotter, graphics, recursion) and this is an Excel spreadsheet which I used to do a bunch of simultaneous equations to determine that the sum from r=1 to n of r4 is n5/5 + n4/2 + n3/3 - n/30. I’ll simplify that later I suppose.

The idea was that the sum of rp can be expressed as a polynomial of order p + 1, so I just got 5 simultaneous equations involving the 5 coefficients of the quintic expression and got Excel to solve them in an “algorithmic” way similar to the triangular form thing we have to do.

I was revising FP1 and the sections on triangular form and summations of rpinspired” me to do this.

Pax



Recursion

31 05 2008

I’ve begun wondering if there’s anything special I can find with recursion, or if it’s just a fun way of expressing things. Is there anything new in there?

Pax



Geist

18 05 2008

If my muddled understanding of cellular automata and neural networks (and indeed the human brain itself), logic gates and the internet has taught me anything, it’s that the networking of nodes (simple[r] systems) can yield impressive, unpredictable or lulzworthy results. For me at least, pieces of fiction (films, books and such… not like, rubbish stuff) have an effect because I pick up on certain connections within the material to other parts of itself as well as to other things I don’t fully understand and stuff I already know etc.. This generates a kind of feel which I struggle to capture with my poor photography and endless blogging.

Maybe these complex network “feels” are also what govern sociology, love and anti-lulz! I think of this “feel” as a generalisation of the term zeitgeist, removing it from time. Geist, then? It already has a definition; I like mine better. How about nGeist? For network Geist? WordPress seems content with it… yes, that’s fine. Maybe The Node was just one Geist. Or the Universal nGeist. The uGeist! I MAKE WORDS UP.

Usually when I’m not fully acquainted with someone - or something - I get a more attractive “feel” than I will when I get more familiar.

Occasionally though, it just gets better and better until I get lost completely. Very occasionally. But when it does, it increases O(xx!). These cases have been computing, maths and a few other special cases which maybe I’ll write about later.

Ha ha! Later!

Pax



More exams

18 05 2008

I’ll standardise CPT1 and CPT2 to 3.7. Core 2 was 3.8ish? Have all three physics papers on Thursday, Stats 1 on Friday and then a break for a week. Then Core 3 and FP1 on Monday, all three chemistry papers on that Wednesday and Mechanics 1 on that Friday - AND I’M DONE!

Pax



More multiplication

4 03 2008

Method 1

Method 2

If we consider that the largest square that has to be looked up in method 1 is ((a+b)/2)2 and in method 2, a2 (if a is the larger of the two), it’s clear that method 1 will require a smaller square table but more operations per run, so there’s some tradeoff involved there.

I’m making an assumption here as I don’t know about general cases for binary subtraction but I think that addition or subtraction of 2 n-digit numbers is O(n·k) while multiplication is definitely O(n2).

Considering binary numbers, 11111111·10101010 will take n2 + 2n - 1 operations (New Turing Omnibus p168).

Substituting into method 2:

picture-3.png

If each lookup is one operation (and there is a fixed number of lookups and subtractions for the general case) and subtraction is O(n·k), and division by 10 (i.e. by 2) is also O(n·k) (another assumption - I suppose that since we’re dealing with a fixed denominator unlike the multiplication case where it seemed logical for it to be O(n2)) then I think the function increases as n·k.

But it requires a square table. A LARGE ONE. However, this may be okay because you can reuse the squares in many calculations so perhaps in the long run it somehow balances out the initial deficit?

Or maybe the table can be populated as you go so there’s no initial deficit but a general inefficiency which soon disappears as the table values start getting filled in?

I really don’t know though.

It’s a nice thought.

Hmm?

Pax