File:Shepard interpolation 2.png

Summary

Description
English: Shepards interpolation method, sampling a smooth function, exp(-x^2-y^2). See also File:Shepard interpolation.png
Date
Source Own work
Author Hankwang

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
Creative Commons CC-Zero This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication.
The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.

Category:CC-Zero#Shepard%20interpolation%202.pngCategory:Self-published work

Data

#!/usr/bin/perl -w

$n=40;
$p=0.1;
srand(6);
for ($i = 0; $i < $n; ++$i) {
    $x = rand(1);
    $y = rand(1);
    $v = (rand(1) < $p) ? 1 : 0;
    print("$x $y $v\n");
}
Category:Interpolation Category:Images with Perl source code
Category:CC-Zero Category:Images with Perl source code Category:Interpolation Category:PNG created with Gnuplot Category:Self-published work