[ADMB Users] FW: [Developers] FW: ADMB-RE
Mark Maunder
mmaunder at iattc.org
Mon Oct 24 09:42:23 PDT 2011
For your info
From: dave fournier [mailto:davef at otter-rsch.com]
Sent: Sunday, October 23, 2011 4:46 PM
To: Mark Maunder
Cc: developers at admb-project.org
Subject: Re: [Developers] FW: ADMB-RE
On 11-10-23 04:07 PM, Mark Maunder wrote:
When I developed ADMB Griewank wanted me to make the copy constructor for
dvariables to be a deep copy. This introduced all kinds of technical difficulties
(hence the exestence of prevariables). It did not seem to have any real advantage.
So for df1b2variables I went back to shallow copies. The only thing you need to
lnow is that as you discovered
df1b2variable x =y;
means that x and y are the same. This is already the case for dvar_vectors.
See below
From: Richard Bian [mailto:r.bian at niwa.co.nz]
Sent: Sunday, October 23, 2011 2:49 PM
To: Mark Maunder
Subject: ADMB-RE
Hi Mark,
When I code my model, I noticed something interesting in ADMB-RE. Assuming x is a dvariable, if I declare another dvariable y this way, dvariable y=x; then when I change y, x will be changed in the RE round, but not in ordinary ADMB round. I guess when ADMB-RE converts the tpl to cpp in the df1b2_parameters functions, it declares y as x's reference rather than an normal variable. I didn't see this mentioned in the manual, so I think I'd let you know about this.
Regards,
Richard
Richard Bian
National Institute of Water & Atmospheric Research
41 Market Place
Auckland Central 1010, New Zealand
Tel: +64 9 375 2054 Fax: +64 9 375 2051
Please consider the environment before printing this email.
NIWA is the trading name of the National Institute of Water & Atmospheric Research Ltd.
_______________________________________________
Developers mailing list
Developers at admb-project.org<mailto:Developers at admb-project.org>
http://lists.admb-project.org/mailman/listinfo/developers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.admb-project.org/pipermail/users/attachments/20111024/1fc8509d/attachment.html>
More information about the Users
mailing list