Not long ago to do arithmetic modelling of the operation, to use the lingoAnd still have to re-provision the dynamic plan using lingoSo on Baidu found under how to use C + + deployment of lingo, the final result found to be a pitSo I got stuck in it and got two or three cows to figure out that there was a day in the house that didn't sleep ... To bucketHowever, it is clear, but also took a lot of detours, so to write down a little experience, summed u
We sometimes encounter heavy, repetitive work when using lingo, manual operation is obviously time consuming, and the @for function in lingo can only do some simple loops, which requires us to apply the script file to simplify these repetitive work. The English part below is an example from the Official Handbook, which summarizes the 2 points I find useful:1. script file type:. LTF However, the script file
The first step: Enter the target condition and the constraint condition. Each line is separated by semicolons. Then click the Solve button on the toolbar or the Solve submenu under the Lingo menu.Step Two: Check the results in the report.By default, lingo does not perform sensitivity analysis.Need to be configured in lingo to generate a sensitivity analysis repor
Assign values using verbose syntax
The logical operators in lingo use the single equal sign "= ".
Set Param To Value
Put Value Into Param
Verbose syntax to assign values more clearly.
Case-insensitive
Because case-insensitive is case-insensitive, note the comparison of strings.
Put"A" = ""
-- 1
Case-sensitive
Lingo is not sensitive in most cases. Only one case is that the propert
: x (K, J) = 1 ;);! Ensure that no circles exist. @ for (city (I) | I # gt #1: @ for (city (J) | J # gt #1 # and # I # ne # j: u (I)-u (J) + n * x (I, J)
3. maximum short circuit problem
Given N point Pi to form a set {Pi}, the distance from any point Pi in the set to another point Pj is represented by Cij. if Pi to Pj is not connected by ARC, cij = positive infinity, Cii = 0, specify an endpoint PN, and the shortest route from Pi to PN is required. Here we use dynamic planning.
And
The code solved with lingo is as follows:
Model! With lingo to solve the problem of salary distribution, five people each have a different job;Sets:var/1..5/;Link (var,var): c,x;EndsetsDataC= 3 8 2 10 38 7 2) 9 76 4 2) 7 48 4 2) 3 59 10 6 9 10;Enddatamin= @sum (link:c*x);@for (Var (i):@sum (Var (j): X (I,J)) =1);@for (Var (j):@sum (Var (i): x (I,J)) =1);@for (Link: @bin (x));!x11,x12,.., x15,x21,x22,.., x25
Model: sets: Jing/1 .. 20/; out/1 .. 13/; jingout (Jing, out): DAT; Result (Jing, out): X; themin (Jing, out); endsetsdata: DAT = (20*13 data ); enddata @ for (result (I, j): @ Bin (x (I, j )));! Only 0 and 1 @ for (Jing (I): @ sum (result (I, j): X (I, j) = 1) for all elements );! Each patrol point must be assigned a location; @ for (Out (j): @ sum (result (I, j): X (I, j)> = 1 );! Patrol points> = 1 for all exits; @ for (Out (j): @ sum (result (I, j): X (I, j ))
The code solved with lingo is as follows:
Model! The steady-state probability distribution of the transfer matrix is obtained.Sets:PROD/1..3/:P;Link (prod,prod): T;EndsetsData:! Transfer matrix;t= 0.368 0 0.6320.368 0.368 0.2640.184 0.368 0.448;Enddata@for (Prod (i):! Remove a redundant constraint;P (i) = @sum (link (j,i):P (j) *t (J,i));@sum (prod:p) = 1;@for (Prod (i):@warn (' The sum of each line of the input matrix must be 1 ',@abs (1-@sum (link
Id = getnettext ("http://www.baidu.com /")
-- Getnetbytearray ("http://www.baidu.com ") Put getstreamstatus (ID) Put nettextresult (ID)
-_-
--------------------------------------------------------------------------------
Netlingo
--------------------------------------------------------------------------------
It is used to access the network and obtain the text stream or media stream of the webpage. It can also be used to check whether the Network is available.
--
with the customer,
After the seal is signed, fax will be sent back to the customer.
Before sending an instruction to the warehouse and the slitting factory, the type and quantity of required materials were calculated using a fixed formula with a proportional coefficient. for example, if the width of all products required by the customer is
If the value is 99, multiply the order by a proportional coefficient greater than 1, or call it magic number. The universal proportional coefficient, such a
Naive Bayesian classification has a restrictive condition, that is, feature attributes must be
conditional independent or basic independent (in fact, in practical applications almost impossible to complete independence)
A Bayesian network definition consists of a
direction-free graph (DAG) and a set of
conditional probability tables . Each node in the DAG represents a
random variable, which can be directly observed or hidden, while a directed edge represents a
conditional dependency between
With the gradual application of smart optical network ASON, the transmission network will gradually increase the number of intelligent network elements. As operators have invested heavily in the traditional SDH network, in order to protect the original investment and realize the smooth evolution of the traditional optical transmission network to ASON, the intelligent network and traditional devices will coexist for a long time, the interoperability between the two is inevitable. Therefore, the i
OpenStack's neutron defines two main types of network--tenant networks and provider networks. OpenStack administrators must decide how their neutron network deployment strategy will use--tenant networks, provider networks, or some combination of both.This section describes the unique challenges posed by the tenant netw
In the past, people used Wireless Office as a fashion, such as chatting online in the cafe and posing with a wireless laptop in the airport lobby. Today, wireless applications have begun to penetrate into a variety of enterprise applications. In some enterprise applications, wireless applications have even become a tool to replace wired networks.
Some enterprises, especially large sales enterprises, do not have fixed office positions, for example, a s
Previous 4ArticleThis is a fuzzy system, which is different from the traditional value logic. The theoretical basis is fuzzy mathematics, so some friends are confused. If you are interested, please refer to relevant books, I recommend the "fuzzy mathematics tutorial", the National Defense Industry Press, which is very comprehensive and cheap (I bought 7 yuan ). Introduction to Artificial Neural Networks
Artificial Neural Network (ANN) is a mathematic
This paper summarizes some contents from the 1th chapter of Neural Networks and deep learning. Catalogue
Perceptual device
S-type neurons
The architecture of the neural network
Using neural networks to recognize handwritten numbers
Towards Deep learning
Perceptron (perceptrons)1. FundamentalsPerceptron is an artificial neuron.A perceptron accepts several binary inputs: X1,X2, .
Over the past few days, I have read some peripheral materials around the paper a neural probability language model, such as Neural Networks and gradient descent algorithms. Then I have extended my understanding of linear algebra, probability theory, and derivation. In general, I learned a lot. Below are some notes.
I,Neural Network
I have heard of neural networks countless times before, but I have never stu
Instructor Ge yiming's "self-built neural network writing" e-book was launched in Baidu reading.
Home page:Http://t.cn/RPjZvzs.
Self-built neural networks are intended for smart device enthusiasts, computer science enthusiasts, geeks, programmers, AI enthusiasts, and IOT practitioners, it is the first and only Neural Network book created using Java on the market.
The self-built neural network is simple and interesting. It is a popular book for neural
is the number of nodes related to the classification, assuming that we are set to 10 classes, the output layer is 10 nodes, the corresponding expectations of the setting in the multilayer neural network has been introduced, each output node and the above hidden layer 100 nodes connected, total (100+1) *10=1010 link line, 1010 weights.As can be seen from the above, the core of convolutional neural networks is the creation of convolutional layers, so w
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.