|
[Sponsors] |
December 11, 2014, 01:48 |
C_STORAGE_R and SV_UDSI_M1
|
#1 |
Senior Member
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17 |
In UDF Manual 15.0 example 2.7.4.3 there is a line to retrieve the value of a scalar at previous time step:
Code:
phi_old = C_STORAGE_R(c,t,SV_UDSI_M1(i)); Code:
phi_old = C_UDSI_M1(c,t,i); |
|
May 20, 2015, 05:06 |
exactly my question
|
#2 |
New Member
Franz Roman
Join Date: Jun 2009
Posts: 28
Rep Power: 17 |
Hi,
I am wondering exactly the same. Did you found out if both options are equivalent? Thanks Franz |
|
May 20, 2015, 07:32 |
|
#3 |
Senior Member
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17 |
In the end I didn't use any previous time step macro. Instead I preferred to store variables in user defined memories (C_UDMI), an alternative way to compare with previous time step(s).
|
|
May 20, 2015, 10:21 |
|
#4 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
In mem.h, the following line is found:
Code:
#define C_UDSI_M1(c,t,i)C_STORAGE_R(c,t,SV_UDSI_M1(i)) Code:
phi_old = C_UDSI_M1(c,t,i); Code:
phi_old = C_STORAGE_R(c,t,SV_UDSI_M1(i)); |
|
April 13, 2017, 05:59 |
|
#5 | |
New Member
saeed
Join Date: Mar 2017
Posts: 2
Rep Power: 0 |
Quote:
phi_old = C_T_M1(c, t) Thanks |
||
|
|