Thread Subject: saving initial values in simulink

Subject: saving initial values in simulink

From: Nuno Loureiro

Date: 11 Jul, 2011 14:36:10

Message: 1 of 2

Hello,

I am trying to calculate an error with simulink based on the following expression:

Error= (F(t)-F(0))-(V(t)-V(0))

where V is a vector on my workspace (first column is time and second is data) and F is an input value on simulink with a sample time at each time step. F(0) and V(0) are the initial values of the input F and vector V.
My question is: how can I save the values F(0) and V(0) at time t=0 and then use them at every other timestep?

thanks
Nuno

Subject: saving initial values in simulink

From: Nuno Loureiro

Date: 11 Jul, 2011 21:09:09

Message: 2 of 2

"Nuno Loureiro" wrote in message <ivf1oq$rap$1@newscl01ah.mathworks.com>...
> Hello,
>
> I am trying to calculate an error with simulink based on the following expression:
>
> Error= (F(t)-F(0))-(V(t)-V(0))
>
> where V is a vector on my workspace (first column is time and second is data) and F is an input value on simulink with a sample time at each time step. F(0) and V(0) are the initial values of the input F and vector V.
> My question is: how can I save the values F(0) and V(0) at time t=0 and then use them at every other timestep?
>
> thanks
> Nuno

Can anyone help me?

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
initial value Nuno Loureiro 11 Jul, 2011 10:39:08
simulink Nuno Loureiro 11 Jul, 2011 10:39:08
rssFeed for this Thread

Contact us at files@mathworks.com