Possibly this should be submitted as a bug-fix…
Why does the class Problem store a reference to the CostFunction and a reference to the Constraint?
This seems incredibly bad programming / commenting. A call to create a Problem class of the form:
Problem prob(preCreatedCostFunction, PositiveConstraint(), initialValues);
will fail unpredictably at optimisation time as the Constraint is no longer a valid reference.
If you want to force the CostFunction and the Constraint to be pre-created at the very least this should be commented, better would be to pass a shared pointer (which could be tested).
Simon
This communication and any attachments contains information which is confidential and may be subject to legal privilege. It is for intended recipients only. If you are not the intended recipient you must not copy, distribute, publish, rely on or otherwise use it without our consent. Some of our communications may contain confidential information which it could be a criminal offence for you to disclose or use without authority. If you have received this email in error please notify [hidden email] immediately and delete the email from your computer.
The FSA reserves the right to monitor all email communications for compliance with legal, regulatory and professional standards.
This email is not intended to nor should it be taken to create any legal relations or contractual relationships. This email has originated from
The Financial Services Authority (FSA)
25 The North Colonnade,
Canary Wharf,
London
E14 5HS
United Kingdom
Registered as a Limited Company in England and Wales No.1920623.
Registered Office as above
Switchboard: 020 7066 1000
Web Site: http://www.fsa.gov.uk
*****************************************************************
Free forum by Nabble | Disable Popup Ads | Edit this page |