??? Undefined function or method 'In' for input arguments of type 'char'.

Hi all,
I am trying to calculate the position of a point (x y z) with help of the points rotations. i have declared the rotation and all the other point inside the same m file. But i still get the below error
??? Undefined function or method 'In' for input arguments of type 'char'.
Thank in advance.
Regards, Bala

6 件のコメント

Wayne King
Wayne King 2011 年 10 月 13 日
You have to tell us what In is
Jan
Jan 2011 年 10 月 13 日
Please post the complete error message and show the line, which causes the error.
Image Analyst
Image Analyst 2011 年 10 月 13 日
You aren't, by chance, trying to take the natural logarithm are you? The function for that is log().
Balaji
Balaji 2011 年 10 月 13 日
Hi all,
thanks for the reply, but i just have the following code and i got this error. don't know why i am having this problem.
MAIN_CORD_SYS = [0 0 0];
MAIN_CORD_SYS_RELATIVE= [30 0 10];
CAB_CORD_SYS=[-165 0 785]; % The CVM uses MAIN relative
ENGINE_CORD_SYS_RELATIVE = [35 0 10];
FRONT_AXLE_CORD_SYS_RELATIVE = [304 0 100];
CAB_REF_POINT=[16.00 -37 87.00];
ENGINE_REF_POINT=[10.00 0.00 25.00];
FRONT_AXLE_REF_POINT=[80.00 0.00 0.00];
roll= (3.705866E-05)*(180/pi);
pitch=(-2.732535E-05)*(180/pi);
yaw=(-1.924688E-04)*(180/pi);
RX = [1 0 0;0 cos(roll) sin(roll);0 -sin(roll) cos(roll)];
RY = [cos(pitch) 0 -sin(pitch);0 1 0;sin(pitch) 0 cos(pitch)];
RZ = [cos(yaw) sin(yaw) 0;-sin(yaw) cos(yaw) 0 ;0 0 1];
XYZ=(RX*RY*RZ);
XZY=(RX*RZ*RY);
YXZ=(RY*RX*RZ);
YZX=(RY*RZ*RX);
ZXY=(RZ*RX*RY);
ZYX=(RZ*RY*RX);
R=XYZ;
RESULTS= MAIN_CORD_SYS_RELATIVE+(CAB_REF_POINT*R);
MR+CAB_REF_POINT;
Output=RESULTS-(MR+CAB_REF_POINT)
Jan
Jan 2011 年 10 月 13 日
Please, Bali, post the complete error message. It contains the line, which causes the problem. It is not useful if we try to guess, what your problem is, when it appears explicitely written in your command window.
In addition you should use the debugger, to find out, what's going on: Type "dbstop if error" in the command window and run your program again. Then Matlab stops, when the error occurs and you can check the variables.
Wayne King
Wayne King 2011 年 10 月 13 日
I don't see how you're getting the error you report with this. I can see how you get an error that MR is not defined, but nothing about "In"

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

 採用された回答

Balaji
Balaji 2011 年 10 月 13 日

1 投票

Hi all,
Thanks for the help.
I found out the problem, i was having sapce in the file name "In File.m" and it caused the below error
??? Undefined function or method 'In' for input arguments of type 'char'.
The file works fine after removing the space in the file name.
once again thank you everyone.
Regards, Bala

その他の回答 (1 件)

wahad rahmann
wahad rahmann 2018 年 11 月 14 日

0 投票

Hi every one,
when i run this code
import ETS2.*
syms a1 a2 x y real
q1 = 30; q2 = 40;
E = Rz('q1')*Tx(a1)*Rz('q2')*Tx(a2);
TE = E.fkine( [q1,q2] );
simplify(TE)
it give error like this
''Undefined function or method 'Rz' for input arguments of type 'char'.
Error in ==> Untitled at 4
E = Rz('q1')*Tx(a1)*Rz('q2')*Tx(a2);''
please guide me.
thanks in advance

1 件のコメント

Walter Roberson
Walter Roberson 2018 年 11 月 14 日
You appear to be importing java methods related to European Truck Simulator 2. Where did you find the java code?

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

カテゴリ

ヘルプ センター および File ExchangeData Type Conversion についてさらに検索

質問済み:

2011 年 10 月 13 日

コメント済み:

2018 年 11 月 14 日

Community Treasure Hunt

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

Start Hunting!

Translated by