Assign one real to a Lorenz field.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(lorenz), | intent(inout) | :: | lhs | Left hand side. |
||
real(kind=R_P), | intent(in) | :: | rhs | Right hand side. |
subroutine lorenz_assign_real(lhs, rhs)
!---------------------------------------------------------------------------------------------------------------------------------
!< Assign one real to a Lorenz field.
!---------------------------------------------------------------------------------------------------------------------------------
class(lorenz), intent(INOUT) :: lhs !< Left hand side.
real(R_P), intent(IN) :: rhs !< Right hand side.
!---------------------------------------------------------------------------------------------------------------------------------
!---------------------------------------------------------------------------------------------------------------------------------
if (allocated(lhs%U)) lhs%U = rhs
if (allocated(lhs%previous)) lhs%previous = rhs
return
!---------------------------------------------------------------------------------------------------------------------------------
endsubroutine lorenz_assign_real