简体   繁体   English

在Matlab中生成正弦波模式

[英]Generate sinusoidal patterns in Matlab

How can I generate the following 我如何生成以下内容 图片 in Matlab? 在Matlab中?

and How generates these patterns : 以及如何生成这些模式: image2

Like this: 像这样:

f= % you choose
A=repmat(sin(linspace(0,f*(2*pi+pi),256)),[256 1]);

imshow(A)

在此处输入图片说明

Explanation: linspace creates linearly spaced point to control the size of the image (change 256 by something else). 说明: linspace创建线性间隔的点以控制图像的大小(通过其他方法更改256)。 repmat repeats the sin wave every row if the image. repmat如果图像每行重复一次sin波。

Change the initial and final angle to control the behaviour in the corners 更改初始角度和最终角度以控制拐角处的行为

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM