Seems Jellyfish you are working on some similar kind of thing to what i want to do. Please could you help me with coding for the finite differences? If you can send me your code for one of your equations that can help me. look at my posts and you can see where i am i am having problems. I...
backward difference on third equation is done on purpose, I am trying to use two coupled meshes. I have never programmed a FD before especially in this case where discritization has been done to both the time and spatial variables.
Boundary conditions are that p(0, z) = n(0,z) = 0 (causality)...
have a wave equation:
(∂^2 p)/〖∂z〗^2 -1/c^2 (∂^2 p)/〖∂t〗^2
In my case, (fields propagation within a semiconductor laser)
Which can be factored into forward propagating photon density:
(∂p^+)/∂t+C_g (∂p^+)/∂z=C_g Gp^++〖1/2 βR〗_sp
And backward propagation wave (photon density)...