Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Simple Code wont run!
Replies: 4   Last Post: Nov 1, 2012 2:47 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
James

Posts: 4
Registered: 11/1/12
Simple Code wont run!
Posted: Nov 1, 2012 1:22 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

I am currently try to create a function with nested functions inside. The error I am currently receiving from matlab is

Output argument "cosine" (and maybe
others) not assigned during call to "C:\users\etc..."

Where exactly am i going wrong? I am very new to matlab and do not know what I am missing!

Code:

function [cosine] = james(x)

function [cosine]= euler(x)
e = exp(1);
cosine = e^(ix)-isin(x)
end

end



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.