newbie99 0 / 0 / 0 Регистрация: 04.06.2015 Сообщений: 7 |
||||
1 |
||||
04.06.2015, 08:51. Показов 4721. Ответов 3 Метки нет (Все метки)
были различные ошибки, но смог их исправить, но с этой встал в ступор и не могу понять как быть
Error using plot
__________________
0 |
Programming Эксперт 94731 / 64177 / 26122 Регистрация: 12.04.2006 Сообщений: 116,782 |
04.06.2015, 08:51 |
3 |
3368 / 1893 / 569 Регистрация: 09.04.2015 Сообщений: 5,297 |
|
04.06.2015, 09:09 |
2 |
Решение В строке 2 переменная x, она во фрагменте не задана.
0 |
newbie99 0 / 0 / 0 Регистрация: 04.06.2015 Сообщений: 7 |
||||
04.06.2015, 09:28 [ТС] |
3 |
|||
спасибо, подтолкнули в нужную сторону, исправил и заработало Добавлено через 4 минуты
не одно, так другое т_т
0 |
3368 / 1893 / 569 Регистрация: 09.04.2015 Сообщений: 5,297 |
|
04.06.2015, 11:31 |
4 |
Разберись с параметрами fplot, что там за пустые скобки?
0 |
IT_Exp Эксперт 87844 / 49110 / 22898 Регистрация: 17.06.2006 Сообщений: 92,604 |
04.06.2015, 11:31 |
4 |
Содержание
- Error using plot Vectors must be the same length.
- Direct link to this question
- Direct link to this question
- Answers (1)
- Direct link to this answer
- Direct link to this answer
- See Also
- Categories
- Community Treasure Hunt
- How to Get Best Site Performance
- Americas
- Europe
- Asia Pacific
- Error using plot3 Vectors must be the same length.
- Direct link to this question
- Direct link to this question
- Direct link to this comment
- Direct link to this comment
- Answers (1)
- Direct link to this answer
- Direct link to this answer
- See Also
- Categories
- Community Treasure Hunt
- How to Get Best Site Performance
- Americas
- Europe
- Asia Pacific
- Error using plot Vectors must be the same length.
- Direct link to this question
- Direct link to this question
- Direct link to this comment
- Direct link to this comment
- Answers (1)
- Direct link to this answer
- Direct link to this answer
- See Also
- Categories
- Products
- Community Treasure Hunt
- How to Get Best Site Performance
- Americas
- Europe
- Asia Pacific
- Error using plot Vectors must be the same length.
- Direct link to this question
- Direct link to this question
- Accepted Answer
- Direct link to this answer
- Direct link to this answer
- Direct link to this comment
- Direct link to this comment
- More Answers (0)
- See Also
- Categories
- Community Treasure Hunt
- How to Get Best Site Performance
- Americas
- Europe
- Asia Pacific
- Error using plot3 — Vectors must be the same length
- Direct link to this question
- Direct link to this question
- Accepted Answer
- Direct link to this answer
- Direct link to this answer
- More Answers (0)
- See Also
- Categories
- Products
- Release
- Community Treasure Hunt
- How to Get Best Site Performance
- Americas
- Europe
- Asia Pacific
Error using plot Vectors must be the same length.
Direct link to this question
Direct link to this question
0 Comments
Answers (1)
Direct link to this answer
Direct link to this answer
0 Comments
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Читайте также: No proposal chosen notify error
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot3 Vectors must be the same length.
Direct link to this question
Direct link to this question
1 Comment
Direct link to this comment
Direct link to this comment
Answers (1)
Direct link to this answer
Direct link to this answer
0 Comments
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
Читайте также: Digma dicam 145 прошивка
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot Vectors must be the same length.
Direct link to this question
Direct link to this question
1 Comment
Direct link to this comment
Direct link to this comment
Answers (1)
Direct link to this answer
Direct link to this answer
0 Comments
See Also
Categories
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot Vectors must be the same length.
Direct link to this question
Direct link to this question
0 Comments
Accepted Answer
Direct link to this answer
Direct link to this answer
1 Comment
Direct link to this comment
Direct link to this comment
More Answers (0)
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
Читайте также: Error ioctl no such device
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot3 — Vectors must be the same length
Direct link to this question
Direct link to this question
0 Comments
Accepted Answer
Direct link to this answer
Direct link to this answer
0 Comments
More Answers (0)
See Also
Categories
Products
Release
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
plot Vectors must be the same lengths
Here is my code
I want to have a figure that the X label is i, the Y label is v and we can see change of V in different Temperature (T). but I face the error that «plot Vectors must be the same lengths.»
How can I fix this error?
2 Answers 2
Check dimension of your x, y vector by using size(i) size(V) . i should be a vector and the size should be [1 Len] or [Len 1]. Make sure the size of V is [Len, xxx] or [xxx, Len] too, so they are in the same length and you can plot it. Also, make sure i, and V have the same length ‘Len’ in the same dimension, otherwise you can use dot quotation operator, V.’ , to get the transpose.
As Steven mentioned, you have a dimensional mismatch. Getting more familiar with a couple of the Matlab array operators (: and .) explained in the code can shorten and clarify the code.
Housekeeping before we get started:
Declare all your variables:
use T as a 1×4 and do that stuff first all of these will be 1×4 afterwards T=333:10:363; Notice the use of the dot operator to do pointwise operations
Now let’s do all the parts that involve i. Let’s not start at i=0 because that gives Nan/Inf results i=0.01:0.01:1;
If you wanted to, you could do this with section using matrix multiplication. It’s implemented here with a for loop because that is easier to follow.
In the V=(idx,:) line we are taking the 101×1 vector and shoving it into the idx row of V using the colon operator.
Источник
Error using plot3 Vectors must be the same length.
Direct link to this question
Direct link to this question
1 Comment
Direct link to this comment
Direct link to this comment
Answers (1)
Direct link to this answer
Direct link to this answer
0 Comments
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot3 — Vectors must be the same lengths.
Direct link to this question
Direct link to this question
0 Comments
Answers (1)
Direct link to this answer
Direct link to this answer
1 Comment
Direct link to this comment
Direct link to this comment
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot Vectors must be the same length.
Direct link to this question
Direct link to this question
0 Comments
Answers (1)
Direct link to this answer
Direct link to this answer
2 Comments
Direct link to this comment
Direct link to this comment
Direct link to this comment
Direct link to this comment
,ixOrder]=sort(Radius(index_liq)); % get the sorted order of radius values
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник
Error using plot3 Vectors must be the same length.
Direct link to this question
Direct link to this question
1 Comment
Direct link to this comment
Direct link to this comment
Answers (1)
Direct link to this answer
Direct link to this answer
0 Comments
See Also
Categories
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- Deutsch
- English
- Français
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 简体中文 Chinese
- English
- 日本 Japanese (日本語)
- 한국 Korean (한국어)
Accelerating the pace of engineering and science
MathWorks is the leading developer of mathematical computing software for engineers and scientists.
Источник