Portrait of Mayk Thewessen

Mayk Thewessen

Time-series simulation and forecasting for the energy transition. Electricity markets, batteries, V2G, flex industry — based in the Netherlands, working at Birdview Energy and independently via Treehouse Energy.

What I work on

I build models and tooling for the Dutch electricity grid: forward price curves, BESS dispatch and revenue stacking, scenario analysis, and grid power-flow studies. Most of it lives in Python on top of PyPSA, linopy, and HiGHS — with a custom HiPO build for the heavier scenarios.

Day to day that means a lot of TenneT, JAO, ENTSO-E, and Ned.nl data; a lot of optimisation; and a steady stream of small upstream PRs back into the open-source stack I depend on.

Electricity markets

I trade the Dutch market across its full stack — from cleared day-ahead curves down to imbalance settlement at quarter-hour resolution. The work touches every product where a battery, V2G fleet, or flexible industrial load can earn revenue, plus the cross-border flows that determine when those products are binding.

Wholesale

  • Day-ahead · EPEX SPOT, Nord Pool
  • Intraday · continuous & auctions
  • ID3 · ID1 · index pricing
  • Forwards · cleared & OTC curves
  • NL · DE · BE · FR · GB · NO · DK

Balancing & ancillary

  • FCR · symmetric, 4-hour blocks
  • aFRR capacity · up & down
  • aFRR energy · merit-order activation
  • mFRR · imbalance settlement
  • TenneT MARI/PICASSO integration

Cross-border

  • Flow-based · JAO domain, PTDFs, RAMs
  • NTC · legacy bilateral capacity
  • Single Day-Ahead Coupling (SDAC)
  • XBID · cross-border intraday
  • Import/export profile reconstruction

Truth sources

  • ENTSO-E Transparency Platform
  • TenneT imbalance, FCR/aFRR
  • EPEX SPOT · Nord Pool
  • Ned.nl · NL renewables truth
  • JAO · flow-based

Generation fleet & commodity fundamentals

Forward power-curve modelling means knowing the fleet — every CCGT and OCGT marginal cost, every renewables capacity factor, every retirement and new-build. Below: the technologies I track and the commodity benchmarks that drive marginal price across the merit order.

Thermal & firm

  • CCGT · OCGT · gas turbines
  • CHP · industrial & district heat
  • Coal · hard coal & lignite
  • Biomass · co-fired & dedicated
  • Nuclear · Oil · Diesel peakers

Renewables fleet

  • Solar PV · utility & rooftop
  • Onshore wind
  • Offshore wind · NL North Sea build-out
  • Hydro · run-of-river & pumped
  • Curtailment & redispatch tracking

Storage & flex

  • Lithium BESS · 1h, 2h, 4h, 8h
  • V2G · fleet aggregation
  • Electrolysers · alkaline & PEM
  • Heat pumps · industrial & district
  • Demand response · industrial flex

Commodity benchmarks

  • Gas TTF · NL hub
  • Coal API2 · ARA delivery
  • CO₂ EUA · ETS futures
  • Brent · Diesel · oil-linked peakers
  • Fuel-to-power conversion w/ heat rates

Renewables modelling

Hourly capacity factors built bottom-up from reanalysis weather and panel/turbine specs — never trust a published CF, build it yourself. Calibrated against Ned.nl for NL solar and wind (the truth source) and ENTSO-E for the rest of Europe.

Solar PV

  • PVGIS · panel-level CF
  • pvlib · physical model chain
  • atlite · gridded CF profiles
  • Tilt, azimuth, soiling, snow
  • Inverter clipping & DC/AC ratio

Wind

  • atlite · ERA5 → CF
  • windpowerlib · power curves
  • Hub-height extrapolation (log law)
  • Wake losses & availability
  • Onshore vs offshore turbine classes

Weather datasets

  • ERA5 · ECMWF reanalysis
  • ERA5-Land · 9 km surface
  • SARAH-3 · solar irradiance
  • MERRA-2 · NASA reanalysis
  • KNMI · NL weather stations

Cross-checks

  • Renewables.ninja · Pfenninger & Staffell
  • Ned.nl · NL realised generation
  • ENTSO-E · per-zone CFs
  • IEA PVPS performance ratios
  • Project-level monitoring data

Time-series & forecasting

Imbalance prices, intraday spreads, and renewables shortfalls — short-horizon forecasting that has to run live, recalibrate daily, and survive distribution shifts. Tree-based regressors do most of the work; deep models earn their keep on longer horizons and when the feature space is genuinely high-dimensional.

Tree boosting

  • XGBoost · default for tabular
  • LightGBM · fast on wide features
  • CatBoost · categorical-heavy markets
  • Quantile regression for prediction intervals
  • SHAP values for diagnostics

Classical & statistical

  • statsmodels · SARIMAX, VAR
  • Prophet · seasonal baselines
  • Exponential smoothing · Holt-Winters
  • Kalman filters · state-space
  • Ridge / Lasso for stable benchmarks

Feature engineering

  • Lag · rolling · expanding windows
  • Calendar (DST · holidays · DoW · Settlement)
  • Weather (T · GHI · wind speed at 10/100m)
  • Market structure (residual load · merit order)
  • Cross-zone spreads & flow-based shadow prices

Deep & validation

  • PyTorch · Lightning
  • Temporal Fusion Transformer · N-BEATS
  • Walk-forward / time-series CV
  • Conformal prediction intervals
  • Backtests against realised settlement

Optimisation & energy systems

Capacity expansion, dispatch, and BESS revenue stacking — all linear or mixed-integer, all on the open-source PyPSA stack. HiGHS with HiPO for the heavier scenarios; small upstream PRs back into linopy and HiGHS when something blocks a real run.

Energy-system modelling

  • PyPSA · network & dispatch
  • PyPSA-Eur · pan-European reference
  • linopy · LP/MIP on xarray
  • powerplantmatching · fleet datasets
  • Custom NL high-voltage power-flow models

Solvers

  • HiGHS · default, open-source
  • HiPO · custom build for hard scenarios
  • Gurobi · CPLEX · when licensed
  • SCIP · MIP fallback
  • YALMIP · MATLAB modelling layer

BESS dispatch

  • Multi-market revenue stacking
  • SoC-aware perfect-foresight LP
  • Rolling-horizon receding-horizon dispatch
  • Stochastic / scenario-based bidding
  • Degradation-aware throughput penalties

Grid & network

  • AC & DC OPF
  • N-1 contingency analysis
  • Congestion & redispatch modelling
  • Connection-point feasibility studies
  • JAO flow-based capacity reconstruction

Data engineering & ML stack

Datasets that don't fit in memory and queries that have to run on a laptop and a cluster. Columnar formats are non-negotiable; pandas where the API matters, polars where the throughput does, DuckDB for everything in between.

DataFrames & arrays

  • numpy · pandas · the daily driver
  • polars · larger-than-memory pipelines
  • xarray · gridded / multi-dim
  • pyarrow · Arrow-native I/O
  • dask · for the rare cluster case

Storage & databases

  • DuckDB · OLAP on parquet, in-process
  • PostgreSQL · transactional, prod
  • SQLite · local truth files
  • TimescaleDB · long time-series
  • parquet · feather · zarr

ML & numerics

  • scikit-learn · pipelines & baselines
  • xgboost · lightgbm · catboost
  • scipy · statsmodels
  • pytorch · lightning
  • Optuna · Hyperopt for HPO

Apps & ops

  • FastAPI · pydantic
  • Streamlit · Dash · quick dashboards
  • Typer · Click · CLIs
  • pixi · uv · conda · envs
  • pytest · ruff · mypy

Geo / GIS & grid topology

Grid models start from geometry — substation coordinates, transmission corridors, land cover, and the gemeente boundaries that determine connection rights. OpenStreetMap is the only open dataset that gets the Dutch HV network roughly right; the rest is calibration.

Vector & raster

  • geopandas · shapely · pyproj
  • rasterio · rioxarray
  • fiona · gdal
  • EPSG:28992 (Amersfoort/RD) for NL

Sources

  • OSM · transmission & substations
  • AHN4 · NL elevation
  • BAG · BRT · NL administrative
  • Copernicus · land cover

Topology & viz

  • networkx · graph algorithms
  • folium · pydeck · kepler.gl
  • plotly · matplotlib · cartopy
  • osmnx · OSM pulls

MATLAB & Simulink

The numerical legacy from TU/e and URE — power-electronics simulation, EV drivetrain modelling, and the original codebase of my MSc thesis. I still reach for it when Simscape Electrical is the right tool, or when a vendor reference model only ships as a Simulink block diagram.

Simulation

  • Simulink · system-level dynamics
  • Simscape Electrical · power circuits
  • PLECS · switched converters
  • Stateflow · controller logic

Toolboxes

  • Optimization Toolbox
  • YALMIP · LP/MIP modelling
  • Statistics & ML Toolbox
  • Signal Processing Toolbox

Where I use it

  • EV traction & DAB OBC simulation
  • MPPT controller prototyping
  • MSc thesis (V2G day-ahead)
  • URE drivetrain models

Career

  1. 2013 – 2017 BSc Electrical Engineering, Technische Universiteit Eindhoven.
  2. 2014 – 2015 University Racing Eindhoven (URE) — EV drivetrain design, part-time alongside the bachelor.
  3. 2017 – 2019 MSc Electrical Engineering, Technische Universiteit Eindhoven. Master's thesis on day-ahead price formation in 2030 with high BESS & V2G penetration — code · scholar.
  4. 2017 – 2020 Taylor Solar — CTO, leading PV DC/DC optimiser design.
  5. 2021 – 2023 Lightyear — Research Scientist, day-ahead market pricing models for the solar EV.
  6. 2023 – present Treehouse Energy — independent consulting on energy markets, BESS, grid congestion, and hourly time-series simulation in Python.
  7. present Birdview Energy — investment-grade BESS revenue & grid-risk analytics across NL / DE / BE.

How a BESS valuation comes together

Most of my work flows through a pipeline like this — fundamentals feed a forward curve, the curve plus asset specs feed a dispatch optimiser, and the optimiser produces a revenue stack across every market a battery can sit in.

flowchart LR
    A[Fundamentals
fuels · weather · capacity] --> D[Calibrate] B[Asset specs
MW · MWh · efficiency · degradation] --> E[Dispatch optimiser
linopy + HiGHS] C[Grid data
TenneT · JAO · zonal] --> F[Congestion & curtailment] D --> G[Hourly forward curve] G --> E E --> H[Revenue stack:
DA · Intraday · FCR · aFRR · Imbalance] F --> I[Investment-grade report] H --> I

Selected projects

Birdcurve

Hourly forward power price curve for NL and neighbouring zones — built from fundamentals (fuel forwards, capacity, renewables generation profiles) and calibrated against the cleared forward market. The curve I use to value BESS revenue across day-ahead, imbalance, and ancillary stacks.

BESSview

Analytics and visualisation for battery energy storage — operational telemetry, dispatch traces, revenue attribution by market, and back-tests against alternative bidding strategies.

NL grid power flow

PyPSA-Eur–based model of the Dutch high-voltage network, calibrated against TenneT data and used to study congestion, curtailment risk, and connection-point capacity for new BESS and industrial load.

Upstream contributions

Small but load-bearing PRs to the optimisation stack — linopy (warmstart, benchmarks), HiGHS (HiPO build path), and PyPSA-Eur. The goal is the same: make the tools faster and less surprising for everyone solving the same problems.

From my GitHub

A handful of public repos — mostly Python, mostly energy data.

All 39 public repos →

Elsewhere