Subarray Layout Optimization problem

  • Stergianakos
  • Topic Author
More
24 May 2023 14:38 #12170 by Stergianakos
Subarray Layout Optimization problem was created by Stergianakos
Hello!
I am a new user of SAM, and I am using it to simulate photovoltaic performance. When I simulate a system of approximately 25 kW, the program runs successfully without any warnings, and I obtain the expected results. However, when I attempt to optimize the PV layout based on my area constraint using the "Subarray Layout Optimization" macro, I encounter the following error:
"Macro did not finish.
[839] referencing unassigned variable: modules_per_string_npv."
I am aware that this question has been asked before, but I did not understand the provided answer. According to the post , I should define a financial model. However, I have already set all the tabs related to financial parameters, installation costs, electricity rates, etc. and I had a successful simulation.Additionally, after running the above macro, some inputs changed automatically. For instance, the number of inverters increased to 17 (from 1), the GCR rose to 1 (from 0.5), and the number of strings in parallel increased to 3 (from 1). Is this a bug?Thank you very much.

 

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

  • pgilman
More
24 May 2023 17:04 #12171 by pgilman
Replied by pgilman on topic Subarray Layout Optimization problem
Hi Georgios,

Please attach a copy of the .sam file you are using for this optimization along with either a screenshot of the Subarray Layout Optimization inputs, or a description of the inputs if you would like me to help troubleshoot.

A couple of notes: Be sure to enable self shading on the Shading and Layout page so that the GCR affects the results, and do not use the Estimate Subarray 1 configuration option on the System Design page.

Best regards,
Paul.

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

  • Stergianakos
  • Topic Author
More
25 May 2023 14:24 #12174 by Stergianakos
Replied by Stergianakos on topic Subarray Layout Optimization problem
Hello Paul,

Thank you very much for your quick response! I have attached some images where I have noted some changes the macro made to the inputs, even though I selected the "Do not update" subarray configuration option in the "Subarray Layout Optimization" macro. Note also that the error insists:
"Macro did not finish.
[839] referencing unassigned variable: modules_per_string_npv."


Thank you very much
 

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

  • pgilman
More
27 May 2023 10:34 #12180 by pgilman
Replied by pgilman on topic Subarray Layout Optimization problem
Hi Georgios,

The macro runs successfully for me -- I'm using SAM 2022.11.21 r1. Are you using the latest version of SAM? The macro takes a long time to run but finishes and shows results.

I did need to fix one thing about the inputs in your .sam file: The inverter can only have a single MPPT input for systems with more than one inverter. To fix that, I had to go to the System Design page and change the number of inverters from 7 to 1, then go to the Inverters page and change the number of MPPT inputs to 1 (that input is disabled when the number of inverters is greater than 1), and then go back to the System Design page and change the number of inverters back to 7. I had to click through an error message about the number of MPPT inputs and inverters several times in the process.

Best regards,
Paul.

 

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

  • Stergianakos
  • Topic Author
More
28 May 2023 13:46 #12182 by Stergianakos
Replied by Stergianakos on topic Subarray Layout Optimization problem
Hello Paul,Thank you for your answer. Yes, I am using the latest version of SAM. I tried reinstalling it on my computer, but the error persists. I even tried running the macro on a different computer, and I encountered the same error. What might be the problem? Is there any other input I need to define to make it work? Regarding the number of inverters, as I mentioned in my initial post, they automatically change after running the macro (I'm unsure why), along with the GCR ratio and the number of strings in parallel.Thank you very much

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

  • pgilman
More
30 May 2023 17:45 #12190 by pgilman
Replied by pgilman on topic Subarray Layout Optimization problem
Hi Georgios,

The macro temporarily changes the value of some inputs in the optimization process and then resets those inputs to their original values when the optimization ends. In this case, the error interrupts the macro before the optimization finishes, so those input values never get reset.

I'm looking into what is causing the error and will get back to you when I know more.

Best regards,
Paul.

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

Moderators: pgilman
Powered by Kunena Forum