Skip to content

Instantly share code, notes, and snippets.

@jstults jstults/fs.f90
Created Jan 29, 2012

Embed
What would you like to do?
Falkner-Skan IVP
module fs
implicit none
contains
subroutine rates(F, t, y, arg)
double complex, intent(in) :: t
double complex, intent(in), dimension(3) :: y, arg
double complex, intent(out), dimension(3,1) :: F
F(1,1) = y(2)*arg(3)
F(2,1) = arg(3)*y(3)
F(3,1) = -arg(1)*y(1)*arg(3)*y(3)+arg(2)*y(2)**2*arg(3)-arg(2)*arg(3)
end subroutine rates
subroutine jac(pJ, t, y, arg)
double complex, intent(in) :: t
double complex, intent(in), dimension(3) :: y, arg
double complex, intent(out), dimension(3,3) :: pJ
pJ(1,1) = 0
pJ(1,2) = arg(3)
pJ(1,3) = 0
pJ(2,1) = 0
pJ(2,2) = 0
pJ(2,3) = arg(3)
pJ(3,1) = -arg(1)*arg(3)*y(3)
pJ(3,2) = 2*arg(2)*y(2)*arg(3)
pJ(3,3) = -arg(1)*y(1)*arg(3)
end subroutine jac
end module fs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.