Topics about getting started or leveling up as an AIMMS developer. Datalinks, AIMMS language, building apps...
- 623 Topics
- 1,358 Replies
Demo time!First off we had a demonstration of the capabilities of Octeract, a global MINLP solver that has been linked to AIMMS. The new options are always great since they can provide alternatives for our clients to pick the best of the breed for each problem. And as such, this solver can be useful for some problems. More on them here:https://octeract.com/ Next was a cool progress update on our Application Management via API Calls. I see great potential for integrating AIMMS in other solution via API's but also integrating CI/CD with this functionality. Finally, @Gertjan shared numbers on the community edition license which is now 1 year old! Check our celebration post here: Share your thoughts!
Our AIMMS Community License has completed it's first year! 🎉🎊🎈And we are very happy in the reception that this free edition got by our users.Looking back at the original post, I love the proposed intentions for this release. To quote @Gloria Quintanilla :Whether it’s crafting a plan to reduce your personal carbon footprint, creating a schedule for your kids’ school or simply to learn and experiment, AIMMS Community Edition is ideal for those who want to apply modeling to improve decision making. It’s also a great companion for recent graduates who previously used an AIMMS Academic License but want to continue playing with the software at no cost, or showcase their AIMMS skills to prospective employers. So, what did the community edition do for you? Please share with us!And if you still don't have a license, jump right on:https://licensing.cloud.aimms.com/license/community.htm?utm_source=website&utm_medium=footer
Waiting for sub jobs to complete For large jobs, it may make sense to split it into multiple jobs. It may not be convenient, or appropriate, to let the client session organize the communication between the various jobs.This article presents and discusses an example, whereby one control job manages several sub jobs. In addition, results are presented in the client session when all jobs are finished. Read more...
Hi, I was trying to play around with Monte Carlo simulation in AIMMS. I can save the results from MP.Objective for every run. But, how can I save the solution for every run? I tried to use something like below for every run:Variable_Result(run, param1, param2) := Variable(param1,param2);It’s in the procedure “RunMonteCarlo” in the attached file. But, it doesn’t work. Any idea?Thanks,Zulfan
Hi, I’ve been trying to run some Monte Carlo simulations, but apparently if the number of runs is more than 500, the Histogram cannot be made. AIMMS returns some arithmetic error that I don’t understand. How can we increase the number of data that Histogram can make?Thanks,Zulfan
Hello everyone,in contrast to other programming languages, the source code of an AIMMS model usually is in a single file. Our code is hosted at a GitLab instance. Our team notices, that GitLab struggles with the large .ams-file, especially in merge requests. Sometimes the diff is too large to be shown, posting comments (as a reviewer as part of a code review) fails, or loading already posted comments fails. The size of our .ams-file is usually between 1 MB and 5 MB.Has anyone else experienced similar issues? Does anyone know a good alternative to conduct code reviews, which does not involve hosting the code on a different platform?I’m aware that we could use libraries to divide the code in smaller chunks, however, I feel like this is not as easy as in other programming languages and not the way it’s “supposed to be” in AIMMS.Best regardsBenedikt
Hello, I want to save the results of various variables into an Excel Workbook. All the results I want to save are on the “Multiple Iteration Dashboard ” Page I created. I read about the function PageCopyTableToExcel that would allow me to save those results (https://documentation.aimms.com/functionreference/user-interface-related-functions/page-functions/pagecopytabletoexcel.html#pagecopytabletoexcel). You can find my projects attached to this question. To do so, I created a Procedure named “ExportExcel” where you can find the following code : if not axll::WorkBookIsOpen(WorkbookFilename : "Book1.xlsx" ) then axll::OpenWorkBook(WorkbookFilename : "Book1.xlsx" );endif; PageCopyTableToExcel(pageName: "Multiple Iteration Dashboard", tag: "FuelEfficiency", includeHeaders: 1, selectionOnly: 0, ExcelWorkbook: "Book1.xlsx", Range: "A1:Z150"); I went into the Fuel Efficiency Table Properties to correctly tag it as “FuelEfficiency”.However, I got t
Hey Guys,I have a small problem by modeling my MILP.I created a Matrix do define some Binary Variables. Now I want to create a constraint, which contains a multiplication between the Matrix of the Variables an a Matrix with some parameters. The result should be a scalar value comparable to the sumproduct-function in Excel. I want to do a multiplication between the matrices an the result should be a scalar?Hopefully there is a simple function in Aimms to solve my problem.I am thankful for every help!Best regardsSimon
Hello, I want to solve an optimization problem with a minimization of costs. I would like to create a loop that would help me solving the same model but changing only one parameter of my objective function at each iteration. The logic is the following : While (Parameter <= Bound ): Solve Objective_Function(Parameter); Parameter = Parameter + 1; where “Parameter” is the parameter I want to change at each iteration of the loop. where “Bound” is simply a bound to stop my while-loop. where Objective_function is simply the objective function of my problem and depends on the parameter that should change at each iteration. Could you help me? Thank you.
In version 4.71.4, I tried to use the LastUsedColumnNumber, and as the name already gives away it returns a number while I had hoped for a column name in the range of 1 to “ZZZ” like the ones that Excel uses. This would make it easier to also used it in the column/data range definition when reading data.Can anyone advice on how to easily/efficiently translate this?Thanks in advance!
Hi AIMMSians,I have formulated an NLP model with around 2500 variables and it is non-convex. When I solve it using IPOPT, I get the error “Intermediate Infeasible, terminated by solver”. When I use CONOPT as solver, I get same error. Analyzing the listing iteration log files, it reveals that solver labelled the solution as infeasible because the convergence is too slow as demonstrated by message in the end of listing iteration log “Convergence is slow and a derivative is discontinuous”. Please note that sometimes, the same model reached a “local optimal” with sensible values for the variables. With some nice information in AIMMS documentation, forum and webinar, I have tried scaling option, good initial points (which are not possible in every case) and a bit of reformulation by removing some variables acting as intermediate variables between two variables to calculate some values. None of these options have proved any change in the results. Any idea or word is highly appreciated. Thank
Hello, everyone！Now I have a problem about how to set ranges for specific values of a variable. I have a variable “Cmatrix(t,x,conv) ” and “t,x,conv” are some sets. I need that Cmatrix(t,x,conv) ∈ [-1,1] only when conv ≠ 'Heat_pump' . And Cmatrix(t,x,conv) >1 only when conv = 'Heat_pump'. How do I write this in the red box? When I set a constraint to bound the “Cmatrix(t,x,conv) ”, there will be errors as “The solver CONOPT 4.1 cannot handle the ranged constraint Cmatrix_except_HP(1,Elec,CHP_engine) in mathematical program "Cost_minimization"; please define the middle term as a variable and add bounds.” Can some kind person save me? Thank you so so so much! Wish you happy every day.
New internal demo and here I am to share! Remember what I share here is not (necessarily) released yet and can change or even be discarded! I just give the scoop.Connecting the dots is a new functionality in the combination chart that can allow you to “connect the dots” quite literally! So if you have a line chart and have missing data (for some x values), you can still connect the data that is present.Example of connecting dotsAutomatic conversation of classic charts to new combination chart! I really appreciate the effort into building this functionality making life so much easier, but still maintaining the original chart so you'll always be safe in using this. I also enjoyed the improvement to table filtering explicitly separating regex functionality from others. This is already released: https://documentation.aimms.com/webui/table-widget.html#regular-expressions
Hi. Please, I would like to know if it is possible to create a stochastic model from an existing deterministic Non-linear programming problem using AIMMS. I need great help regarding generating scenarios in a multiperiod Optimization problem containing 3 uncertain parameters.Thank you
Last Friday, we had another fantastic demo session.Here are my thoughts and impressions:API Key generations and handling (aka PRO REST API Keys) - this is really cool! As in several API services available, PRO will also have key generation available to interact with the REST server. As always, security comes 1st, so all necessary measures are in place to use this properly and securely. Looking forward to checking all the automation that will be available from this. /
As a follow-up on this first article, a new How-To article is published about the extraction of files and data using the Data Exchange Library (DEX). It shows the difference in using the DEX vs the HTTP library and gives examples on how to read data from both a saved file and from a memory stream.Go to article: How to use the Data Exchange Library for extracting files and dataThe next article in this series will be about using the different data formats. After that, we will go in depth on integrating OAuth using DEX. Let us know if you have suggestions for other follow-up articles!
Hi, I have been following the Employee Training example. However, I cannot run the code (attached). It is said that the solution does not exist. I don’t know what causes it.Furthermore, how do I check and know if the equations are not feasible ya? I’ve been looking into this Math Inspector, but somehow it’s difficult to understand for me. Thanks,
Dear all, Few years ago, I used Aimms to create the file as attached. At that time, CPLEX 12.17.1 package was used to solve the MILP supply chain model. However, when I use newer packages (12.8,12.9,20.1) to run the same file, it gives me very different results. Especially, the “CO2_Capture_Compression_Cost” variable is 0 although it should be 5.6 billion euros as I got. I tried many ways to find why it happens but it doesn’t work. Does anyone can help me in this problem? Thanks a lot for your read and help. P/s: please run “ReadCO2sourcedata”, “ReadProductssinkdata”, and “ReadStoragesinkdata” to get initial data from “CO2dat” excel file before running the program.
Find unused identifiers in your AIMMS project Applications that are around for a while clearly have value to the organization. However, some identifiers such as sets, parameters, variables, and procedures in that application may no longer be used, because: They were created for analyzing and testing a particular circumstance. Once the circumstance is handled, the corresponding identifiers can be removed. As the application evolves, some functionality may become obsolete. There are some disadvantages of having obsolete identifiers in the application: It may confuse your successor, as he/she wonders why an obsolete identifier was added. For a defined parameter or set, it may take up a significant amount of memory and thereby also increase the size of cases. Read more...
I am back with the insider's view of our internal demo sessions for new developments. Let me share impressions: Some interesting developments in the AIMMS Presolver, namely the dual reductions. This new development (which can seek and eliminate unnecessary variables) can significantly improve memory usage during the solve phase. If that is your case, I would definitely take a look at it here. Webui has continued to evolve our combination chart with some very nice looking charts to add on top of the bar chart: line, scatter, area, spline… Very helpful for analyzing data and customizing for end-users. And, on top of that, some added functionality to coloring, based on indexes and with transparency. To me, it looks great! Finally, some additions to our Pro Account Manager. This should facilitate managing accounts in our Pro environments from a programmatic pov. Was this useful ? Do you like any of the above news? Let me know!
If you have two versions of an AIMMS project in which you solve a math program then it can sometimes happen that you get two different solutions (after running) while you expected that both versions would return the same solution. Assuming that you are using the same solver (and version), and the solver does not hit a time limit, this usually means that the math programs generated by AIMMS are different. One approach to find these differences is described below.First create the constraint listings for both project versions by setting the following Solvers General options:'Constraint Listing' to 'At every solve' (or 'At first solve') 'Constraint Listing Variable Values' to 'Print variable values'By setting the second option AIMMS will not only print the level values of all variables in the generated math program, but also their upper and lower bounds.The constraint listing will be printed at the end of the solve (by default) but you can also generate it at the beginning of the solve by
Already have an account? Login
Please use your business or academic e-mail address to register
Login to the community
No account yet? Create an account
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.