- #1
Juliousceasor
- 25
- 0
Hello,
I have a 1-D steady state (dc/dt=0) differential equation in the atmosphere. It looks like follows,
K*C'' + (K'+K/H)*C' + (1/H*K'- (K/H^2)*H'- (L+Si))C + S = 0
where,
C = concentration of the contaminant in the atmosphere at different heights z
K = vertical diffusion coefficient
H = scale height
L = decay constant
Si= constant
S = source term
C'' = double derivative of C w.r.t. z
C',K',H'= derivative of C,K,H w.r.t. z
K,H,Si,S,L are all known values.
I am trying to solve the above differential equation numerically by means of finite differences of 1st order with boundary conditions,
At the top boundary: C = S/L
at the bottom boundary k*dc/dx = 0
Can anyone tell me how to write this routine in matlab?
help would be greatly appricieted! :)
I have a 1-D steady state (dc/dt=0) differential equation in the atmosphere. It looks like follows,
K*C'' + (K'+K/H)*C' + (1/H*K'- (K/H^2)*H'- (L+Si))C + S = 0
where,
C = concentration of the contaminant in the atmosphere at different heights z
K = vertical diffusion coefficient
H = scale height
L = decay constant
Si= constant
S = source term
C'' = double derivative of C w.r.t. z
C',K',H'= derivative of C,K,H w.r.t. z
K,H,Si,S,L are all known values.
I am trying to solve the above differential equation numerically by means of finite differences of 1st order with boundary conditions,
At the top boundary: C = S/L
at the bottom boundary k*dc/dx = 0
Can anyone tell me how to write this routine in matlab?
help would be greatly appricieted! :)