[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: vector function within vector function

From: Nicholas Jankowski
Subject: Re: vector function within vector function
Date: Wed, 30 Dec 2015 08:47:44 -0500

On Dec 30, 2015 2:04 AM, "Andreas Weber" <address@hidden> wrote:
> Am 29.12.2015 um 19:24 schrieb ken1866:
> > Hi, I'm brand new to Octave and am trying to understand the concept of vector
> > processing.  I created the following function that works fine with scalar
> > input but when I try vector input I get an error message about nonconformant
> > arguments.
> Hi Ken, your code is missing. Have you tried to attach it as file or
> embedded the code in the email?
> -- Andy

I was able to read it by jumping over to the nabble archive. It shows up as text there, so not sure why it was stripped out of the email the list sent. Thought it might have just been my mobile email client.


num=100; b1=linspace(200,220,num); b2=linspace(0.4,0.8,num);

function val=ls(p1,p2) x=[1,2,3,5,7,10]; y=[109,149,149,191,213,224]; val=sum((y-p1*(1-exp(-p2*x))).^2); endfunction


error: ls: operator *: nonconformant arguments (op1 is 100x100, op2 is 1x6)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]