/GulfStream

Legacy MATLAB scripts for the Gulf Stream paper.

Primary LanguageMATLAB

Documentation

This repository contains the source code for the following paper, please pursue this link to access it:

Li, B., de Queiroz, A. R., DeCarolis, J. F., Bane, J., He, R., Keeler, A. G., Neary, V. S. The economics of electricity generation from Gulf Stream currents. Energy, 134 (2017): 649 - 658.

Resource assessment

  • processing.m

    • MABSAB model covers a vast sea area and original data files are huge in size, usually several GB. This script reads original netCDF files generated by MABSAB model and extracts velocity components only within a specified region.
    • Input: ocean_his_xxxx.nc
    • Output: <year>.mat
  • process_depth.m

    • MABSAB represents depth by 36 terrain-following layers, therefore, bathymetry is needed to determine the exact depth of each layer. Original bathymetry data (depth_rho.mat) covers the whole MABSAB model domain, which is gigantic. This script reads the original data and extracts the data within a specified domain only.
    • Input: depth_rho.mat
    • Output: depth_domain.mat

Portfolio optimization

  • MEP_calculate.m

    • Input : <year>.mat, depth_domain.mat
    • Output: Save monthly energy output (MEP_grid) in MEP<year>.mat, each year is an independent file
  • MEP_combine.m

    • Input: MEP<year>.mat
    • Output: A single file (MEP.mat) including 6 years of monthly energy output (MEP)
  • pa_preprocess.m

    • Input: MEP.mat, 2009result.mat
    • Output: Figure 3 (coefficient of correlation vs. distance) and Figure A (in the Appendix, frequency vs. distance).
  • pa.m

    • This script runs the portfolio optimization as a continuous quadratic programming (QP) problem.
    • Input: MEP.mat, depth_domain.mat, 2009result.mat
    • Output: A figure showing CF vs. 𝜎2.
  • pa_miqp.m

    • This script runs the portfolio optimization as a mixed integer quadratic programing (MIQP) problem.
    • Input: MEP.mat, depth_domain.mat, 2009result.mat, <year>result.mat if run 6-site test case
    • Output: Due to computational complexity, this model is never solved and a two-stage simplified version is solved instead.
  • pa_2step.m

    • This script runs the portfolio optimization as a two-stage problem, the first stage is a continuous linear programming problem (LP) and the second step is a mixed integer quadratic programing (MIQP) problem.
    • Input: MEP.mat, depth_domain.mat, 2009result.mat
    • Output: A scatter graph showing Pareto frontier of both stages

Economic characterization

  • LC.m

    • This script calculates levelized cost of electricity (LCOE) for each site within the domain. It is assumed that each single site is with a dedicated transmission line to onshore grid. Note this one is using the old data from FY2013-2014 spreadsheet model.
    • Input: depth_domain.mat and <year>.mat
    • Output: <year>result.mat
  • LCnew.m

    • This script does the same thing as LC.m, which calculates LCOE of each single site. This one is using new component cost harmonized with Sandia's Reference Model 4.
    • Input: depth_domain.mat and <year>.mat
    • Output: <year>result.mat
  • LC_pa_2step.m

    • This scripts calculates LCOE of each optimal portfolio. Note that the collection point for each portfoio of multiple sites is optimized such that the total transmission cost is minimized.
    • Input: MEP.mat, depth_domain.mat and pa_2step_result.depth.mat
    • Output: A box plot showing cost share of each component in percentage