Skip to content
Snippets Groups Projects
Forked from 4C / FORESEE
210 commits behind the upstream repository.
amod_wpm.f 26.07 KiB
!*****************************************************************!
!*                                                               *!
!*              Post Processing for 4C (FORESEE)                 *!
!*                                                               *!
!*                                                               *!
!*                  Modules and Subroutines:                     *!
!*                                                               *!
!*      data_mansort:  module to store the mansort, manrec input *!
!*      wood_processing:  module to store wood processing infos	 *!
!*	    wpm_output:  module to store simulation output			 *!
!*	    lifespan_par: module to store lifespan parameters		 *!
!*      ini_input: initialize the values of the modules		     *!
!*      allocate_in_output: allocates module values              *!
!*      deallocate_in_output: deallocates module values          *!
!*                                                               *!
!*                  Copyright (C) 1996-2018                      *!
!*     Potsdam Institute for Climate Impact Reserach (PIK)       *!
!*          Authors and contributors see AUTHOR file             *!
!*  This file is part of 4C and is licensed under BSD-2-Clause   *!
!*                   See LICENSE file or under:                  *!
!*     http://www.https://opensource.org/licenses/BSD-2-Clause   *!
!*                           Contact:                            *!
!*       https://gitlab.pik-potsdam.de/foresee/4C                *!
!*                                                               *!
!*****************************************************************!
! module contains informations from mansort file: "removals"
! module contains information for "roundwood" and "after processing" steps
! module contains lifespan function parameters
! module contains wmp output
module data_wpm
!***************************************************************
! module contains informations from mansort file: "removals"
!                           cm		cm      cm			cm      cm			m³/ha    kg C/ha
!# year   count  spec type  len     diam    diam wob	top_d   t_d wob		Volume   DW			number

	type mansort_type
	 integer		:: year, count, spec, number
	 character(4)	:: typus
	 real			:: diam, volume, dw, diam_wob
	end type mansort_type

	type manrec_type
	 integer		:: year, measure
	 character(28)	:: management
	end type manrec_type

	type  mansort_obj
		type(mansort_type)		    :: mansort
		type(mansort_obj), pointer :: next
	end type mansort_obj

	type  manrec_obj
		type(manrec_type)		    :: manrec
		type(manrec_obj), pointer   :: next
	end type manrec_obj

	! pointer to the the mansort, manrec lists, sea list
	type(mansort_obj), pointer	:: first_mansort
	type(manrec_obj) , pointer	:: first_manrec
	type(mansort_obj), pointer	:: first_standsort
    ! pointer variable for manipulating mansort, manrec lists, sea list
	type(mansort_obj), pointer	:: act_mansort
	type(manrec_obj) , pointer	:: act_manrec
	type(mansort_obj), pointer	:: act_standsort
	! years from the manrec file with needed management
	integer, allocatable, save, dimension(:) :: management_years
	integer :: nr_pr_ln	
	
	! number of simulation years, management (manrec) years and wpm relevant management years
	integer		:: nr_years