{
  "cells": [
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "collapsed": false
      },
      "outputs": [],
      "source": [
        "%matplotlib inline"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {},
      "source": [
        "\n# Zinn & Harvey transformation\n\nHere, we transform a field with the so called \"Zinn & Harvey\" transformation presented in\n[Zinn & Harvey (2003)](https://www.researchgate.net/publication/282442995_zinnharvey2003)_.\nWith this transformation, one could overcome the restriction that in ordinary\nGaussian random fields the mean values are the ones being the most connected.\n\nSee :any:`transform.zinnharvey`\n"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "collapsed": false
      },
      "outputs": [],
      "source": [
        "import gstools as gs\n\n# structured field with a size of 100x100 and a grid-size of 1x1\nx = y = range(100)\nmodel = gs.Gaussian(dim=2, var=1, len_scale=10)\nsrf = gs.SRF(model, seed=20170519)\nsrf.structured([x, y])\nsrf.transform(\"zinnharvey\", conn=\"high\")\nsrf.plot()"
      ]
    }
  ],
  "metadata": {
    "kernelspec": {
      "display_name": "Python 3",
      "language": "python",
      "name": "python3"
    },
    "language_info": {
      "codemirror_mode": {
        "name": "ipython",
        "version": 3
      },
      "file_extension": ".py",
      "mimetype": "text/x-python",
      "name": "python",
      "nbconvert_exporter": "python",
      "pygments_lexer": "ipython3",
      "version": "3.8.6"
    }
  },
  "nbformat": 4,
  "nbformat_minor": 0
}