|
libsim Versione 8.0.0
|
◆ pack_distinct_var6d()
compatta gli elementi distinti di vect in un array Definizione alla linea 664 del file volgrid6d_var_class.F90. 666 CALL delete(csv)
667ENDDO
668
669200 CONTINUE
670
671END SUBROUTINE import_var_conv
672
673END SUBROUTINE vg6d_v7d_var_conv_setup
674
675
676ELEMENTAL FUNCTION conv_func_eq(this, that) RESULT(res)
677TYPE(conv_func),INTENT(IN) :: this, that
678LOGICAL :: res
679
680res = this%a == that%a .AND. this%b == that%b
681
682END FUNCTION conv_func_eq
683
684
685ELEMENTAL FUNCTION conv_func_ne(this, that) RESULT(res)
686TYPE(conv_func),INTENT(IN) :: this, that
687LOGICAL :: res
688
689res = .NOT.(this == that)
690
691END FUNCTION conv_func_ne
692
693
694FUNCTION conv_func_mult(this, that) RESULT(mult)
695TYPE(conv_func),INTENT(in) :: this
696TYPE(conv_func),INTENT(in) :: that
697
698TYPE(conv_func) :: mult
699
700IF (this == conv_func_miss .OR. that == conv_func_miss) THEN
701 mult = conv_func_miss
702ELSE
703 mult%a = this%a*that%a
704 mult%b = this%a*that%b+this%b
705ENDIF
706
707END FUNCTION conv_func_mult
708
709!> Apply the conversion function \a this to \a values.
710!! The numerical conversion (only linear at the moment) defined by the
711!! \a conv_func object \a this is applied to the \a values argument;
712!! the converted result is stored in place; missing values remain
713!! missing; if the conversion function is undefined (\a
714!! conv_func_miss) the values are unchanged. The method is \c
715!! ELEMENTAL, thus \a values can be also an array of any shape.
716ELEMENTAL SUBROUTINE conv_func_compute(this, values)
717TYPE(conv_func),INTENT(in) :: this !< object defining the conversion function
718REAL,INTENT(inout) :: values !< value to be converted in place
719
720IF (this /= conv_func_miss) THEN
721 IF (c_e(values)) values = values*this%a + this%b
722ELSE
723 values=rmiss
724ENDIF
725
726END SUBROUTINE conv_func_compute
727
728
729!> Locate variables which are horizontal components of a vector field.
730!! This method scans the \a volgrid6d_var array provided and locates
731!! pairs of variables which are x and y component of the same vector
732!! field. On exit, the arrays \x xind(:) and \a yind(:) are allocated
733!! to a size equal to the number of vector fields detected and their
734!! corresponding elements will point to x and y components of the same
735!! vector field. If inconsistencies are found, e.g. only one component
|