MATLAB: Help for AND circuit

and gate in matlablogical gates in matlabsimulink

I draw an AND circuit ion matlab 2014 but when I start it an error occurs "Error evaluating expression 'xInitial' for 'InitialState' specified in the Configuration Parameters dialog for block diagram 'AND01': Undefined function or variable 'xInitial'." what shoul I do to solve this problem.

Best Answer

Please type
xInitial = 0;
at the MATLAB command prompt, and then try running the model.
That should eliminate the error, but it may result in a different error. Or the model may run but it may not behave as you intended.
Sorry, but without seeing your model, it is impossible to provide a definitive solution.
Related Question