Differences of results between the desktop version and the SDK one

  • Juliette Marti
  • Topic Author
More
20 May 2019 16:02 - 20 May 2019 16:03 #6807 by Juliette Marti
Hello, I'm new to the SDK. I notice that the results of the financial model are different when calculated with the Desktop version or with the code generated by SAM 2018.11.11 itself (I tried with Python 2, Python 3, and Matlab). For example, the size of debt value is 284 millions for the desktop version, but 259 millions for the generated code. Can anyone explain me why this is happening?



Thank you a lot in advance.
Last edit: 20 May 2019 16:03 by Juliette Marti.

Please Log in or Create an account to join the conversation.

  • Paul Gilman
More
20 May 2019 19:27 - 20 May 2019 19:28 #6810 by Paul Gilman
Hi,

There are a couple of things that might cause differences between results generated by SAM and those generated by code you write that calls the SSC API:

1. SAM is using a different SSC library than your code.
2. There are differences in the inputs between SAM and your code.
3. Different rounding errors in SAM and your code.

SAM's code generator should automatically copy the SSC library file from the SAM installation to the folder with your code, and assign input variable values identical to the inputs in SAM.

The debt_option input may be responsible for the size of debt difference in your results.

Best regards,
Paul.
Last edit: 20 May 2019 19:28 by Paul Gilman.

Please Log in or Create an account to join the conversation.

  • Juliette Marti
  • Topic Author
More
21 May 2019 10:40 - 21 May 2019 10:40 #6814 by Juliette Marti
Thank you for your answer! After a few investigations, the problem seems to be different rounding errors between SAM and the generated code. I have to say that I have no idea of how to solve that issue.
Last edit: 21 May 2019 10:40 by Juliette Marti.

Please Log in or Create an account to join the conversation.

  • Paul Gilman
More
30 May 2019 16:52 #7344 by Paul Gilman
One approach might be to present your results rounded to the nearest meaningful digit. For example, perhaps round annual energy to the nearest MWh like 244,864,000 kWh.

Best regards,
Paul.

Please Log in or Create an account to join the conversation.

  • Anton Driesse
More
17 Jun 2019 15:18 #7460 by Anton Driesse
Actually, the "PPA price (year 1)" looks quite different.

Please Log in or Create an account to join the conversation.

Moderators: Paul Gilman
Powered by Kunena Forum