Mr. Roman Pearce

## 1678 Reputation

18 years, 300 days
CECM/SFU
Research Associate

I am a research associate at Simon Fraser University and a member of the Computer Algebra Group at the CECM.

## simplify real trig expression...

Maple

A reddit user posted an interesting question:

The problem is how to simplify, e.g. 2/3*37^(1/2)*sin(1/6*Pi+1/3*arccos(55/1369*37^(1/2)))+2/3 to 4.  I tried a few things and got nowhere.  Any suggestions?

## ListTools count for each unique element...

I frequently have a list of numbers and what I want is a sorted list of unique elements with a count of how many times each element appears.  Is there some way to do this with ListTools?

Here is my code:

listhist := proc(L)
local S, T, i;
T := table(sparse):
for i in L do T[i] := T[i]+1; end do;
S := sort(map(op,[indices(T)]));
[seq([i,T[i]], i=S)];
end proc:

## plotting a volume of data - densityplot3...

Maple

I have the following problem. Two formulas in three variables represent the costs of algorithms. I want a visual of their ratio, so that I can "see" how their relative performance varies. Here is a simple example. I can analyze this example analytically, but you can't always do that.

```R := sum(binomial(n+i*d,n),i=1..k-1);
S := binomial(n+k*d,n);
f := unapply(R/S, n, d, k);
A := Array(1..10,1..10,1..10,f,datatype=float[8]);
```

I want a 3-dimensional rendering...

## hfloat polynomials...

I want to evaluate a polynomial and turn its coefficients into hfloats. Shouldn't evalhf do this? For example:
```f := randpoly([x,y,z]);  # integer coefficients
g := evalf(f);    # software float coefficients
h := evalhf(f);   # error
```
I think the last one should give me a polynomial with hardware floating point coefficients. Instead I get an error.

## "this issue has been tracked"...

There are lots of posts on MaplePrimes with Wei Xi Fan telling us that "this issue has been tracked". I'm always happy to hear that, but I think a subtle alternative would be better: I would write in red at the bottom of the original report "Note: this issue has been reported to Maplesoft's internal bug tracking database." Make it sound kind of ominous, as if the offending bug will surely be crushed. Also, I think a message in red on the original post is better than a reply which appears somewhere down the page. Of course for this to work, it would have to be easy (one click?) for company
 1 2 3 Page 1 of 3
﻿