24 questions
0
votes
0
answers
43
views
Monte Carlo Euler discretization for a 3-factor financial option pricing model yields price bias
I'm trying to replicate results from a published paper that prices call options under a three-factor stochastic model. The option price depends on stochastic volatility, a domestic short rate, and a ...
-1
votes
1
answer
62
views
Find the minimum number of connected subgraph that covers the whole digraph
I have a large directed graph, and I try to access every edge for this digraph. The problem is to minimize the number of the access (a connected subgraph is counted as one access). And it reduces to ...
0
votes
5
answers
125
views
Reordering a list of tuples to match the value of the next element in the list
If I have a list of tuples like this [(1, 3), (-6, 3), (1, 7)] and i would like to return a list like this [(7, 1),(1, 3), (3, -6)]. What can I do?, any ideas on how to sort the tuples. The essential ...
-2
votes
1
answer
170
views
Suggestions needed for improving eulerian path algorithm for CSES Mail Delivery problem
I am getting time limit exceeded for my solution for CSES Mail Delivery for some test cases.
Your task is to deliver mail to the inhabitants of a city. For this reason, you want to find a route whose ...
0
votes
0
answers
29
views
Incorrect output for covering all graph edges
I need to cover all the edges of a graph with the minimum number of paths. I read that the Eulerian path method is needed here. I tried to reproduce it, but it doesn't work correctly.
def split_graph(...
2
votes
1
answer
236
views
Route Inspection of Directed Graph in ASP
For the multidirected graph below I am trying to write an program that visits all edges at least once. For instance, in the below graph I am looking for an outcome similar to "edge(1,2), edge(2,3)...
0
votes
2
answers
284
views
i made Eulerian path algorithm(Euler-path). what's the problem?
I made an Eulerian path algorithm, what's the problem?
#include <cstdio>
#include <vector>
#include <iostream>
#include <list>
using namespace std;
int graph[1000][1000]; // 1&...
0
votes
1
answer
679
views
differentiating the SEIR model in Java
I'm attempting to make a simulation of the SEIR epidemic model.
It contains four parts:
Susceptibles (non-infected)
Exposed (infected but not infectious yet)
Infectious (infected and infectious)
...
0
votes
0
answers
472
views
Find minimal cost of eulerian path,which is contain given edges in undirected graph(Algorithm)
How to find in undirected, weighted graph the minimal eulerian path?(This path must contain the given edges)
The weight of the edges is the sum of the 2 points(exmpl:edge 4-9 weight=4+9=13) for all ...
3
votes
2
answers
762
views
Is there a counter-example for this algorithm finding the Euler Path in a Eulerian Graph?
The following is the given algorithm for finding a Euler Path in a Eulerian Graph. However, it is said that there is an counter example with less than 10 vertices. The given Eulerian Graph is ...
0
votes
3
answers
7k
views
Directed Graph: Euler Path
Based on standard defination, Eulerian Path is a path in graph that visits every edge exactly once.
Now, I am trying to find a Euler path in a directed Graph. I know the algorithm for Euler circuit. ...
0
votes
1
answer
579
views
Prolog grade counter and eulerpath
this week I got this homework to do: count the grade of nodes in a undirected graph and test if there is a euler path in it. the function should work like following:
gradliste([[a,b],[b,c],[b,g],[c,d]...