Last data update: 2014.03.03

R: Input text "file" for gulf of Riga autumn planktonic food web
FILERigaAutumnR Documentation

Input text "file" for gulf of Riga autumn planktonic food web

Description

Input text "file" for the Carbon flux Gulf of Riga planktonic food web in autumn as described in Donali et al. (1999).

The Gulf of Riga is a highly eutrophic system in the Baltic Sea

The foodweb comprises 7 functional compartments and two external compartments, connected with 26 flows.

Units of the flows are mg C/m3/day

The "dataset" RigaAutumnFile is included to demonstrate the use of a text input file for food web models.

The original file, RigaAutumn.input can be found in subdirectory ‘web’ of the packages directory

In this subdirectory you will find many foodweb example input files

  • They can be read using Read(file)

  • Or they can be directly solved using Setup(file)

Usage

data(FILERigaAutumn)

Format

vector of character strings as present in the original file

Author(s)

Karline Soetaert <karline.soetaert@nioz.nl>

References

Donali, E., Olli, K., Heiskanen, A.S., Andersen, T., 1999. Carbon flow patterns in the planktonic food web of the Gulf of Riga, the Baltic Sea: a reconstruction by the inverse method. Journal of Marine Systems 23, 251..268.

See Also

LIMRigaAutumn a list containing the linear inverse model specification, generated from file ‘RigaAutumn.input

Examples

print(FILERigaAutumn)

# RigaAutumnInput is a vector of text strings - 
# here it is first converted to a "File" 
# When using the example files in the LIM directory, 
# this first statement is not necessary
## Not run: 
File <- textConnection(FILERigaAutumn)
RigaAutumn.input <- Read(File)

## End(Not run)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(LIM)
Loading required package: limSolve
Loading required package: diagram
Loading required package: shape
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/LIM/FILERigaAutumn.Rd_%03d_medium.png", width=480, height=480)
> ### Name: FILERigaAutumn
> ### Title: Input text "file" for gulf of Riga autumn planktonic food web
> ### Aliases: FILERigaAutumn
> ### Keywords: datasets
> 
> ### ** Examples
> 
> print(FILERigaAutumn)
  [1] "Foodchain input file for the model of Donali et al."                                                      
  [2] ""                                                                                                         
  [3] "This input file contains the AUTUMN data"                                                                 
  [4] "#####################################################################"                                    
  [5] ""                                                                                                         
  [6] "!==================================!"                                                                     
  [7] "! MEASURED CONCENTRATIONS, mgC/m3  !"                                                                     
  [8] "!==================================!"                                                                     
  [9] "! Values from table 2, p. 254"                                                                            
 [10] ""                                                                                                         
 [11] ""                                                                                                         
 [12] "## STOCK "                                                                                                
 [13] ""                                                                                                         
 [14] " P1  = IniP1     ! PicoAutotrophs"                                                                        
 [15] " P2  = IniP2     ! Non-picoAutotrophs"                                                                    
 [16] " B   = 87.28     ! Bacteria"                                                                              
 [17] " N   = 3.85      ! Heterotrophic nanoflagellates"                                                         
 [18] " Z   = 90.51     ! Zooplankton-heterotrophic nanoflagellates"                                             
 [19] " D   = 355.27    ! Detritus + virus"                                                                      
 [20] " DOC = XNA       ! Dissolved organic carbon - not known"                                                  
 [21] ""                                                                                                         
 [22] "## END STOCK"                                                                                             
 [23] ""                                                                                                         
 [24] "## EXTERN"                                                                                                
 [25] ""                                                                                                         
 [26] "CO2"                                                                                                      
 [27] "Sedimentation"                                                                                            
 [28] ""                                                                                                         
 [29] "## END EXTERN"                                                                                            
 [30] ""                                                                                                         
 [31] "## PARAMETER"                                                                                             
 [32] " Inip1           = 19.06  {mmol/m3}   ! PicoAutotrophs"                                                   
 [33] " Inip2           = 66.29 {mmol/m3}   ! Non-picoAutotrophs"                                                
 [34] " MaintenanceResp = 0.1"                                                                                   
 [35] "## END PARAMETER"                                                                                         
 [36] ""                                                                                                         
 [37] "!===================!"                                                                                    
 [38] "! NET INPUT VALUES  !"                                                                                    
 [39] "!===================!"                                                                                    
 [40] ""                                                                                                         
 [41] "## RATE "                                                                                                 
 [42] ""                                                                                                         
 [43] " P1  = -2.19     !(SE 2.42)! PicoAutotrophs"                                                              
 [44] " P2  = 0.19      !(SE 4.90)! Non-picoAutotrophs"                                                          
 [45] " N   = 0.16      !(SE 0.60)! Heterotrophic nanoflagellates"                                               
 [46] " Z   = 1.51      !(SE 17.95)! Zooplankton-heterotrophic nanoflagellates"                                  
 [47] " B   = 6.75      !(SE 3.18)! Bacteria"                                                                    
 [48] " D   = -18.62    !(SE 19.66)! Detritus + virus"                                                           
 [49] " DOC = -252.93 !(SE 31.11)! Dissolved organic carbon"                                                     
 [50] ""                                                                                                         
 [51] "## END RATE"                                                                                              
 [52] ""                                                                                                         
 [53] "!====================!"                                                                                   
 [54] "! RATE OF CHANGES    !"                                                                                   
 [55] "!====================! "                                                                                  
 [56] ""                                                                                                         
 [57] "! dP1=-Flow(p1,0) -Flow(P1,Z) -Flow(P1,N) -Flow(P1,DOC) +Flow(0,P1)"                                      
 [58] "! dP1=-Flow(p2,0) -Flow(P2,Z) -Flow(P2,N) -Flow(P2,DOC) +Flow(0,P2)"                                      
 [59] "! dZ =-Flow(z,0)  +Flow(P2,Z) +Flow(N,Z)  +Flow(D,Z) -Flow(Z,D)-Flow(Z,DOC)"                              
 [60] "! dN =-Flow(N,0)  +Flow(P1,N) +Flow(B,N)  -Flow(N,Z) -Flow(N,DOC)"                                        
 [61] "! dD = Flow(P2,D) +Flow(Z,D) "                                                                            
 [62] "! dB = Flow(DOC,B)-Flow(B,N) -Flow(B,0)"                                                                  
 [63] "! dDOC=Flow(N,DOC)+Flow(P1,DOC)+Flow(P2,DOC)+Flow(Z,DOC)+Flow(D,DOC)-Flow(DOC,B)"                         
 [64] ""                                                                                                         
 [65] ""                                                                                                         
 [66] "## FLOW"                                                                                                  
 [67] " "                                                                                                        
 [68] " ! Respiration fluxes"                                                                                    
 [69] " Flow(P1,CO2)        = ZeroOrder"                                                                         
 [70] " Flow(P2,CO2)        = ZeroOrder"                                                                         
 [71] " Flow(Z,CO2)         = ZeroOrder"                                                                         
 [72] " Flow(N,CO2)         = ZeroOrder"                                                                         
 [73] " Flow(B,CO2)         = ZeroOrder"                                                                         
 [74] ""                                                                                                         
 [75] " ! Production fluxes"                                                                                     
 [76] " Flow(CO2,P1)        = ZeroOrder"                                                                         
 [77] " Flow(CO2,P2)        = ZeroOrder"                                                                         
 [78] ""                                                                                                         
 [79] " ! PicoAutotrophs"                                                                                        
 [80] " Flow(P1,Z)        = ZeroOrder"                                                                           
 [81] " Flow(P1,N)        = ZeroOrder"                                                                           
 [82] " Flow(P1,DOC)      = ZeroOrder"                                                                           
 [83] " P1->Sedimentation"                                                                                       
 [84] ""                                                                                                         
 [85] " ! Non-Pico autotrophs"                                                                                   
 [86] " Flow(P2,DOC)      = ZeroOrder"                                                                           
 [87] " Flow(P2,Z)        = ZeroOrder"                                                                           
 [88] " Flow(P2,D)        = ZeroOrder"                                                                           
 [89] " Flow(P2,Sedimentation)"                                                                                  
 [90] ""                                                                                                         
 [91] " ! Nanoflagellates"                                                                                       
 [92] " Flow(N,DOC)       = ZeroOrder"                                                                           
 [93] " Flow(N,Z)         = ZeroOrder"                                                                           
 [94] " "                                                                                                        
 [95] " ! Zooplankton"                                                                                           
 [96] " Flow(Z,DOC)       = ZeroOrder"                                                                           
 [97] " Flow(Z,D)         = ZeroOrder"                                                                           
 [98] " Z->Sedimentation"                                                                                        
 [99] ""                                                                                                         
[100] " ! Detritus"                                                                                              
[101] " Flow(D,Z)         = ZeroOrder"                                                                           
[102] " Flow(D,DOC)       = ZeroOrder"                                                                           
[103] " D->Sedimentation"                                                                                        
[104] ""                                                                                                         
[105] " ! Bacteria"                                                                                              
[106] " Flow(B,N)         = ZeroOrder"                                                                           
[107] " B->Sedimentation"                                                                                        
[108] ""                                                                                                         
[109] " ! DOC"                                                                                                   
[110] " Flow(DOC,B)       = ZeroOrder"                                                                           
[111] ""                                                                                                         
[112] "## END FLOW"                                                                                              
[113] ""                                                                                                         
[114] "## VARIABLES"                                                                                             
[115] ""                                                                                                         
[116] " GrossProdP1         = Flow(CO2,p1)"                                                                      
[117] " RespirationP1       = Flow(p1,CO2)"                                                                      
[118] " DocReleaseP1        = Flow(P1,DOC)"                                                                      
[119] " SedP1               = Flow(P1,Sedimentation)"                                                            
[120] ""                                                                                                         
[121] " GrossProdP2         = Flow(CO2,p2)"                                                                      
[122] " RespirationP2       = Flow(p2,CO2)"                                                                      
[123] " DocReleaseP2        = Flow(P2,DOC)"                                                                      
[124] " SedP2               = Flow(P2,Sedimentation)"                                                            
[125] ""                                                                                                         
[126] " GrossPrimProd       = GrossProdP1 + GrossProdP2"                                                         
[127] ""                                                                                                         
[128] " Totalresp           = Flow(P1,CO2) +Flow(P2,CO2) +Flow(Z,CO2) +Flow(N,CO2) +Flow(B,CO2)"                 
[129] ""                                                                                                         
[130] " ZooDOCrelease       = Flow(Z,DOC)"                                                                       
[131] " ZooGrazing          = Flow(P1,Z) +Flow(P2,Z) +Flow(N,Z) +Flow(D,Z)"                                      
[132] " ZooFaeces = Flow(Z,D)"                                                                                   
[133] " ZooFaecesSed = Flow(Z,Sedimentation)"                                                                    
[134] " ZooAssimilation     = ZooGrazing - ZooFaeces - ZooFaecesSed - ZooDOCRelease"                             
[135] " ZooRespiration      = Flow(Z,CO2)"                                                                       
[136] " "                                                                                                        
[137] " "                                                                                                        
[138] ""                                                                                                         
[139] " BactRespiration     = Flow(B,CO2)"                                                                       
[140] " BactAssimilation    = Flow(DOC,B)    ! 100% efficiency"                                                  
[141] " SedB             = Flow(B,Sedimentation)"                                                                
[142] ""                                                                                                         
[143] " NanoRespiration     = Flow(N,CO2)"                                                                       
[144] " NanoGrazing         = Flow(B,N)+Flow(P1,N)"                                                              
[145] " NanoGrazingBacteria = Flow(B,N)"                                                                         
[146] " NanoGrazingP1       = Flow(P1,N)"                                                                        
[147] ""                                                                                                         
[148] " NanoAssimilation    = NanoGrazing    ! 100% efficiency"                                                  
[149] ""                                                                                                         
[150] " DetritusDOCrelease  = Flow(D,DOC)"                                                                       
[151] " SedD                = Flow(D,Sedimentation)"                                                             
[152] ""                                                                                                         
[153] ""                                                                                                         
[154] "## END VARIABLES"                                                                                         
[155] ""                                                                                                         
[156] ""                                                                                                         
[157] "!======================!"                                                                                 
[158] "! EQUALITY CONSTRAINTS !"                                                                                 
[159] "!======================!"                                                                                 
[160] ""                                                                                                         
[161] "## EQUATION"                                                                                              
[162] ""                                                                                                         
[163] "! Gross primary production"                                                                               
[164] "  GrossPrimProd=85.78!(SE 30.32)"                                                                         
[165] ""                                                                                                         
[166] "! Total respiration"                                                                                      
[167] "  Totalresp=335.77!(SE 11.69)"                                                                            
[168] ""                                                                                                         
[169] "! Net bacterial production"                                                                               
[170] " BactAssimilation - BactRespiration =16.19!(SE 8.15)"                                                     
[171] ""                                                                                                         
[172] "! Sedimentation"                                                                                          
[173] "!SedP1=0.008   !(SE 0.45)"                                                                                
[174] " SedP2=0.34!(SE 0.13)"                                                                                    
[175] "  ZooFaecesSed=0.78!(SE 0.40)"                                                                            
[176] " SedB + SedD=13.92!(SE 4.51)"                                                                             
[177] ""                                                                                                         
[178] ""                                                                                                         
[179] "## END EQUATION"                                                                                          
[180] ""                                                                                                         
[181] ""                                                                                                         
[182] "!===================!"                                                                                    
[183] "! CONSTRAINTS       !"                                                                                    
[184] "!===================!"                                                                                    
[185] ""                                                                                                         
[186] ""                                                                                                         
[187] "## CONSTRAINT"                                                                                            
[188] ""                                                                                                         
[189] "! Detritus DOC release"                                                                                   
[190] "!--------------------------"                                                                              
[191] " DetritusDOCrelease < 0.02* D"                                                                            
[192] ""                                                                                                         
[193] "! Gross primary production : mass-specific"                                                               
[194] "!--------------------------"                                                                              
[195] " GrossProdP1*P2  =GrossProdP2*P1*[1,2]"                                                                   
[196] ""                                                                                                         
[197] "! Grazing of nanoflagellates"                                                                             
[198] "!----------------------------"                                                                            
[199] " NanoGrazingBacteria*P1 = [0.5,2]*NanoGrazingP1*B                 "                                       
[200] ""                                                                                                         
[201] "! Zooplankton grazing"                                                                                    
[202] "!--------------------------"                                                                              
[203] " -Flow(D,Z)*P1-Flow(D,Z)*P2+Flow(P1,Z)*D+Flow(P2,Z)*D   > 0"                                              
[204] ""                                                                                                         
[205] "! Zooplankton assimilation"                                                                               
[206] "!--------------------------"                                                                              
[207] " ZooAssimilation = [0.4,0.8]*Zoograzing"                                                                  
[208] ""                                                                                                         
[209] "! Heterotroph respiration"                                                                                
[210] "!--------------------------"                                                                              
[211] " ZooRespiration  = Z*MaintenanceResp + ZooAssimilation * [0.4,1.0] !not recoverable from calculated flows"
[212] " BactRespiration = B*MaintenanceResp + BactAssimilation* [0.4,1.0]"                                       
[213] " NanoRespiration = N*MaintenanceResp + NanoAssimilation* [0.4,1.0] !not recoverable from calculated flows"
[214] ""                                                                                                         
[215] "! Autotroph respiration"                                                                                  
[216] "!--------------------------"                                                                              
[217] " RespirationP1=GrossProdP1*[0.05,0.55]"                                                                   
[218] " RespirationP2=GrossProdP2*[0.05,0.55]"                                                                   
[219] ""                                                                                                         
[220] "! Autotroph DOC release"                                                                                  
[221] "!--------------------------"                                                                              
[222] " DOCreleaseP1 = GrossProdP1 * [0.05,1]"                                                                   
[223] " DOCreleaseP2 = GrossProdP2 * [0.05,1]"                                                                   
[224] ""                                                                                                         
[225] "! Zooplankton DOC release"                                                                                
[226] "!--------------------------"                                                                              
[227] " ZooDOCrelease = ZooGrazing*[0.1,1.0] !not recoverable from calculated flows"                             
[228] ""                                                                                                         
[229] "! Sedimentation of bacteria"                                                                              
[230] "!--------------------------"                                                                              
[231] " SedB < BactAssimilation - BactRespiration"                                                               
[232] ""                                                                                                         
[233] "## END CONSTRAINT"                                                                                        
> 
> # RigaAutumnInput is a vector of text strings - 
> # here it is first converted to a "File" 
> # When using the example files in the LIM directory, 
> # this first statement is not necessary
> ## Not run: 
> ##D File <- textConnection(FILERigaAutumn)
> ##D RigaAutumn.input <- Read(File)
> ## End(Not run)
> 
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>