Scaling factors

The scaling vector \(s\) contains for each process \(j\) a factor \(s_j\) by which the process needs to be scaled to fulfill the demand of the product system. Mathematically, it can be calculating by solving the following equation by \(s\) where \(A\) is the technology matrix and \(f\) the final demand vector of the system:

$$ A * s = f $$

RESTGET result/{result-id}/scaling-factors
IPCresult/scaling-factors
Python IPCResult.get_scaling_factors
Return typeList[TechFlowValue]

Examples

JSON-RPC via Fetch API

The example below shows the usage of this method using the JSON-RPC protocol via the Fetch API which is available in modern web-browsers or platforms like Deno.

  let resp = await fetch("http://localhost:8080", {
    method: "POST",
    body: JSON.stringify({
      jsonrpc: "2.0",
      id: 1,
      method: "result/scaling-factors",
      params: {
        "@id": "fa78990c-3f88-455a-9f8f-bd9e536bac28",
      }
    })
  });
  let v = await resp.json();
  console.log(v);
  // {
  //   jsonrpc: "2.0",
  //   result: [
  //     {
  //       techFlow: { provider: [Object], flow: [Object] },
  //       amount: 0.0016129032258064518
  //     },
  //     { techFlow: ...
})();