libsim Versione 8.0.0

◆ arrayof_ttr_mapper_insert_array()

subroutine, private arrayof_ttr_mapper_insert_array ( type(arrayof_ttr_mapper) this,
type(ttr_mapper), dimension(:), intent(in), optional content,
integer, intent(in), optional nelem,
integer, intent(in), optional pos )
private

Method for inserting a number of elements of the array at a desired position.

If necessary, the array is reallocated to accomodate the new elements.

Parametri
thisarray object to extend
[in]contentobject of TYPE TYPE(ttr_mapper) to insert, if not provided, space is reserved but not initialized
[in]nelemnumber of elements to add, mutually exclusive with the previous parameter, if both are not provided, a single element is added without initialization
[in]posposition where to insert, if it is out of range, it is clipped, if it is not provided, the object is appended

Definizione alla linea 496 del file stat_proc_engine.F90.

497
498! euristically determine whether we are dealing with an
499! analysis/observation or a forecast dataset
500na = count(mask_timerange(:) .AND. itimerange(:)%p1 == 0)
501nf = count(mask_timerange(:) .AND. itimerange(:)%p1 > 0)
502lforecast = nf >= na
503#ifdef DEBUG
504CALL l4f_log(l4f_debug, &
505 'recompute_stat_proc_agg, na: '//t2c(na)//', nf: '//t2c(nf))
506#endif
507
508! keep only timeranges of one type (really necessary?)
509IF (lforecast) THEN
510 CALL l4f_log(l4f_info, &
511 'recompute_stat_proc_agg, processing in forecast mode')
512ELSE
513 mask_timerange(:) = mask_timerange(:) .AND. itimerange(:)%p1 == 0
514 CALL l4f_log(l4f_info, &
515 'recompute_stat_proc_agg, processing in analysis mode')
516ENDIF
517
518#ifdef DEBUG
519CALL l4f_log(l4f_debug, &
520 '(re)compute_stat_proc_agg, number of useful timeranges: '// &
521 t2c(count(mask_timerange)))
522#endif
523
524IF (SIZE(itime) == 0 .OR. count(mask_timerange) == 0) THEN ! avoid segmentation fault in case of empty volume
525 ALLOCATE(otime(0), otimerange(0), map_ttr(0,0))
526 IF (PRESENT(dtratio)) ALLOCATE(dtratio(0))
527 RETURN
528ENDIF
529
530! determine start and end of processing period, should work with p2==0

Generated with Doxygen.