# All Questions

170 views

### What is the equivalent of FORTRAN 77 COMMON BLOCK in Mathematica?

I am in the process of converting a FORTRAN 77 program to Wolfram Language. I have several COMMON BLOCK statements in FORTRAN 77. My question is how to deal with them in Wolfram Language? My ...
68 views

### How to count the actual occurence of a warning message in a Do loop?

I am running a lot of simulations to fit a model to randomly generated data. Sometimes the fitting converges properly sometimes it does not, but it will give you the fitting parameters anyway. I would ...
681 views

### Is it possible to reference “self” from a pure function?

This would calculate the factorial of 6, if the "self" was the function itself. Is there something that could allow this? ...
36 views

### Application of lowpass Butterworth filter

I'm trying to design a Butterworth lowpass filter with a cutoff frequency of So far what I did is ...
130 views

### How to implement Bresenham’s algorithm as a system of equations?

Bresenham's line drawing algorithm is usually implemented via loops. But in Mathematica we can take advantage of its ability to solve Diophantine equations. From educational viewpoint it is quite ...
57 views

### Mathematica nested loops [on hold]

I can write down the following Python code: for j1 > 2: time1 = i1 for i2 > i1: if j2 < 2: time2 = i2 break Purpose of the above code: ...
73 views

### Switch x and y axis data in Mathematica? [on hold]

I have data in the following format: {{1, 100}, {2, 200}}. When I try to plot it with following code: ...
48 views

### Defining function from table [on hold]

I have a table of values of the form Table[{i1,j1}, {i2,j2}...] and I want to define a function like f[i] to take the values ...
256 views

### Computing the first derivative in x, y ,and z

I have the following function: f:=x^3+yz+z^2x; I need to compute the first derivative in x, ...
59 views

### Determining the order of continuity (smoothness) of a function

Is there any method to determine the order of continuity of a function (just like an interpolant) over a given domain, or at least determine the continuity on a given order? For example, according to ...
87 views

### MapAt with Replace(All) causing kernel crash

Bug introduced in 10.1 and fixed in 10.2 I wanted to roll a function that works like /. but only acts on the very first match it encounters. ...
43 views

### Computation (or estimation) of an trigonometric Integral with a parameter

I am trying to calculate the following integral which contains a parameter. I have used the Integrate and FullSimplify using assumptions but Mathematica fails to produce an analytical solution. ...
475 views

### How to extract points from a closed curve

OK, let's create a simple closed curve C0 = ContourPlot[x^2/4 + y^2/9 == 1, {x, -5, 5}, {y, -5, 5}]; and let's plot the corresponding points ...
43 views

### Numerically solve recurrence equation

I have the following recurrence equation ...
34 views

### How can I construct a string pattern from a list of patterns? [duplicate]

Is it possible to construct a string pattern from a list of strings? ...
66 views

### How can I solve implicit function with mathematica?

I wish to solve the Implicit function given below ...
36 views

### How to draw bifurcation diagram for fractional-order Lorenz system? [on hold]

Please provide help to write the program for bifurcation of fractional-order Lorenz system. By using adams-baseforth predictor-corrector method.
215 views

### Reversing components in a list

Suppose I have the following list: Tl={{a, 3, b}, {c, 6, d}, {e, 9, f}, {g, 5, h}} I really want to reverse specific elements of this list such that I get the ...
64 views

### How to find the number of nodes in finite element model

I am using Mathematica version 10 to solve a 2-D elliptic equation by the finite element method. I created a finite element model with a very fine mesh. Would you please suggest me a command to show ...
40 views

### Estimating Power Spectral Density from Autocorrelation

I have been tasked with computing the power spectrum of a noisy signal. Specifically, I am asked to do so through first attaining the autocorrelation function. From what I have read, the PSD is simply ...
42 views

### How do I animate just one variable out of three inside Manipulate/Not show line until Animate?

1) In the following code, I want to Animate just the Elapsed Time (t) variable. How do I write an ...
49 views

### Integration result with incomplete beta function

I'm doing some calculations (double integration) which results in the incomplete beta function occurring as an end result. My input is: ...
108 views

### Plotting the exponential of 1/(y-x)

What is the best way to handle this situation? ...
34 views

### Genarating Random Move right left up down

Suppose that we have a 4 faces die. The person toss the die and if it land on: 1) the person will move to the right 2) the persone will move to the left 3) the person will move upward 4) the person ...
39 views

### Region from Points

Is there a built-in way to define a 3D region from an arbitrary list of points. The points will represent vertices of the edges of the region and we can assume that 1) they are not all on the same ...
44 views

### NSolve not working [on hold]

I'm sorry if this is a dumb question, but for some reason NSolve isn't working for me. Here's what I'm trying to do. ...
67 views

### Multiple interactive adjusters for multiple parameters including locator

I want to make a program that allows to vary multiple parameters via multiple adjusters. It may well be that this question has been answered already somewhere. However, I am pretty new to programming ...
31 views

### Can't Nintegrate my NDsolve results

I want to NIntegrate my NDsolve result. I don't have a exact function form because it is coming from the NDsolve result. It looks like Integrate only permit numerical forms. The function y1[t] could ...
169 views

### Solve didn't give the right solution

I've got a pretty simple equation set here but I cannot seem to solve it correctly. ...
41 views

### N function not returning numerical value [on hold]

I have (what would seem to be) a very simple problem that is causing me a lot of frustration. I have written a module that performs a fairly straightforward NIntegrate of a certain function. Some ...
58 views

### Plotting Solution Curves in a Vector Field

I am having trouble trying to plot solution curves onto a vector field for this certain ODE. I have tried plotting with multiple different initial conditions/ different constants however I keep ...
39 views

### Problem in DSolve solving [on hold]

I want to solve matric form diffrential equation in Mathematica. matric M,T,S are defined before DSolve and the code is given below but Matematica don't solve this equation. Please help me. ...
33 views

### Does Compilation option “InlineExternalDefinitions”/“InlineCompiledFunctions” lead to unnecessarily complicated nesting?

Question: When an external (possibly complicated) definition f is used inside a compiled function with ...
27 views

### MathLink Excel version 3.5 & 3.6 inconsistency

I bought and installed Mathematica Link for Excel 3.6.0. However, after installation, it appears inside Excel as Version 3.5.0. Has anyone seen this issue? I have emailed Wolfram support but have ...
27 views

### MathLink error msg: Libraries are not installed or outdated

I installed Mathematica 10.2.0.0, Excel 2013 32-bit, and MLink for Excel 3.6.0. In Excel, I added Mathematica Link in Add-Ins, and included the C:\ProgramData\Mathematica\ folder as a Trusted ...
89 views

### How to get a new list by exchanging some elements?

Let's begin with a simple example. Now, we have a list, list0=Range[4]; k1 and k2 are some elements of the list0. If |k1-k2|==2, then the elements k1 and k2 can ...
77 views

### Import Data different column length

Lets assume, i have this data.txt file. s1/km t1/h s2/km t2/h 20 1 40 1 40 2 80 2 60 3 I define myself a function ...
406 views

### Convert binary voxel image to geometric region

I have a binary voxel image which described a contiguous region in space. Example: ...
54 views

### Converting imported data into a list of pairs [on hold]

I have data imported like this: ...
34 views

### How to enable automatic “grammar check” for MMA? [duplicate]

The special evaluation mechanism of MMA might make it more likely for MMA users (especially new users) to make mistakes and more difficult to find them. For example, one may have defined a function ...
136 views

### How to simplify writing LibraryLink code?

LibraryLink is an API for extending Mathematica through C or C++. It is very fast because it gives direct access to Mathematica's packed array data structure, without even needing to make a copy of ...
332 views

### Find the volume of Phobos and Deimos

How can we calculate the volume of a 3D object using the new-in-10 computational geometry functions? For simple objects this works: ...
41 views

### Efficient way to get adjacency information from MeshRegion

What is the most efficient way to get adjacency information from a MeshRegion, i.e. some efficient representation of which vertex is connected to which other one? ...
16 views

### how to paste codes and expressions from mathematica to forum (here) [migrated]

can anyone tell me how to copy expressions from mathematica and paste them here, without any change. so that you can exactly see what is in my mathematica window... ...
83 views

### Solving a system of non-linear equations with symbolic parameters

I'm in the middle of preparing my master thesis, where I need to find a closed form or a numerical solution for the system below. Solve[] and ...
110 views

### How to recreate a certain word cloud

This is my current method: ...
57 views

### How to superimpose Graphics Line with a control? [on hold]

I would like to have a vertical line directly over a sliding control, but Overlay doesn't seem to work for me, and I don't know how to accomplish this.
103 views

### How do I get the ball to stop when it hits the ground?

1) I would like the graph to stop when the ball hits the ground (y=o). I have declared xmax, but have not been able to incorporate it into my code. 2) I would also like to include animate, where for ...