Last active
June 28, 2019 17:14
-
-
Save Shogun89/615e1945998412ac6924502e85455a8a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% Here are some test values | |
a=1 | |
b=2 | |
c=3 | |
d=4 | |
% calling the trial function with the test values | |
result = trial_function(a,b,c,d) | |
% displaying the result, note that it is disp not print | |
disp(result) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function your_result = trial_function(a,b,c,d) | |
A = [0,1;1, a]; | |
B = [0,1;1,b]; | |
C = [0,1;1,c]; | |
D = [0,1;1,d]; | |
% the product of the matrices. Set the return value above: function generic_result = generic_name(args) | |
your_result = A*B*C*D; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment