필터 지우기
필터 지우기

How would I go about plotting Tupper's self-referential formula in MATLAB?

조회 수: 3 (최근 30일)
Nathan Wieczorek
Nathan Wieczorek 2017년 4월 2일
답변: Carl 2017년 4월 4일
The formula itself is:
1/2 < floor(mod(floor(y/17)*2^(-17*floor(x)-mod(floor(y), 17)),2))
How could I plot this in an x,y Cartesian graph in matlab with axes:
0<= x <= 105
n <= y <= n+16

답변 (1개)

Carl
Carl 2017년 4월 4일
Hi Nathan, you would first have to find the values of (x,y) that satisfy that inequality, under those constraints. Assuming you have those points, you can construct a matrix of binary values and simply plot that.
points = randi([0 1], 106, 17);
imagesc(points);
colormap gray; axis equal;

카테고리

Help CenterFile Exchange에서 Colormaps에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by