フィルターのクリア

How to graph two different functions on different axes

1 回表示 (過去 30 日間)
BM
BM 2017 年 8 月 9 日
コメント済み: BM 2017 年 8 月 9 日
Hopefully I am asking this correctly. Is there a way to plot two different functions on two different axes in MATLAB? Say along the y-axis I want to plot the values of the function A(q). Along the x-axis, lets say I want to plot the function log(m). Thus, I want my plot to be log(m) by A(q), knowing that the function on each axis depends on two different variables.
  1 件のコメント
José-Luis
José-Luis 2017 年 8 月 9 日
Do you mean you want to plot a function of two variables?
Or are you trying to define a surface?

サインインしてコメントする。

採用された回答

Jan
Jan 2017 年 8 月 9 日
編集済み: Jan 2017 年 8 月 9 日
I do not know "plotting along an axis". I know 2D diagrams using two axes and plotting y against x. E.g.:
x = 1:0.01:2*pi;
y = sin(x);
plot(x,y);
But of course I can apply a function to x also:
I do not know "plotting along an axis". I know 2D diagrams using two axes and plotting y against x. E.g.:
t = 1:0.01:2*pi;
y = sin(t);
x = cos(t);
plot(x,y);
Or
plot(rand(1,10), rand(1,10))
So what is the problem? What does "plot to be log(m) by A(q)" exactly mean? Simply
plot(log(m), A(q))
  4 件のコメント
Jan
Jan 2017 年 8 月 9 日
As result you will get a line:
x = rand(1, 10);
plot(x, 0, 'o')
Then: yes, of course you can draw sets of points placed on 2 lines in one diagram.
I still do not understand the problem. Simply "plot q by A(q)", and then "plot the values of log(m) along the x-axis to see where the values of +/- log(m) intersect with A(q) on the x-axis." What happens if you simply try it?
BM
BM 2017 年 8 月 9 日
This is only a generalized part of a much larger program. I will think about it some more and come back here if I get stuck. Perhaps then, I will be able to pose a better question!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by