% C. Talarico % wheat.m clear all; close all; clc; % Wheatstone bridge equations: % Approach #1 % 5*it = 1 % 12.5*ib = 1 % OR % 5*it + 0*ib = 1 % 0*it + 12.5*ib = 1 % Ax = b A = [5 0; 0 12.5] b = [1; 1] x = A\b x = inv(A)*b % Appproach #2 syms it ib; sol = solve(5*it == 1, 12.5*ib == 1) % Carefuk: solutions in order ib, it SOL = [sol.it sol.ib] it = vpa(SOL(1)) ib = vpa(SOL(2))