On Friday, 22 September 2017 at 17:11:56 UTC, Ilya Yaroshenko
wrote:
Should we add `a * b` to ndslice for 1d vectors?
Discussion at https://github.com/libmir/mir-algorithm/issues/91
If it is for element-wise product, then possibly yes.
If it is for dot product (as suggested by the github
On Thursday, 15 September 2016 at 17:32:16 UTC, Adam D. Ruppe
wrote:
On Thursday, 15 September 2016 at 14:40:24 UTC, Andrei
Alexandrescu wrote:
Wait, but I just showed how with vanilla ddoc you can
immediately use mathjax to do better than adrdox. No need for
any pre/postprocessing or
On Tuesday, 23 August 2016 at 12:12:30 UTC, Seb wrote:
On Tuesday, 23 August 2016 at 11:58:53 UTC, tn wrote:
On Monday, 22 August 2016 at 15:34:47 UTC, Seb wrote:
http://blog.mir.dlang.io/random/2016/08/22/transformed-density-rejection-sampling.html
What are the columns "mu time"
On Monday, 22 August 2016 at 15:34:47 UTC, Seb wrote:
http://blog.mir.dlang.io/random/2016/08/22/transformed-density-rejection-sampling.html
What are the columns "mu time" and "sigma^2 time" of the
benchmark table in the Sampling subsection?
On Tuesday, 26 April 2016 at 18:45:09 UTC, Andrei Alexandrescu
wrote:
On 04/26/2016 02:29 PM, TheGag96 wrote:
On Tuesday, 26 April 2016 at 14:33:42 UTC, tn wrote:
Maybe the name of the function should then be "writes" and/or
"writesln" (instead of "print"), so
On Tuesday, 26 April 2016 at 12:52:13 UTC, Andrei Alexandrescu
wrote:
On 04/26/2016 08:18 AM, cym13 wrote:
The first questions I expect are "when should I use print and
when use
writeln?" for they share a common role with common features.
"When you want spaces between arguments and when you
On Thursday, 25 February 2016 at 18:19:56 UTC, John Colvin wrote:
I don't know of an algorithm for generating random permutations
that isn't in-place (or O(N) storage), but I'm not an expert on
the topic so maybe one does exist.
These might be relevant:
On Saturday, 6 February 2016 at 13:06:37 UTC, Andrei Alexandrescu
wrote:
Could you please add two simple calculations? Assuming uniform
random distribution of data, compute the average number of
swaps as a weighted average of orderings. Also, show the number
of lines (one test or one swap per
On Friday, 5 February 2016 at 21:42:41 UTC, Xinok wrote:
On Friday, 5 February 2016 at 15:13:56 UTC, tn wrote:
On Thursday, 4 February 2016 at 20:30:57 UTC, Timon Gehr wrote:
At most 6 comparisons, <=3 swaps, idempotent (optimal number
of swaps):
...
Inspired by this, I made four ot
On Saturday, 6 February 2016 at 01:46:58 UTC, Andrei Alexandrescu
wrote:
On 02/04/2016 03:30 PM, Timon Gehr wrote:
At most 6 comparisons, <=3 swaps, idempotent (optimal number
of swaps):
Oh, also: could you let that bad boy run and let it find
anything that does idempotent partition in 6
On Thursday, 4 February 2016 at 20:30:57 UTC, Timon Gehr wrote:
At most 6 comparisons, <=3 swaps, idempotent (optimal number of
swaps):
...
Inspired by this, I made four other versions of the function that
are shorter but make more swaps (at most 4, 6, 7 and 8 swaps
respectively). Each
On Thursday, 21 January 2016 at 01:11:19 UTC, Andrei Alexandrescu
wrote:
On 01/20/2016 04:22 PM, Ivan Kazmenko wrote:
2. The index of minimum or maximum element, mostly using plain
array as
a range. I write "a.length - a.minPos.length", and it looks
completely
unintuitive. Additionally, when
On Thursday, 14 January 2016 at 19:46:33 UTC, anonymous wrote:
On 14.01.2016 16:29, tn wrote:
I don't use my browser in full screen mode, but the useless
white
margins are still there. With the horizontal-split mode the
line length
of the message is less than 60 characters. Compared to that, I
On Thursday, 14 January 2016 at 12:31:51 UTC, w0rp wrote:
I love this redesign.
Anyone who complains about not taking up the full width of the
screen is wrong. If lines stretch on eternally, they become
harder to scan with your eyes. It's a well known effect which
has been studied and
On Tuesday, 8 December 2015 at 15:25:28 UTC, Andrei Alexandrescu
wrote:
I'm working on the complexity algebra and of course trying to
simplify my life :o). One good simplification would be to get
rid of log(polynomial_sum) terms such as:
log(n + m)
log(n^^3 + n1^^2 + n2)
etc.
Do any of
On Tuesday, 8 December 2015 at 16:25:50 UTC, tn wrote:
... and that m is more than polynomially larger than s. ...
Should of course be "larger than n".
On Friday, 4 December 2015 at 03:37:10 UTC, Andrei Alexandrescu
wrote:
On 12/3/15 10:29 PM, Jack Stouffer wrote:
On Friday, 4 December 2015 at 02:21:12 UTC, Andrei
Alexandrescu wrote:
On 12/03/2015 09:10 PM, Idan Arye wrote:
The complexities of the operations is a property of the data
On Friday, 4 December 2015 at 09:57:48 UTC, Jakob Ovrum wrote:
On Friday, 4 December 2015 at 09:51:05 UTC, tn wrote:
"I just want to insert an element. I don't care how long it
takes. Why do I need to specify that it should be linear?"
In my opinion, there should be "
On Friday, 4 December 2015 at 14:08:08 UTC, Andrei Alexandrescu
wrote:
On 12/04/2015 04:51 AM, tn wrote:
"I just want to insert an element. I don't care how long it
takes. Why
do I need to specify that it should be linear?"
Oh but you do care.
I don't, if I have a small
On Monday, 26 January 2015 at 20:35:31 UTC, Andrei Alexandrescu
wrote:
On 1/26/15 12:30 PM, Dicebot wrote:
We couldn't merge it into std.experimental before because you
have
stated that even std.experimental modules shouldn't have a
breaking
changes normally. It was 2 reviews ago.
Now you
On Friday, 26 September 2014 at 06:29:21 UTC, Dragos Carp wrote:
Though you could use prerelease and/or build suffixes (1.2.3-0w
/ 1.2.3+0w).
These are very close to what I would like to see.
Though, if I understand correctly, build suffix wouldn't work, as
for example 1.2.3+0w and 1.2.3+1w
On Tuesday, 23 September 2014 at 06:22:27 UTC, Jacob Carlborg
wrote:
On 22/09/14 23:04, tn wrote:
What is the recommended way of versioning bindings? If the
binding of
the target library 1.2.3 is versioned as 1.2.3 and a bug is
fixed in the
binding (no change in the target library), how
On Monday, 22 September 2014 at 09:33:52 UTC, Sönke Ludwig wrote:
If you can think of any potentially important and especially
backwards-incompatible changes/additions, please mention them
(ideally as GitHub tickets), so that we can include them before
the 1.0.0 release.
What is the
On Monday, 28 July 2014 at 10:27:02 UTC, Iain Buclaw wrote:
- GDC's homepage is now getting a UI update.
Staging area for the new look is found here:
http://staging.dgnu.org
I think the old logo was better. The new one looks weird, like it
was unfinished.
On Sunday, 23 February 2014 at 21:38:46 UTC, Walter Bright wrote:
On 2/23/2014 12:31 PM, Andrej Mitrovic wrote:
I'd prefer 3 separate states. pragma(inline),
pragma(no_inline), and
pragma(default_inline) or something like that.
That makes documentation with a sorted list of pragmas
On Tuesday, 17 December 2013 at 19:09:49 UTC, H. S. Teoh wrote:
However,
they do exhibit good spatial locality in higher-dimensional
space (i.e.,
if entry X is accessed first, then the next entry Y is quite
likely to
be close to X in that space). Does anybody know of a good data
structure
On Thursday, 5 December 2013 at 11:13:17 UTC, Siavash Babaei
wrote:
Hi,
I primarily work in statistical modelling of financial data
(risk modelling). I am at a point when I need to think about
developing applications in addition to data analysis and
modelling.
My primary concern is whether
In general this sounds great. However:
On Tuesday, 3 December 2013 at 14:26:07 UTC, Andrew Edwards wrote:
Betas will be released four weeks after an official release.
Does this mean that a new release branch will be created at that
point? I think it makes sense.
Once a release candidate is
On Thursday, 14 November 2013 at 00:37:38 UTC, Tyro[17] wrote:
Greetings,
I have accepted the responsibility of preparing the builds for
DMD and would like to engage in conversation about the way
ahead.
The first concern I have is about the build cycle.
... (clip) ...
Your thoughts and
On Tuesday, 12 November 2013 at 07:33:57 UTC, qznc wrote:
On Tuesday, 12 November 2013 at 04:41:56 UTC, Vladimir
Panteleev wrote:
double[] arr = [1, 2, 3, double.nan, 1, 2];
assert(arr.isSorted);
arr.sort();
This code will fail with an assert error, but not the one on
the second line. Rather,
On Tuesday, 12 November 2013 at 08:54:35 UTC, tn wrote:
On Tuesday, 12 November 2013 at 07:33:57 UTC, qznc wrote:
On Tuesday, 12 November 2013 at 04:41:56 UTC, Vladimir
Panteleev wrote:
double[] arr = [1, 2, 3, double.nan, 1, 2];
assert(arr.isSorted);
arr.sort();
This code will fail
On Tuesday, 12 November 2013 at 09:40:52 UTC, Walter Bright wrote:
On 11/12/2013 1:33 AM, tn wrote:
I could not find any documentation on how the unordered
comparison operators (, !=, !=, !, !=, !, !)
translate into opCmp calls.
That's because they just don't translate to opCmp calls.
Well
On Tuesday, 12 November 2013 at 15:56:25 UTC, Andrei Alexandrescu
wrote:
On 11/12/13 12:54 AM, tn wrote:
...
An alternative would be to check for nans explicitly.
I think NaNs are singular unordered values that make invalid
inputs for either sort or isSorted. We should simply add an
assert
On Tuesday, 12 November 2013 at 17:59:37 UTC, Vladimir Panteleev
wrote:
1) As above, introduce a less function which guarantees
transitivity for basic types, and use it in examples throughout.
2) Improve documentation and visibility of this problem. For
example, add this to the documentation
On Tuesday, 12 November 2013 at 19:39:19 UTC, Vladimir Panteleev
wrote:
On Tuesday, 12 November 2013 at 19:26:12 UTC, tn wrote:
Thus, the correct solution would be to modify the functions to
take lessOrEqual as a template parameter instead of less.
Too late for that now... just like it's too
On Tuesday, 12 November 2013 at 20:03:37 UTC, Andrei Alexandrescu
wrote:
Consider we define equiv(a, b) as (a, b) = !less(a, b)
!less(b, a).
If at least one of the numbers is NaN, all comparisons return
false. That puts NaN in the same equivalence class with all
numbers, including numbers
On Tuesday, 12 November 2013 at 21:09:34 UTC, Vladimir Panteleev
wrote:
On Tuesday, 12 November 2013 at 21:03:03 UTC, tn wrote:
assert((equiv(a, b) equiv(b, c)) = equiv(a, c));
(= on Booleans is actually implication.)
Shouldn't the implication be to the other direction? Then it
becomes
On Tuesday, 12 November 2013 at 21:07:48 UTC, Andrei Alexandrescu
wrote:
On 11/12/13 1:03 PM, tn wrote:
On Tuesday, 12 November 2013 at 20:03:37 UTC, Andrei
Alexandrescu wrote:
Consider we define equiv(a, b) as (a, b) = !less(a, b)
!less(b, a).
If at least one of the numbers is NaN, all
On Tuesday, 9 April 2013 at 08:33:53 UTC, Manu wrote:
On 9 April 2013 18:04, Dicebot m.stras...@gmail.com wrote:
On Tuesday, 9 April 2013 at 07:57:37 UTC, Manu wrote:
Are you saying the example above is not actually valid code?
struct Foo {
int a = 0;
pure int bar( int n ) { //
Hi. Just a couple stupid questions:
* What is the relation between std.uni and std.utf? Why is two
modules needed? Seems confusing to me. Shouldn't these be
combined? If not, then please explain the the distinction in the
beginning of the module documentation.
* Shouldn't the module be
On Tuesday, 19 February 2013 at 16:28:15 UTC, John Colvin wrote:
On Tuesday, 19 February 2013 at 16:03:58 UTC, bearophile wrote:
Don:
Simd comparison generally doesn't return a bool, it returns a
bool array,
one per element.
Does (arr[] 10) mean is every element in arr less than
10 OR is
On Thursday, 14 February 2013 at 19:54:28 UTC, Jacob Carlborg
wrote:
D has any (previously an overload of canFind) as an
algorithm that
finds whether at least one element of a range satisfies a
condition,
otherwise writable as !r.find!(a = condition).empty. The
convenience/mechanics/generality
On Wednesday, 19 December 2012 at 19:52:41 UTC, Robert Jacques
wrote:
On Wed, 19 Dec 2012 09:35:39 -0600, Andrei Alexandrescu
seewebsiteforem...@erdani.org wrote:
On 12/19/12 2:30 AM, Walter Bright wrote:
https://github.com/D-Programming-Language/phobos/pull/1018/files
Shouldn't it be part
On Wednesday, 19 December 2012 at 10:13:56 UTC, Iain Buclaw wrote:
On 19 December 2012 08:55, Walter Bright
newshou...@digitalmars.com wrote:
On 12/19/2012 12:47 AM, Alex Rønne Petersen wrote:
On 19-12-2012 08:35, Jacob Carlborg wrote:
On 2012-12-19 08:30, Walter Bright wrote:
On Tuesday, 27 November 2012 at 21:16:41 UTC, Walter Bright wrote:
On 11/27/2012 9:51 PM, Manu wrote:
There's another you missed:
enum X = 10;
I would have imagined this would be semantically identical to
E.A/E.B,
but the compiler seemed to view this as distinct in my
experiments.
Those are
On Thursday, 22 November 2012 at 14:52:33 UTC, Vladimir Panteleev
wrote:
On Thursday, 22 November 2012 at 10:41:33 UTC, Andrej Mitrovic
wrote:
On 11/22/12, r_m_r r_...@mailinator.com wrote:
I just modified the Main_Page
and added the WhySwitch page (content copied from the old
wiki:
On Thursday, 18 October 2012 at 11:43:40 UTC, simendsjo wrote:
On Thursday, 18 October 2012 at 11:31:47 UTC, tn wrote:
Hi.
I want to extend math library functions to work with my own
type. However, the definition for my own type seems to prevent
automated access to the original function. How
On Thursday, 18 October 2012 at 13:35:55 UTC, simendsjo wrote:
On Thursday, 18 October 2012 at 12:10:17 UTC, tn wrote:
On Thursday, 18 October 2012 at 11:43:40 UTC, simendsjo wrote:
On Thursday, 18 October 2012 at 11:31:47 UTC, tn wrote:
(...)
You need to manually add std.math.exp2
On Thursday, 23 August 2012 at 00:19:39 UTC, bearophile wrote:
At page 69 of those slides there is some code that looks
interesting, I think this is a reduced version of part of it,
that shows another way to use vectorized comparisons:
void main() {
double[] a = [1.0, 1.0, -1.0, 1.0,
On Friday, 1 June 2012 at 01:57:36 UTC, kenji hara wrote:
I'd like to propose a new language feature to D community.
...
This patch is an additional enhancement of opDollar (issue 3474
and #442).
Sounds awesome. However, the name opDollar should be changed to
something like opSize, opLength,
On Thursday, 8 December 2011 at 13:13:38 UTC, Vladimir Panteleev
wrote:
On Thursday, 8 December 2011 at 12:27:44 UTC, Steven
Schveighoffer wrote:
you receive an A+ from me!
BTW, is there any way to sort the threaded view so that the
newest messages appear on top? Simply because, in a web
Andrei Alexandrescu Wrote:
On 11/20/11 2:40 AM, Andrei Alexandrescu wrote:
Thanks to all who provided feedback! I read again the entire thread,
then made one more pass:
http://d-programming-language.org/new/
I made one more pass and improved the homepage in a number of ways.
^^-32 is still small enough to have no performance penalty in
practise.
-- tn
Fawzi Mohamed Wrote:
On 23-nov-10, at 10:20, tn wrote:
bearophile Wrote:
Don:
Since the probability of actually generating a
zero is 1e-4000, it shouldn't affect the speed at all g.
If bits in double have the same probability then I think there is a
much higher
are
unacceptably slow. I had to use 1 - uniform![)(0.0, 1.0) instead of
uniform!(](0.0, 1.0) because of this issue. I would also expect versions
using float and double to be faster than the version using real.
-- tn
tn Wrote:
int [] 271
int [) 271
int (] 283
int () 285
long [] 372
long [) 399
long (] 401
long () 397
float[] 286
float[) 374
float(]5252
float()5691
double
56 matches
Mail list logo