{
  "cells": [
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "collapsed": false
      },
      "outputs": [],
      "source": [
        "%matplotlib inline"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {},
      "source": [
        "\n# Basic Methods\n\nThe covariance model class :any:`CovModel` of GSTools provides a set of handy\nmethods.\n\nOne of the following functions defines the main characterization of the\nvariogram:\n\n- ``CovModel.variogram`` : The variogram of the model given by\n\n  .. math::\n      \\gamma\\left(r\\right)=\n      \\sigma^2\\cdot\\left(1-\\rho\\left(r\\right)\\right)+n\n\n- ``CovModel.covariance`` : The (auto-)covariance of the model given by\n\n  .. math::\n      C\\left(r\\right)= \\sigma^2\\cdot\\rho\\left(r\\right)\n\n- ``CovModel.correlation`` : The (auto-)correlation\n  (or normalized covariance) of the model given by\n\n  .. math::\n      \\rho\\left(r\\right)\n\n- ``CovModel.cor`` : The normalized correlation taking a\n  normalized range given by:\n\n  .. math::\n      \\mathrm{cor}\\left(\\frac{r}{\\ell}\\right) = \\rho\\left(r\\right)\n\n\nAs you can see, it is the easiest way to define a covariance model by giving a\ncorrelation function as demonstrated in the introductory example.\nIf one of the above functions is given, the others will be determined:\n"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "collapsed": false
      },
      "outputs": [],
      "source": [
        "import gstools as gs\n\nmodel = gs.Exponential(dim=3, var=2.0, len_scale=10, nugget=0.5)\nax = model.plot(\"variogram\")\nmodel.plot(\"covariance\", ax=ax)\nmodel.plot(\"correlation\", ax=ax)"
      ]
    }
  ],
  "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
}