Questions tagged [modeling]

Questions about approaches for simulating physical systems or phenomena by building from related understanding and basic principles.

Filter by
Sorted by
Tagged with
5 votes
3 answers
245 views

Plotting Incidence function of the SIR Model

I am working on the SIR model and I am trying to plot the incidence function on a specific time interval. ...
0 votes
0 answers
90 views

Predict with Deep Learning in Mathematica

I have two series of number (Tmax,Tmin) and my target is (ET). I want modeling this and I have one code for this operation but this code is not very acceptable. Can you help me to improve or use an ...
0 votes
0 answers
168 views

Magnetostatics analysis of Switched Reluctance Motor in Mathematica

Accidentally stumbled upon magnetostatic calculation in Mathematica. https://www.wolfram.com/language/12/nonlinear-finite-elements/magnetostatics.html?product=mathematica I would like to ask a ...
2 votes
1 answer
96 views

Need an equation for modeling Tytler's Cycle

In all cultures over all time there appears, in different languages for different countries, the maxim "Shirtsleeves to shirtsleeves in three generations." This is a function with three ...
8 votes
1 answer
393 views

Can LearnDistribution learn conditionality?

I would like to apply LearnDistribution to multivariate conditional distributions. Here's a simple artificial example: ...
8 votes
2 answers
263 views

Alternative Material Models for Finite Element

The Solid Mechanics capabilities of Mathematica make it an interesting alternative to using other software especially when considering multi-physics problems. I would like to collect here (for the ...
1 vote
3 answers
203 views

Finding a continuous distribution that fits the empirical density of dataset $1,1/4,1/9,1/16\ldots$

I have a list of coefs of the form $1,1/4,1/9,1/16,\ldots,1/d^2$ sampled with relative sampling frequencies $1,1/4,1/9,1/16,\ldots,1/d^2$. How do I find a nice continuous density whose CDF closely ...
1 vote
1 answer
114 views

Implementing and testing boundary conditions in polar coordinates for convection-diffusion equation

I am modeling a system using the convection-diffusion equation on a 2D, radially symmetric space. I wanted to do some sanity checks to make sure I am coding it correctly. I set up a situation where I ...
3 votes
2 answers
448 views

Solving Differential Equation System for HIV Treatment Model

I was working on a project about optimal strategies for HIV treatment, models used from [Butler, Kirschner, and Lenhart] 1997. This model explains the spread of HIV viruses in the human body, where ...
0 votes
1 answer
58 views

Nucleation models in Mathematica

Are there any nucleation models available in Mathematica? In particular, I am looking to implement a version of the Kolmogorov-Johnson-Mehl-Avrami model to analyze phase-transition kinetics in one ...
3 votes
0 answers
165 views

FindDistribution analog: automated data modeling with all Wolfram statistical distributions

BOUNTY GOAL To get bounty I am asking to build a function that serves as an analog of FindDistribution. You can also simply re-implement ...
2 votes
1 answer
218 views

Fitting a Lorentzian curve to data

Good morning everyone, regarding my research "high resolution laser spectroscopy" I would like to fit the data obtained from the experiment with a Lorentzian curve using Mathematica, so as ...
5 votes
1 answer
103 views

Spalart-Allmaras turbulence model

In this post Alex gives an implementation of the Spalart-Allmaras turbulence model [1, 2]. The example produces reasonable results, as far as I can tell. However, the implementation Alex uses deviates ...
13 votes
2 answers
815 views

How to Create Kapitza's Pendulum?

Hi, I have never worked on a project of this kind before. I am having difficulty using Kapitza's Pendulum (inverted pendulum with moving vertical base). It is hard for me to make the model equations, ...
7 votes
1 answer
433 views

Numerically solving a system of SDE's with Levy noise?

Consider this system from the following paper titled: The long-time behaviour of a stochastic SIR epidemic model with distributed delay and multidimensional L´evy jumps https://arxiv.org/pdf/2003....
0 votes
1 answer
146 views

Extension of: Numerically solving a system of SDE's with Levy noise?

A great answer by Alex is to be found here for my original question: Numerically solving a system of SDE's with Levy noise? Now Let us perturb this system with time delays so the system is: \begin{...
4 votes
1 answer
367 views

Implementation of FEM to steady-state coupled fluid flow and heat transfer

This is a steady-state conjugate heat transfer problem (the time-independent version of this problem). The problem is conjugate as the energy equation is being solved in thermally connected solid and ...
7 votes
1 answer
284 views

Modelling heat transfer in periodically reversing flow

This is a heat transfer problem, which involves reciprocating (fully-reversing) fluid flow over a heated block of solid. The objective is to determine the temperature field in the solid and the fluid ...
7 votes
1 answer
333 views

Refining mesh size leads to absurd results for a coupled heat transfer FEM model

I have been recently solving a conjugate heat transfer problem, which involves fully-reversing or reciprocating flow of fluid over a heated block of solid. The problem is 2D and the temperature field ...
2 votes
1 answer
140 views

Directly calculating the cyclic steady state of a time-periodic conjugate heat transfer problem

Context The following transient problem is the reciprocating (i.e., fully reversing) flow of a fluid $0<x<L, 0<y<d$ over a thick heated block $0<x<L, -e<y<0$ until the system ...
1 vote
0 answers
73 views

Some conceptual doubts about steady and transient solvers of the NS + energy equations

Recently, I have been solving some transient and steady, flow and heat transfer problems in Mathematica. The transient problem is essentially the reciprocating (i.e., fully reversing) flow of a fluid ...
4 votes
2 answers
101 views

ParametricPlot for phase field error (case: Predator-Prey Model) [closed]

so I have a task that need to draw a phase field of predator-prey model, but first I tried my lecturer's coding: ...
6 votes
4 answers
518 views

Showing that a Hopf bifurcation exists?

I have the following system of ODEs: dx/dt = a/(1 + z) - Q*z dy/dt = Qx - qy dz/dt = qy - cz/(K + z). Assuming K = 1, Q = q < c, and a = c*(Sqrt[c/Q] - 1), is there a way to use Mathematica to test ...
0 votes
0 answers
55 views

Modeling Experimental data with a CDF

I have some data plotted above which relates two variables that were derived experimentally. I'm trying to fit a cumulative distribution function to it so that we can take a sample of Y at X. I've ...
1 vote
1 answer
113 views

Fitting a sum of three lorentzian based on a dataset

as you can see below, I have developed a code that allows me to fit the present dataset via a Lorentzian. Now what I should do is to develop a sum of three Lorentzians based on this model so that this ...
1 vote
0 answers
60 views

How to take a derivative of a function with respect to another function inside the function?

I have these two equations: ...
4 votes
1 answer
577 views

My model has not finished evaluating in more than a day so can't test if it works, what is wrong with it?

Hello I have this modified monocentric city model that I have been working on for a while. Sorry for the long post, I wanted to add the whole code, because it's all connected. My suspicion is that it ...
2 votes
1 answer
218 views

The nonlinear state-space model of a spherical pendulum cannot be linearized and cannot be controlled?

I am attempting to model and control a spherical pendulum. I have derived the equations as follows: ...
2 votes
0 answers
882 views

Solution to heat equation with Neumann boundary conditions and lateral heat loss

I am conducting an experiment on heat conduction in a copper rod. To do so I am using a thin copper rod with several temperature probes, then I am going to compare the data with a solution to the heat ...
8 votes
2 answers
411 views

How to add an attractive potential (migration term) named component to Mass Transport PDE

Wolfram Mathematica 12.2 now features "Named Partial Differential Equation Terms" For specific physics fields, relevant PDE terms have been packaged as components and augmented with ...
11 votes
3 answers
569 views

Mass Transport Model

I've asked similar questions before about Mathematica's Mass Transport model. My aim is to model these systems and show how they change by manipulating various parameters. This time it's the following ...
20 votes
2 answers
890 views

Large deformation of solids

Link to notebook with this question and code I'd like to understand how large deformations of solid mechanics work and how they are implemented. For this am looking at the following reference problem: ...
0 votes
0 answers
205 views

How to plot elements from an array?

Im trying to solve a differential equation for a range of parameters (1->4). I then want to automatically plot a graph for each of those parameters. ...
0 votes
0 answers
1k views

Help with "Coordinate should be a pair of numbers, or a Scaled or Offset form."

I am plotting the pair of recurrence relations: ...
5 votes
1 answer
157 views

Mass Transfer Value

I'm trying to model the following boundary condition using MassTransferValue. $$ D_A \frac{\partial[A]} {\partial x} + D_B \frac{\partial[B]} {\partial x}+ D_C \...
0 votes
0 answers
717 views

Error: "ReplaceAll: ... is neither a list of replacement rules nor a valid dispatch table, and so cannot be used for replacing." when solving a root

I have this code: ...
0 votes
1 answer
201 views

Can Mathematica do thermal/mechanical analysis of modeled solid systems?

I want to do thermal and mechanical analysis of various parts which may have complicated geometries. I am contemplating buying SolidWorks because it does this: you model the part and then use their ...
11 votes
1 answer
307 views

Generating random sequence of integers with ordering constraints

I would like to write a Mathematica routine for generating random musical melodies that obey (some of) the constraints of traditional tonal harmony. For simplicity's sake, I'm interested only in ...
4 votes
0 answers
75 views

Why is EstimatedProcess so slow for a vector ARProcess?

I'm trying to fit some 4 x N data to a vector auto-regressive model. However, EstimatedProcess is very slow for this. For a 4-th order vector AR process, it takes more than 10 seconds (for N approx. ...
2 votes
1 answer
81 views

select the right numbers based on a condition

I want to optimize my stock portfolio based on three components: the price of the different stocks the number to buy of each of the stocks the expected return of each stock (after 12 months) For ...
1 vote
0 answers
88 views

Non linear differential equation plot [closed]

Consider the following paper: https://reader.elsevier.com/reader/sd/pii/S0096300306007715?token=2B98E3B12F1E623C99A0787996469AF36E8EF230F6ED5289EAFB60B64CE79A6ACCF74B946A34F3370C65D4FC99018648&...
4 votes
2 answers
964 views

Is it possible to find the transfer function of these three differential equations using Mathematica

Imagine you are attempting to obtain a model of a device with two inputs [u1, u2] and three outputs [O1, O2, x] from the Lagrangian. After some of Lagrangian work, you find the following three ...
0 votes
1 answer
102 views

NDSolve not finding the right solution for a mass hanging of a thread

My NDSolve isn't predicting the right trajectory for one particular case of a problem. System Consider a mass vertically hanging by an almost inelastic thread. The ...
1 vote
2 answers
93 views

How to model the following system of ODE's in Mathematica with plots of the solution?

Consider the following (i) \begin{align} \frac{d S}{dt} &= -\frac{\beta S I}{N}\\[2ex] \frac{dI}{dt} &= \frac{\beta S I}{N} \end{align} Where $N=S+I$ is the total population. (ii) \begin{align}...
1 vote
1 answer
117 views

Help with plotting the bifurcation diagram $R_0$ vs $I.$ [closed]

I am working on the paper "A short study of an SIR model with inclusion of an alert class, two explicit nonlinear incidence rates and saturated treatment rate" by Kumar, Nilam and Kishor and ...
1 vote
1 answer
699 views

Solving time dependent Schrodinger equation for a wavefunction and harmonic oscillator [closed]

How can I obtain a GIF/graph similar to these ones here by solving the time-dependent Schrodinger equation $$ i\hbar\frac{\partial ψ(x,t)}{\partial t} = -\frac{\hbar^2}{2m}\nabla^2ψ(x,t) + V(x)ψ(x,t)$$...
1 vote
0 answers
117 views

2D transient heat equation resolution

I'm writing a code to get the analytical solution mentioned in Sun et al., 2013. I will copy here the passages needed to solve the equation. The 2D transient heat equation is: First of all, I set the ...
3 votes
0 answers
103 views

Graph embedding constrained to a surface?

Have been contemplating it for a while, but did not dare to post as I felt like this must be a major undertaking to implement. Then saw the excellent answers to a recent question RegionPlot3D KnotData ...
1 vote
0 answers
79 views

Microcontrollerembedcode unable to connect to Arduino Yun

Hi Mathematica enthusiasts, I am trying to follow this tutorial off Wolfram reference for microcontrollers Real Time Data Acquisition I have an Arduino Yun Rev2 hooked up exactly as it is from the ...
0 votes
1 answer
173 views

finding FWHM of a dataset with unknown mathematical equation

I have a dataset. I have plotted using "Listloglinearplot". Now I need to find the FWHM (full width half maxima) of the same, However I dont know which mathematical eqution describes best to ...