calculate_and_broadcast_species_properties Subroutine

private subroutine calculate_and_broadcast_species_properties()

Uses

FIXME : Add documentation

Arguments

None

Contents


Source Code

  subroutine calculate_and_broadcast_species_properties
    use mp, only: proc0, broadcast
    use kt_grids, only: gryfx
    integer :: is
    if (proc0) then 
      do is = 1, nspec
         spec(is)%stm = sqrt(spec(is)%temp/spec(is)%mass)
         spec(is)%zstm = spec(is)%z/sqrt(spec(is)%temp*spec(is)%mass)
         spec(is)%tz = spec(is)%temp/spec(is)%z
         spec(is)%zt = spec(is)%z/spec(is)%temp
         spec(is)%smz = abs(sqrt(spec(is)%temp*spec(is)%mass)/spec(is)%z)
         if (gryfx()) then
            !WARNING THIS NORMALISATION IS A GUESS!!!
            !FEEL FREE TO QUESTION IT AND WORRY ABOUT IT
           spec(is)%vnewk = 0.01 ! spec(is)%vnewk / sqrt(2.0)
         end if
      end do
    end if
    call broadcast (nspec)

    do is = 1, nspec
       call broadcast (spec(is)%dens)
       call broadcast (spec(is)%temp)
       call broadcast (spec(is)%fprim)
       call broadcast (spec(is)%tprim)
       call broadcast (spec(is)%vnewk)
       call broadcast (spec(is)%stm)
       call broadcast (spec(is)%zstm)
       call broadcast (spec(is)%tz)
       call broadcast (spec(is)%zt)
       call broadcast (spec(is)%smz)
    end do
  end subroutine calculate_and_broadcast_species_properties