Recent content by acadian

  1. A

    Euler method for modeling simple harmonic oscillation

    Thank you! Modification: e = (v*v/2) + (x*x/2); a = -k*x / m; x = x + v*dt; v = v + a*dt; t = t + dt; Plotting e, t and x produces the following:
  2. A

    Euler method for modeling simple harmonic oscillation

    Hello! An assignment for my computational modeling course is to demonstrate the use of the Standard Euler method for modeling a simple harmonic oscillator; in this case, a mass attached to the end of a spring. I have the two coupled first-order differential equations satisfying hookes law...
  3. A

    How Do You Calculate the Memory Address of Temp[40,30,20] in a 3D Array?

    Homework Statement The problem is finding the memory location of a three-dimentional array Temp. Each index of temp goes from 1 to 100 and each element stores 4 bytes. The array is setup such that the last index varies fastest, aka: Temp[1,1,1], Temp[1,1,2], ... Temp[1,1,100]...
Back
Top