ファイル:CA rule110s.png

ページのコンテンツが他言語でサポートされていません。

元のファイル(10,000 × 10,000 ピクセル、ファイルサイズ: 167キロバイト、MIME タイプ: image/png)

概要

解説 下記を参照。
日付
原典 原版の投稿者自身による著作物
作者 Grondilu (talk) (Uploads)
その他のバージョン

Made with the following Perl code:

use strict;
use warnings;
use GD;

package Automaton {
    sub new {
        my $class = shift;
        my $rule = [ reverse split //, sprintf "%08b", shift ];
        return bless { rule => $rule, cells => [ @_ ] }, $class;
    }
    sub next {
        my $this = shift;
        my @previous = @{$this->{cells}};
        $this->{cells} = [
            @{$this->{rule}}[
                map {
                    4 * $previous[($_ - 1) % @previous]
                    + 2 * $previous[$_]
                    + $previous[($_ + 1) % @previous]
                } 0 .. @previous - 1
            ]
        ];
        return $this;
    }
    use overload
        q{""} => sub {
            my $this = shift;
            join '', map { $_ ? '#' : ' ' } @{$this->{cells}}
        };

    sub to_image {
        my ($this, $width, $height) = @_;
        my $image = GD::Image->new($width, $height);
        my $black = $image->colorAllocate(0, 0, 0);
        my $white = $image->colorAllocate(255, 255, 255);

        my $x = 0;
        my $y = 0;
        foreach my $cell (@{$this->{cells}}) {
            if ($cell) {
                $image->setPixel($x, $y, $black);
            } else {
                $image->setPixel($x, $y, $white);
            }
            $x++;
            if ($x >= $width) {
                $x = 0;
                $y++;
                last if $y >= $height;
            }
        }
        return $image;
    }
}

my ($width, $height) = (10**4, 10**4);
my @a = map 0, 1 .. $width;
$a[$width - 1] = 1;
my $a = Automaton->new(110, @a);

# Save to file
open(my $out, '>', 'output.png') or die "Cannot open file: $!";
binmode $out;
print $out "P1\n$width $height\n";

for (1 .. $height) {
    print $out join(' ', @{$a->{cells}}) . "\n";
    $a->next;
}

close $out;


ライセンス

この作品の著作権者である英語版ウィキペディアGrondiluさんは、この作品を以下のライセンスで提供しています。
Creative Commons CC-Zero このファイルはクリエイティブ・コモンズ CC0 1.0 全世界 パブリック・ドメイン提供のもとで利用可能にされています。
ある作品に本コモンズ証を関連づけた者は、その作品について世界全地域において著作権法上認められる、その者が持つすべての権利(その作品に関する権利や隣接する権利を含む。)を、法令上認められる最大限の範囲で放棄して、パブリック・ドメインに提供しています。

この作品は、たとえ営利目的であっても、許可を得ずに複製、改変・翻案、配布、上演・演奏することが出来ます。

元のアップロードログ

元のファイルページはこちら。以下の利用者は全てen.wikipediaに属します。
  • 2014-02-28 08:32 Grondilu 1000×1000× (10463 bytes) Made it myself with the following Perl code: <code>use strict; use warnings; package Automaton { sub new { my $class = shift; my $rule = [ reverse split //, sprintf "%08b", shift ]; return bless { rule => $rule, cells => [ @_ ] }, $class;...

キャプション

このファイルの内容を1行で記述してください

このファイルに描写されている項目

題材

28 2 2014

9b1b62f5bf9ee9a880d31358b7337a51c56c12d9

170,613 バイト

10,000 ピクセル

10,000 ピクセル

ファイルの履歴

過去の版のファイルを表示するには、その版の日時をクリックしてください。

日付と時刻サムネイル寸法利用者コメント
現在の版2023年8月4日 (金) 17:142023年8月4日 (金) 17:14時点における版のサムネイル10,000 × 10,000 (167キロバイト)Obscure2020Optimized with OxiPNG and ZopfliPNG.
2023年7月10日 (月) 21:192023年7月10日 (月) 21:19時点における版のサムネイル10,000 × 10,000 (1.75メガバイト)CJKVRShowing more executions
2014年2月27日 (木) 20:412014年2月27日 (木) 20:41時点における版のサムネイル1,000 × 1,000 (10キロバイト)GrondiluBigger version, right aligned.
2006年3月18日 (土) 17:552006年3月18日 (土) 17:55時点における版のサムネイル500 × 250 (2キロバイト)MaksimLa bildo estas kopiita de wikipedia:en. La originala priskribo estas: Smaller version of CA_rule110.png {{GFDL}} {| border="1" ! date/time || username || edit summary |---- | 21:57, 1 February 2005 || en:User:Quadell || <nowiki>(tagged)</nowiki> |

以下の​ 2 ページがこのファイルを使用しています:

グローバルなファイル使用状況

以下に挙げる他のウィキがこの画像を使っています: