# data[].attributes.headline
Interactive presentation at the MATh.en.JEANS Congress (Nice) 6 April 2023

# data[].attributes.subject
Interactive presentation at the MATh.en.JEANS Congress (Nice) 6 April 2023

# data[].attributes.headline
Write down the ideas and progress of yourgroup on your topic

# data[].attributes.subject
Write down the ideas and progress of yourgroup on your topic

# data[].attributes.body
My name is Gabriela Urian, you can call me Gabi! I'm 17 and I study at "Emil Racovita" National College in Cluj. I'm really passionate about biology and liberal arts and I'm looking forward to seeing this project unwrap itself:)

# data[].attributes.body
We thought creating a C++ project for said simulation of the parasites' and hosts' evolution would be a good starting point!
Here is the program:
#include<iostream>

#include<stdlib.h>

#include<time.h>

using namespace std;

int H, P;

//no hosts, no parasites

int b, d, dp, e;

//birth rate hosts, death rate hosts, death rate parasites, no eggs per host

int eggs;

//eggs currently waiting to hatch

int probability;

//probability parasite and host meet

int t;

//number of time units to be executed

int k;

//randomized number

int main()

{

cin>>H>>P>>b>>d>>dp>>e>>t;

srand(time(NULL));

for(int a=1;a<=100;a++)

{

k=rand();

}

for(int i=1;i<=t;i++)

{

probability=k*H*P;

eggs=probability*e;

H=H+(b*H)-(d*H)-probability;

P=P-(dp*P)+eggs;

cout<<"\n"<<H<<" "<<P<<"\n";

}

}

k is a randomized number between 1 and 100 meant to randomize the probability of hosts and parasites meeting while keeping it proportional to the populations' number(probability=k*H*P).
I've met some difficulty with my laptop(it literally refuses to run my programs lately) and I haven't found a good online compiler so suggestions would be appreciated!!

We have calculated the populations' evolution for a few chosen variables and tye results have been....incomprehensible and unrealistic so we gotta figure that out.

# data[].attributes.body
We've got news, I'm an idiot and I figured why the hosts' population always decreased dramatically. I changed the probability from probability=H*P*k to probability=(H*P)/k. k is a percentage but we do not need the 1/100 for the rest of the problem besides calculating the probability so I figured I could move it under a fraction.
Also the number of eggs was changed from eggs=probability*e to eggs=(probability*e)/H cause it is directly corralted to the number of hosts(there can't be more eggs than e*H, and probability*e almost always surpassed that number in our simulations).

# data[].attributes.body
Hi! My name is Carmen Moldovan and I'm a student at "Emil Racovita" National College in 10th grade. I am 15, almost 16 and I'm looking forward to creating this project with my colleagues, Tudor and Rebeca. I am a friendly and talkative person and I am passionate about English and geography. I can't wait to see your approach to this project and improve my mathematical and English skills while learning more about our research topic.😋

# data[].attributes.body
Hi!
My name is Fiona Caillau, I'm 14, almost 15. I am from Ivory Coast but I'm a 10th grade student at "Bellevue Marie Rivier" in Alès. I'm in a group of 4 people, Thibaut, Arnaud and Claire, and we're  looking forward to find a solution to the problem n°9.🤗

# data[].attributes.body
Hello !
My name is PELLET Thibaut, I am 15, I am in 11th grade and I am coming from the high school «Bellevue Marie Rivier» from Alès from Gard from Occitanie from France from the space Shengen from European Union from Europe from Earth from milky way from the universe.
In my group i am with Fiona Caillau, Arnaud Fosset, Claire Gauthier and me.
I hope we will work well together on the subject 9 ! 👍

# data[].attributes.body
My name is Rebeca Sturz. I'm 16 and also a student at "Emil Racovita" National College. I'm really curious to know how you thought about solving this problem!! :)

# data[].attributes.body
Our team had a more analytical approach. Since eggs will soon become parasites, we neglected the hatching period, and considered the eggs as new parasites. This led us to the following non-linear coupled system of differential equations, where h - current number of hosts, p - current number of parasites, alpha = b - d, beta = k, gamma = dp, delta= k * average no. of eggs/host.
Team Matei-Codrin

# data[].attributes.body
Hello, my name is Codrin Berinde, I am a 12th grade student at Colegiul National  "Emil Racovita", Cluj-Napoca, Romania. I enjoy working on projects related to exact sciences, and me and my team colleague are eager to work with you to find the best results to research topic 9.

# data[].attributes.body
Hello everyone, my name is Munteanu Matei, I am 17 years old and I am in 11th grade at Colegiul National "Emil Racovita", in Cluj-Napoca Romania. I'm looking forward to meeting you and working on the research project together.

# data[].attributes.body
Here is the code we wrote in order to visualize the behavior of the populations of hosts and parasites, respectively. It generates both an output file "output.txt" with the two populations in time, and another file, "latex.txt", containing LaTeX commands that generate a graph.

We used the mathematical method of discretization: we turned the continuous functions into sequences. Although this method is not that precise (as you will see later) it offers a good perspective of the evolution of the two species.

The program reads from "input.txt" the following float numbers:
h0, p0 - the initial populations
alpha, beta, gamma, delta

It runs through 3000 iterations.
Team Matei-Codrin

# data[].attributes.attachment_link.readable_text
f = open('input.txt', 'r')
g = open('output.txt', 'w')
lx = open('latex.txt', 'w')
h = float(f.readline())
p = float(f.readline())
alpha = float(f.readline())
beta = float(f.readline())
gamma = float(f.readline())
delta = float(f.readline())

vmax = max(h, p)
xmax = 1

hp = [0, 0]*3001
hp[0] = [h, p]

for i in range(1, 3000):
    hnew = h * (1 + alpha - (beta * p))
    pnew = p * (1 - gamma + (delta * h))
    if(hnew > 1000000000 or pnew > 1000000000):
        g.write('Value exceeding upper limit\n')
        break
    if(hnew <= 0):
        g.write('Hosts population died\n')
        break
    if(pnew <= 0):
        g.write('Parasite population died\n')
        break
    h = hnew
    p = pnew
    hp[i] = [h, p]
    if h > vmax:
        vmax = h
    if p > vmax:
        vmax = p
    g.write(str(h) + ', ' + str(p) + '\n')

    xmax = i


g.close()
f.close()

# variabile latex
H = 6.0  # inaltime grafic in centimetri
W = 13.0  # latime grafic in centimetri
ry = H/vmax  # ratia prin care vom calcula abscisa fecarui punct
rx = W/xmax  # ratia prin care vom calcula ordonata fiecarui punct


def latex():
    lx.write('\\draw[thick, blue] (0,' + str(round(hp[0][0] * ry, 5)) + ') ')
    for i in range(1, xmax):
        lx.write(' -- (' + str(round(i * rx, 5)) + ',' +
                 str(round(hp[i][0] * ry, 5)) + ') ')
    lx.write(';\n')

    lx.write('\\draw[thick, red] (0,' + str(round(hp[0][1] * ry, 5)) + ') ')
    for i in range(1, xmax):
        lx.write(' -- (' + str(round(i * rx, 5)) + ',' +
                 str(round(hp[i][1] * ry, 5)) + ') ')
    lx.write(';\n')


# raporteaza
print('Maximum value is ' + str(vmax))
print('The population lived ' + str(xmax) + ' days')

latex()

# data[].attributes.body
Here is an example of a graph generated by our code, for the sample values of:
h0 = 7.5
p0 = 3
alpha = 0.002
beta = 0.0004
gamma = 0.006
delta = 0.0008

Team Matei-Codrin

# data[].attributes.body
We changed the way k, d, b, and dp are generated!
#include<iostream>

using namespace std;

int H, P;

//no hosts, no parasites

int b, d, dp;

//birth rate hosts, death rate hosts, death rate parasites; they must be between 0 and 1

int e;

//no eggs per host

int eggs;

//eggs currently waiting to hatch

int probability;

//probability parasite and host meet

int t;

//number of time units to be executed

int k;

//random number between 0 and 1

int main()

{

cin>>H>>P>>b>>d>>dp>>e>>t>>k;

for(int i=1 ; i<=t ; i++)

{

probability=k*H*P;

eggs=probability*e;

H=H+(b*H)-(d*H)-probability;

P=P-(dp*P)+eggs;

cout<<"\n"<<H<<" "<<P<<"\n";
if(P==0 || H==0)
{
cout<<"Population reached 0";
return 0;

}

}

}

# data[].attributes.attachment_caption
Vector field for set parameters: alpha = 0.02, beta = 0.004, gamma = 0.06, delta = 0.008

# data[].attributes.body
Instead of representing two graphs (hosts against time and parasites against time), you can represent hosts against parasites on the same graph (denoted as x and y, respectively). Therefore, each point of the graph corresponds to two particular population sizes (h, p) and for each point the derivative of each population can be calculated from the differential system and represented as a vector: showing us in what direction the two populations will evolve in time. The vector's modulus shows how fast this change will happen. This graph is called vector field.

You can see for example, on the y axis, that parasites without hosts quickly drop to zero, while on the x axis, hosts without parasites grow exponentially.

Team Matei-Codrin

# data[].attributes.body
There are, however, points on the vector field where the vector is zero. Those are the points where both populations will remain constant in time, hence both derivatives (measures of change) equal zero. We can obtain the coordinates of those points by setting the two derivatives zero in our system and solving the new system, which give us two points: (0, 0) and (gamma/delta, alpha/beta).

The interesting point to study is the second one, since (0, 0) is obviously stationary: with no populations there can't be any change.

Team Matei-Codrin

# data[].attributes.body
Another interesting thing to do is representing the graphs obtained by discretization right on the vector field. We obtain a beautiful spiral around the stationary point.

Team Matei-Codrin

# data[].attributes.body
The code that we wrote in order to obtain the vector fields (the code generates LaTeX commands)

Team Matei-Codrin

# data[].attributes.attachment_link.readable_text
#acest program deseneaza campul de vectori corespunzator
#valorilor a, b, c, d din fisierul 'valori' precum si limitele
#pentru axele x respectiv y citite dupa aceea, dar si factorul de divizie dv
#care spune cu cat se imparte modulul unui vector ca totusi pe figura sa fie vizibil
#(altfel este fie foarte mic, fie foarte mare)

#parametrii corespund sistemului de ecuatii diferentiale cuplate nelineare
# h' = h (a - bp)
# p' = p (-c + dh)

#programul va desena 20 de valori pentru fiecare axa, din 'pas' in 'pas'

f = open('inputPajiste.txt', 'r')
lx = open('latexPajiste.txt', 'w')

a = float(f.readline())
b = float(f.readline())
c = float(f.readline())
d = float(f.readline())
xmax = float(f.readline())
ymax = float(f.readline())
dv = float(f.readline())

yfix = a/b
xfix = c/d

lx.write('\draw[->] (0,0) -- (' + str(xmax) + ',0) node[below] {$h$};\n\draw[->] (0,0) -- (0,' + str(ymax) + ') node[left] {$p$};\n')

def desenareSageata(xi, yi, xf, yf):
    lx.write('\\draw[ultra thick, red, ->] (' + str(xi) + ', ' + str(yi) + ') -- (' + str(xf) + ', ' + str(yf) + ');\n')

def sageata(x, y):
    dirx = x * (a - b * y) / dv
    diry = y * (-c + d * x) / dv
    desenareSageata(x, y, x + dirx, y + diry)

pasx = xmax/20
pasy = ymax/20

xcrt = 0.0
ycrt = 0.0

while xcrt < xmax:
    while ycrt < ymax:
        sageata(xcrt, ycrt)
        ycrt += pasy
        print(xcrt, ' ', ycrt)
    xcrt += pasx
    ycrt = 0.0

if xfix <= xmax and yfix <= ymax:
    lx.write('\\fill (' + str(xfix) + ',' + str(yfix) + ') node[below] {PUNCT FIX (' + str(xfix) + ', ' + str(yfix) + ')} circle (0.1cm);\n')

# data[].attributes.body
The code that draws the spiral above the vector field.

Team Matei-Codrin

# data[].attributes.attachment_link.readable_text
#acest program deseneaza DEASUPRA campului vectorial traiectoria pentru o pereche de valori initiale,
#citite din fisierul inputSpirala.txt. Va mai citi apoi si a, b, c, d, xmax, ymax.
#El va scrie totusi in latex2.txt

f = open('inputSpirala.txt', 'r')
lx = open('latex2.txt', 'w')
h = float(f.readline())
p = float(f.readline())
alpha = float(f.readline())
beta = float(f.readline())
gamma = float(f.readline())
delta = float(f.readline())
xmax = float(f.readline())
ymax = float(f.readline())

tmax = 1

hp = [0, 0]*3001
hp[0] = [h, p]

for i in range(1, 3000):
    #print('calculam h, p pentru ', h, ' ', p)
    hnew = h * (1 + alpha - (beta * p))
    pnew = p * (1 - gamma + (delta * h))
    #print('si da ', hnew, ', ', pnew)
    if(hnew > xmax or pnew > ymax):
        break
    if(hnew <= 0):
        break
    if(pnew <= 0):
        break
    h = hnew
    p = pnew
    hp[i] = [h, p]
    tmax = i

f.close()


def latex():
    lx.write('\\draw[thick, blue] (' + str(hp[0][0]) + ',' + str(hp[0][1]) + ') ')
    for t in range(1, tmax):
        lx.write(' -- (' + str(hp[t][0]) + ',' + str(hp[t][1]) + ') ')
    lx.write(';\n')


# raporteaza
print('Populatia a trait ' + str(xmax) + ' zile')

latex()

# data[].attributes.body
As we started to work on the problem, we decided to do the experiment ourselves. We went to the USAMV (a university here in Cluj) lab and we worked on three hosts and 310 parasites. The parasite we used is called Strongylus equinus and the experiment lasted for  10 days. In 3 days, 122 eggs died and 188 remained. In the next week, another 30 died and 158 eggs hatched.  While working on the experiment, we found various data about parasites and their hosts, and we discovered that once the host is infected with a parasite, it will show clinical symptoms in around 8-9 months. However, most of the hosts don’t die after being infected with the parasite.
-Moldovan Carmen
Team Sturz Rebeca, Moldovan Carmen, Cainap Tudor

# data[].attributes.body
Hello, my name is Tudor Cainap, I am a 10th grade student at Colegiul National "Emil racovita". I am 16 and looking forward to finding a great solution to this problem together with my colleagues Carmen and Rebeca. I'm thrilled by the idea of being able to see what you guys have come up with to this problem whilst also improving my english skills!

# data[].attributes.body
The formula ended up with is:
P(t)=k•(e^-dp•t+c)
P(t) is the parasite population at time t
k=1000 (constant)
e^-dp= 0.8
dp=-ln(0.8)
c=variable
dp=parasite death rate
But before we discovered the final formula, we had several other attempts at equations and equalities that eventually led us to the desired result.
dp=P(t+1)-P(t)
P(t+1)=P(1)+t*c (eg P(100)=P(1)+99c
c is a variable whose values ​​may differ depending on the problem data. From the two formulas above I extracted that dp=t*c, but I needed more to advance.
We also arrived at the formula P(t+1)=P(t)+(br-dp)-t*c, but we don't think it's very correct, so we didn't dwell on it too much.
Initially, the final formula looked like this: P(t)=e^(-dp*t)+c, k being equal to 1. However, this messed up our calculations a bit, so we gave k the value 1000. The new attribution of k helped both the formula and the representation of the function.
-Sturz Rebeca
Team Moldovan Carmen, Cainap Tudor, Sturz Rebeca

# data[].attributes.body
//  Sistems of differential equations that describe the growth over time of a
//  (host - H)(parasite - P)
//  dH/dt = bH - H * P
//  dP/dt = H * P - dp

#include <iostream>
using namespace std;
double dHdt(double H, double P, double b);
double dPdt(double H, double P, double dp);
int main(int argc, const char * argv[]) {
double H = 100;
double P = 10;
double b = 0.1;
double dp = 0.05;
double dt = 0.1; // delta t - interval of time

for (int  t = 0; t < 10; t++)
{
H += dt * dHdt(H, P, b);
P += dt * dPdt(H, P, dp);

cout << "Time: " << t << " Hosts: " << H << " Parasites: " << P << endl;
}

return 0;
}

double dHdt(double H, double P, double b)
{

return b * H - H * P;
}

double dPdt(double H, double P, double dp)
{
return H * P - dp;
}
Team Moldovan Carmen, Sturz Rebeca, Cainap Tudor

# data[].attributes.headline
Video conference on Wednesday, January 25, 2023 from 1:00 to 3:00 pm (French time)

# data[].attributes.subject
Video conference on Wednesday, January 25, 2023 from 1:00 to 3:00 pm (French time)

# data[].attributes.body
Prepare a short slide show on your results and current research.

# data[].attributes.body
im posting this message here to make sure you see it :))
im the only student from cluj (with this subject) coming to France and i was wondering how many of you will be participating to the congress and if you have already started the presentation work...?
rebeca sturz

***this is my personal email adress, if you want to text me so we can work together rebecast0211@gmail.com

# data[].attributes.headline
Documents for the common presentation at the Nice Congress

# data[].attributes.subject
Documents for the common presentation at the Nice Congress

# data[].attributes.headline
Scientific presentation at the MATh.en.JEANS Congress (Nice) 6 April 2023

# data[].attributes.subject
Scientific presentation at the MATh.en.JEANS Congress (Nice) 6 April 2023

# data[].attributes.headline
Interactive presentation @MATh.en.JEANS Congress - 6 April 2023

# data[].attributes.subject
Interactive presentation @MATh.en.JEANS Congress - 6 April 2023

# data[].attributes.body
Presentation at the Nice congress