1
vote
1answer
156 views

Recursion evaluate Table power exceeded limit

I wrote 2 simple recursive functions for calculating the power of a table. pol3[Tb_List, n_Integer?Positive] := If[n == 1, Tb, Tb.pol3[Tb, n - 1]] and ...
2
votes
2answers
529 views

Putting NDSolve into ParametricPlot

I am having issues using Manipulate to plot the (numeric) solution to an ODE for different parameter values. I have a code that has several stages, which seem to ...
1
vote
1answer
107 views

How to label vertices in a grid with random integers?

I would like to assign each vertex a random number with the minimum bound equal to the smallest vertex and the maximum equal to the value of the largest without repeats. ie in a 20x20 grid, the ...
5
votes
0answers
86 views

Modify NDSolve`StateData (if possible)

I am trying to solve a PDE that needs to be scaled constantly (refer to this). @andre suggests I modify NDSolve`StateData. Now, the problem is, I'm not used to ...
2
votes
1answer
116 views

Is it possible for me to explicitly specify a point list for SpatialGraphDistribution?

The function RandomGraph[SpatialGraphDistribution[n, r]] generates a random geometric graph over $[0,1]^2$ where vertices are connected if they are within a ...
7
votes
2answers
193 views

Why doesn't DumpSave work for elements created within a local notebook context?

I recently noticed that when dealing with notebooks with local context, I cannot successfully DumpSave variables, or, rather, when I call ...
2
votes
1answer
130 views

Determining whether two k-chromatic graphs are equivalent (not simply isomorphic) using IsomorphicGraphQ?

In a previous question of mine, I asked whether Mathematica's built-in routines could determine an isomorphism for two $k$-chromatic graphs, Determining whether two $k$-chromatic graphs are isomorphic ...
0
votes
1answer
224 views

DataRange problem in a ListLinePlot within a Manipulate

I'm trying to create a simulation of a set of lists with Manipulate[] and ListLinePlot[]. However, as my simulation starts with ...
3
votes
1answer
64 views

Restricting a plotted expression to reals in a Manipuate

I have an expression from which I'm trying to create a plot that I can manipulate. The expression contains Abs, and I only want to have it evaluated for reals. What ...
1
vote
2answers
951 views

Discrete FFT of non-periodic signal excited by short pulse

Say I have a signal F(t) which represents a excitation by a pulse (so it is not periodic and declining to zero amplitude). According to this answer, for instance, ...
1
vote
2answers
298 views

Implicit differentiation to find the slope of the tangent line to the graph at the indicated point [duplicate]

I used ContourPlot to plot the graph of x Sin[Pi y] - y Cos[Pi x] == 1 with the following input: ...
2
votes
5answers
276 views

Creating ordered triplets from an Excel sheet

I have an Excel sheet of the form: " " a b c 1 R S T 2 U V W 3 X Y Z Where every entry is a number (except the blank quotes, ...
2
votes
1answer
175 views

Export to mat file does not work

I use this command from the Mathematica documentation center Export["1.mat", {"t" -> {{1,2,3}},"u" -> {{4,5,6}}}, "LabeledData"] to save data as mat file ...
1
vote
1answer
91 views

NMaxmize with a list of variables

I want to use NMaximize to find the maximum value of a function with multiple variables. The problem is I would like to set this up so the number of variables is only decided when the function sees ...
0
votes
0answers
49 views

DeleteCases and Inequalities [duplicate]

I would like to remove cases from a list according to an inequality rule - e.g. remove all values less than x. I can do the following but this seems very clumsy: ...
7
votes
1answer
100 views

Crash with subsetting TemporalData

The first line gets a single sample path for an M/M/1 queue for time between 0 and 100. No problem, I can plot it, etc. ...
10
votes
1answer
233 views

Why is ReplaceAll behaving like this?

I'm learning to use the ReplaceAll function and I found the behavior of which is quite confusing. For Sqrt[f[x, y]] /. f[___] -> u Mathematica returns ...
0
votes
2answers
354 views

Dropping Higher Order Terms in symbolic evaluation

I have a series of symbolic manipulations (along with some coefficients). As a sample, here is one of the intermediate forms ...
11
votes
1answer
304 views

Using non-trivial objects in RLink

I would like to use RLink to access igraph, which has an R interface. I do not know R; my motivation for learning it is to be able to access igraph easily. I installed igraph using ...
0
votes
1answer
101 views

Should Read[] not close its Stream? [closed]

I read a record from a file. Read[file,Record]; It reads and opens a stream. Should Read not close its stream after ...
1
vote
1answer
128 views

Match and replace subexpression

I would like to replace the expresion $(n1-1)$ to $z1$ in following: In[1] := 2*n1*p[n1-1,n2] Out[1] := 2*(z1+1)*p[z1,n2] I have tried ...
2
votes
2answers
309 views

How to prevent errors in Manipulate with ListPlot when a result is an empty list?

I am trying to plot two lists, where one is the reference list, and the other is only used to select and highlight the first list. Basically, I want to use the selection list ...
2
votes
1answer
205 views

Is there any way to force Mathematica to collect a symbol in a polynomial?

Let's say that I have a polynomial like this: a + b + c Is there any way that I can get Mathematica to transform it to: ...
3
votes
1answer
300 views

How can I connect database(MSSQL Server) with Mathematica?

Newly I started working with database(MSSQL Server 2012). by google help, I created Table name as EmployeesList and also ...
0
votes
1answer
524 views

How can I find the Fourier series from discrete data?

I would like to define the function with Fourier series when I just have discrette data. (I don't have a specific function). I can draw the graph using the data, but I don't have a idea how can I get ...
4
votes
2answers
218 views

Unexpected behavior of rule matching a pattern

I am a beginner exploring the world of Mathematica. I expected the following code T[6, 5, 4, 1, 2, 3] /. {T[a___, 1, b___] -> Length[List[b]]} should return ...
0
votes
2answers
81 views

Getting value of clock [duplicate]

I have the following code: a = Dynamic[Floor[Clock[2]]] (*So this basically alternates between 0 and 1*) If[a==1, Print["true"]] But this doesn't work, it ...
3
votes
3answers
126 views

How to create a button that colors a selected piece of text in a cell?

I use Mathematica 9.0.1 and I want change the color of a selection in a text cell using a button. But when I use this code it changes the color of the entire cell. ...
4
votes
2answers
169 views

Background color of Code cell lost when convert a notebook file to pdf

Well, I have a notebook with the built-in stylesheet Preprint, which I'd like to convert it to pdf. Everything works well except for the code cells(I use the shortcut key alt+8 to create cells of code ...
4
votes
5answers
869 views

Removing zero values from ordered pairs

I have some processed data, which are basically a collection of ordered pairs in the form: {{x1, y1}, {x2, y2}, ..., {xn, yn}} Ordered pairs which have either a ...
1
vote
3answers
129 views

problem with Importing multiple files

I need to import about 100000 "dat" files to my progrom. I want to do this using the last answer to this question: Importing multiple files using a for-loop I know that I should define a list of all ...
-1
votes
1answer
196 views

Integral evaluation taking too long [closed]

When I try to evaluate the following integral, it runs for a much longer time than I think is should without producing a result. What might be the problem? Can anybody please point it out? ...
-1
votes
1answer
382 views

How can I draw a Cuboid given its center and its dimensions? [duplicate]

I want to draw a Cuboid accroding to the coordinates of its geometric center and its dimensions, rather than its diagnoal coordiantes. And How can I draw a triangular prism?
9
votes
1answer
246 views

Efficiently filling area with disks located at certain points

Starting from a set of points, I want to fill an area using disks. Each disk's center should be one of the points and the disks should not overlap. I've managed to write a function that, given a list ...
3
votes
2answers
177 views

How to migrate or export projects with Workbench

Imagine the following scenario: user A is developing a project with documentation in workbench. She wants to give her (unfinished) work to user B , so that user B can continue work on the project and ...
0
votes
2answers
179 views

Reduce on equations involving integrals

Here's part of problem from a college physics text: A time-dependent force F = (8.00 i - 4.00 t j) N (where t is in seconds) is applied to a 2.00-kg object initially at rest. (a) At what time ...
3
votes
3answers
366 views

Defining a new Function using RegionPlot

I'm trying to make images like this: to illustrate 2D integrals to a calculus class. I used the code ...
2
votes
2answers
637 views

Using ChemicalData to make molecule graphics

I would like to take the acetone $((CH_3)_2CO)$ and chloroform $(HCl_3)$ molecules that Mathematica's chemical data provides, and plot them together. I want to show how chloroform can hydrogen bond ...
0
votes
2answers
725 views

Sequence of data in 3D, joining the points

Let me just first say I am not actually trying to find a function for these set of data. All I am doing is joining the points to make a line. Basically let's say I have some data, which I cleverly ...
0
votes
0answers
35 views

Symbolic Calculations with formal matrices [duplicate]

I want to make calculations with matrices in the form (for lovers of statistical mechanics, is just the first step replica symmetry breaking) ...
1
vote
0answers
137 views

Manipulate - Flickering graphics

I am new to mathematica and was experimenting with NDSolve and doing a simple demonstration of orbital motion and Newtons laws. I put together the following code which all seems to work except the ...
0
votes
2answers
134 views

Iterating Reads From a Text File and Writing the Results of Operation

I have a very large text (TSV) file. I am able to now read single line, thanks to StackExchange. I am able to read a part of that line using the part operator. I want to iterate through the whole ...
3
votes
2answers
549 views

NDSolve: Normalizing at every step

Suppose I have an transport equation with an initial conditions: ...
5
votes
1answer
127 views

Functions, Options and Symbols

In the normal Mathematica language, where no built-in symbols are redefined and no evil things happen, is it a valid assumptions, that no function symbol (Plot, ...
9
votes
3answers
321 views

Replace operators

/. can be used to replace variables but how can one replace operators. For example in a * b, ...
5
votes
1answer
271 views

Looking for a package regarding Schur Polynomials and Kostka numbers

I'm currently looking for any Mathematica package that involves Schur polynomials and/or Kostka numbers. More generally, I'd be happy with anything that expands on symmetric polynomials in general. ...
0
votes
0answers
28 views

What is the precision of this number? [duplicate]

In a matrix evaluation, I got the following number. 2.8330574963868513` I understand that the number after ` shows the precision of the output number. But this ...
2
votes
2answers
308 views

BC for transport equation using NDSolve

First I can solve a transport equation with a source (Is it still called transport equation?) using DSolve. The form of the source serves only as an example. It can ...
4
votes
1answer
151 views

Automatically tracing and keeping ViewPoints in a list while manually rotating 3D graphics

I will need to make a video from the manual rotation of a 3D graphics. In order to do this, I will need to record the set of all view points that I made during rotation. There is method that we can ...
5
votes
4answers
596 views

Left-aligned PlotLabel?

Is it possible to have the text generated by PlotLabel (or any other function) aligned to the left side of the plot instead of in the center?

15 30 50 per page