Recent content by villiami

  1. V

    SR: Gamma rays creating election-positron pair

    Is it possibly that: with photons, there are no frames in which momentum=0. If the p-e pair were produced, there will then be a frame in which momentum=0 (which previously had non-zero momentum photons). Thus mom is not conserved?
  2. V

    SR: Gamma rays creating election-positron pair

    Homework Statement This is a special relativity question: Two gamma rays of identical energies E collide with an angle \theta between their velocities. Show that positron-electron pair creation is impossible in the limiting case \theta=0. Find the minimum \theta value for p-e creation to...
  3. V

    C/C++ Why Aren't My C++ Array Functions Working?

    Great! Thanks guys. For some reason I was sure that wouldn't work- I'd read something about its value being passed, so modifying it (without referring to its address) wouldn't actually change the object. Thanks again!
  4. V

    C/C++ Why Aren't My C++ Array Functions Working?

    Thanks for your help, I'm still unsure how to declare a function to modify a 2D array. I'm trying to make a function to increment a specific element: void flipsite(double* pgrid[][], int n, int m) {*pgrid[n][m] = *pgrid[n][m] + 1.0; }So then in the main function I can write: double...
  5. V

    C/C++ Why Aren't My C++ Array Functions Working?

    Have read a million different sites and threads, but still not getting anywhere (damn 1st year java makes addresses incomprehensible!). What changes do I need to make to get these c++ functions to work? //---------Functions //-- A function to increment the (n,m) element void...
  6. V

    Particle distribution in a box

    So #microstates(A) = N! / n!(N-n)! [Putting n in A] but isn't num(B) = N! / (N-n)!n! as well? [putting N-n into B] I still don't see how to weight them according to volumes.. (thanks for the help so far!)
  7. V

    Particle distribution in a box

    Homework Statement N atoms are in two boxes, box A: volume=V, and box B: volume=3V. (Assume a atoms make up a low density perfect gas). 1) How many ways can n be chosen, where n=(number of atoms in box A)? 2) Each atom if allocated a spatial state. Assuming that the number of available...
  8. V

    MATLAB (Should be) Simple function declarations in Matlab

    Thanks for that, but it still doesn't let me type something like: f(2) which is what I need for the optimization (where I will enter fminsearch(@f,[0]) to find the minimizing x-value given the constant a and b values) Any ideas?
  9. V

    MATLAB (Should be) Simple function declarations in Matlab

    I have already declared some variable values as (for example): a = 2 b = 3 Now I want to declare a function like: f(x) = x + a - b I will be optimizing w.r.t. x later, so I don't want to enter it as f(x,a,b) (or is it possible to oiptimise w.r.t. just one of the variables?) I tried...
  10. V

    Curve-to-curve fitting trouble

    Thanks for the responses, I think I've solved it (partially) by rotating the parts of the curves so the don't double back on themselves. Works well so I'm happy with it!
  11. V

    Curve-to-curve fitting trouble

    The data is not paired, i.e. one set might be for x-values 10,20,30,40,50 and the other at 11,17,31.46,...etc In the first version I used spline interpolation when I needed to compare points/curves. (note these are not actually the data points!) Thanks
  12. V

    Curve-to-curve fitting trouble

    I'm currently working on a MATLAB program which, given two sets of data each representing curves, will transform (through rotations about the origin and x-y shifts) the first curve so it fits the second one best (so far in terms of sum of squares). I have been able to create a program...
  13. V

    Solving Collisions & ZMFs Homework: Mass 4 Particle Deflection

    Homework Statement A particle of relative mass 4 travels at velocity v, and collides with a stationary particle with relative mass 1. By considering the zero momentum frame, show that the larger particle can be deflected by an angle of arcsin(1/4) at the most. (Note this is a...
  14. V

    Solving 0 = -v.cos(2x) + sin(x).sqrt(v^2.[sin(x)]^2 + 2ah)

    Perfact, I hope a few ideas come out of this new form. Thanks
  15. V

    Calculating Spongebob's Age: A Fun Math Challenge

    He goes to BOATING school, not primary. lol
Back
Top