Skip to main content
1-Visitor
May 16, 2024
Solved

Harmonic oscillator quantum physics using transfer matrix

Hello! I'm new to Mathcad (using it this semester in my university, and we are using the Mathcad 15 version, not prime), and i have a problem. I tried to do quantum harmonic oscillator using transfer matrix, as this is the subject right now. The teacher gave us an exemple problem, i tried to re-do it, and i got an error saying "This value must be integer" (it's error from the RR[j] = T(E[j]) line, and the start of the problem is K(i,E) as it seems it doesn't really recognise Vk). My teacher doesn't know exactly what's the problem, so i tried to get help here because it seems the best place.
Does anyone know how can i solve it? Thanks in advance!

Werner_E
Werner_EAnswer
25-Diamond I
May 16, 2024

What do you think that V[k is? V is a vector, but k is a range (which is an implicit loop).

What do you intend for example K(47, 11) to return as result?

Furthermore your function "K" does not use its argument "i" - which means that the 47 in my example above are irrelevant and your function "r" would always return the constant 1.

1 reply

Werner_E
Werner_E25-Diamond IAnswer
25-Diamond I
May 16, 2024

What do you think that V[k is? V is a vector, but k is a range (which is an implicit loop).

What do you intend for example K(47, 11) to return as result?

Furthermore your function "K" does not use its argument "i" - which means that the 47 in my example above are irrelevant and your function "r" would always return the constant 1.

Translate