Changeset 142 for branches/ORCHIDEE_EXT/ORCHIDEE/src_sechiba
- Timestamp:
- 2011-03-16T10:08:26+01:00 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ORCHIDEE_EXT/ORCHIDEE/src_sechiba/sechiba.f90
r116 r142 252 252 REAL(r_std), DIMENSION(kjpindex) :: histvar !! computations for history files 253 253 254 INTEGER(i_std) :: j 254 255 ! 15/03/2011 DS Add for externalisation 256 REAL(r_std), DIMENSION(kjpindex) :: sum_treefrac, sum_grassfrac, sum_cropfrac 257 INTEGER(i_std) :: jv 255 258 256 259 … … 584 587 ! 585 588 ! 589 590 !DS 15:03/2011 Prepares the writing of the history files 591 sum_treefrac(:) = zero 592 sum_grassfrac(:) = zero 593 sum_cropfrac(:) = zero 594 DO jv = 2, nvm 595 IF (is_tree(jv) .AND. natural(jv)) THEN 596 sum_treefrac(:) = sum_treefrac(:) + veget_max(:,jv) 597 ELSE IF ((.NOT. is_tree(jv)) .AND. natural(jv)) THEN 598 sum_grassfrac(:) = sum_grassfrac(:) + veget_max(:,jv) 599 ELSE 600 sum_cropfrac = sum_cropfrac(:) + veget_max(:,jv) 601 ENDIF 602 ENDDO 603 604 586 605 IF ( .NOT. almaoutput ) THEN 587 606 CALL histwrite(hist_id, 'beta', kjit, vbeta, kjpindex, index) … … 638 657 639 658 !$$ 25/10/10 Modif DS & NViovy 640 641 !!$ DO j = 2, nvm642 !!$ IF (is_tree(j) .AND. natural(j)) THEN643 !!$ histvar(:)=SUM(veget_max(:,j))*100*contfrac(:)644 !!$ CALL histwrite(hist_id, 'treeFrac', kjit, histvar, kjpindex, index)645 !!$ ELSE IF ((.NOT. is_tree(j)) .AND. natural(j)) THEN646 !!$ histvar(:)=SUM(veget_max(:,j))*100*contfrac(:)647 !!$ CALL histwrite(hist_id, 'grassFrac', kjit, histvar, kjpindex, index)648 !!$ ELSE IF (.NOT. natural(j)) THEN649 !!$ histvar(:)=SUM(veget_max(:,j))*100*contfrac(:)650 !!$ CALL histwrite(hist_id, 'cropFrac', kjit, histvar, kjpindex, index)651 !!$ ELSE652 !!$ WRITE(numout,*) 'Something wrong happened in histvar of veget_max in sechiba.f90'653 !!$ ENDIF654 !!$ ENDDO655 659 !!$ 656 WHERE (is_tree(:) .AND. natural(:)) 657 histvar(:)=SUM(veget_max(:,j))*100*contfrac(:) 658 ENDWHERE 659 CALL histwrite(hist_id, 'treeFrac', kjit, histvar, kjpindex, index) 660 661 WHERE (.NOT. is_tree(:) .AND. natural(:)) 662 histvar(:)=SUM(veget_max(:,j))*100*contfrac(:) 663 ENDWHERE 664 CALL histwrite(hist_id, 'grassFrac', kjit, histvar, kjpindex, index) 665 666 WHERE (.NOT. natural(:)) 667 histvar(:)=SUM(veget_max(:,j))*100*contfrac(:) 668 ENDWHERE 669 CALL histwrite(hist_id, 'cropFrac', kjit, histvar, kjpindex, index) 670 !!$ 671 672 !-------------------------------------------- 660 histvar(:)= sum_treefrac(:)*100*contfrac(:) 661 CALL histwrite(hist_id, 'treeFrac', kjit, histvar, kjpindex, index) 662 663 histvar(:)= sum_grassfrac(:)*100*contfrac(:) 664 CALL histwrite(hist_id, 'grassFrac', kjit, histvar, kjpindex, index) 665 666 histvar(:)= sum_cropfrac(:)*100*contfrac(:) 667 CALL histwrite(hist_id, 'cropFrac', kjit, histvar, kjpindex, index) 668 669 673 670 histvar(:)=veget_max(:,1)*100*contfrac(:) 674 671 CALL histwrite(hist_id, 'baresoilFrac', kjit, histvar, kjpindex, index)
Note: See TracChangeset
for help on using the changeset viewer.