there is an error in line 2 and I don't know why
function [y] = BeamElementStiffness(E,I,L,phi,kapa)
y = E*I/phi * [kapa*12/L^3 kapa*6/L^2 -kapa*12/L^3 kapa*6/L^2 ; kapa*6/L^2 (4*kapa+phi)/L -kapa*6/L^2 (2*kapa-phi)/L ; -kapa*12/L^3 -kapa*6/L^2 kapa*12/L^3 -kapa*6/L^2 ; kapa*6/L (2*kapa-phi)/L -kapa*6/L^2 (kapa4+phi)/L];
end

Answers (1)

Star Strider
Star Strider on 28 Sep 2018
It could be that you ran your function by clicking on the green Run arrow in the Editor. You need to define the function arguments in your workspace (preferably in a script), and then call your function in the same script.

Categories

Find more on Environment and Settings 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!