フィルターのクリア

make log spacing, specifying the length of the first interval

5 ビュー (過去 30 日間)
Toke
Toke 2013 年 2 月 18 日
Hi
Let say I want to divide one second into 10 points, where the first length is 8 ms. How can I do that?
the logspace function does not give the option of defining the length of the first interval.
The closest I can get is logspace(log10(0.1),log10(1),10), but the first invertal is on only 3 ms.

採用された回答

Walter Roberson
Walter Roberson 2013 年 2 月 18 日
It is not possible to logspace a finite number of intervals that include time 0.
Perhaps what you would like is:
F = 0.08; L = 1; N = 10;
t = [F F.*(L/F).^(1/(N-1)).^(1:N)];

その他の回答 (1 件)

Youssef  Khmou
Youssef Khmou 2013 年 2 月 18 日
hi, specify the first length :
% Logspace
s=logspace(0,1,10)/10;
s(1)=0.008; % 8 ms
% Or linear Space
s2=linspace(0,1,10);
s2(1)=0.008; % 8ms

カテゴリ

Help Center および File ExchangeCreating and Concatenating Matrices についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by