why error is coming "undefined function or variable"?

1 view (last 30 days)
i am trying to declare one qudratic equation but getting this error in R2017b and R2020b also
M1=bit3xor(u2,w2,bitxor(bit3xor(bitand(v2,d2))));
Error: Undefined function or variable 'bit3xor'.
Please someone help me in removing this error.

Answers (1)

KALYAN ACHARJYA
KALYAN ACHARJYA on 21 Nov 2020
Edited: KALYAN ACHARJYA on 21 Nov 2020
There is no such "bit3xor" inbuilt function in MATLAB. It might be custom function, if so please keep the bit3xor.m file in the same working directory.
  1 Comment
Dhruv Bhatnagar
Dhruv Bhatnagar on 21 Nov 2020
Thank You Sir.
But Sir I made change and used like this for f10 equation but still operation is not working What is going wrong in this.
f10 = 1 + v2 + x2 + x2v2 + x2v3 + x3v2 + x2w2 + x2w3 + x3w2
This qudratic equation I want to evaluate using Matlab so I wrote like this.
Z=quad(0,1,1,0,1,0,1,1);
function F10 = quad(u2,v2,w2,x2,u3,v3,w3,x3)
F10=bitxor(1,v2,x2,bitxor(bitxor(bitand(x2,v2),bitand(x2,v3),bitand(x3,v2)),bitxor(bitand(x2,w2),bitand(x2,w3),bitand(x3,w2))));
end

Sign in to comment.

Categories

Find more on Startup and Shutdown in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!