MATLAB: How to define a symbolic vector symbolic vector I would like to define a symbolic vector like y = [0 1]*x where x is [x1 ; x2]. So basically y actually equals to x2. Is it possible? Best Answer Yes!syms x1 x2x = [x1; x2]y = [0 1]*xproduces:y =x2 Related SolutionsMATLAB: How to solve system of 3 differential equations Hi , the following equations are solved symbolically and unknown constants arise because no initial conditions were provided:syms x1(t) x2(t) x3(t) p reqn1 = diff(x1) == r*x1 + p* (x2-x1) eqn2 = diff(x2) == r*x2 + p* (x1+x3-2*x2) eqn3 = diff(x3) == r*x3 + p* (x2-x3)eqns = [eqn1 eqn2 eqn3][x1, x2, x3] = dsolve(eqns) MATLAB: How to sum the elements of a symbolic vector syms x1 x2X = [1, x1, x2, x1^2, x2^2, x1*x2], out=char(X(1))for k=2:numel(X) out=[out '+' char(X(k))]end Related QuestionHow to create symbolic vectorIs it possible to simplify symbolic expressions with known relationsDefining symbolic piecewise functionDefine a symbolic variableCoupled Second order differential eq. solution
Best Answer