We probably have some different ideas on how it should work, because of
your "the largest value should be 3*V=9". I thought that if we have a
horizontal vector going right, and a vertical vector going down, and we
take the diagonal that goes the full distance down and right (so basically
a 2D square where up left is origin and bottom right is point we want to
calculate) the result should be the combination of both multipliers. If the
axis vectors were 3 right and 2 down, that point should have a multiplier
of 6 because it fully uses both axis vectors. From your statement I assume
that you didn't think of it this way.

If you think that the maximum value achievable is 3 in my imaginary square
of the first paragraph, what would you say is the value in the bottom
right? If it is 3, why does the horizontal vector count more than the
vertical one? It's like the bigger vector overrides the smaller one without
taking into account the smaller vector's value. What if we only go half
way? What's the density in the middle of the square? I would expect the
following: We go halfway to the right, so we don't multiply by the full
value but rather only by 1.5. So we are sitting at 1.5 and now we need to
go down halfway. Going all the way down would mean multiplying by 3 but
halfway would be 2. (this is because 1 original copy + 2 extra copies make
the 3 of the multiplier, but going halfway would mean 1 + 2/2 = 2, if this
is confusing I'll clarify it with more examples). So 1.5 x 2 = 3. This also
makes sense to me if I think that the bottom right is 6 and we are half way
through reaching it, so half of 6.

Now, if you look at the last part of yesterdays example document, I tried
to "re-do" the "a" segment showing all the steps the code might do. I first
decompose the vector into a combination of axis vectors, and using
coefficients to show "how much" of each vector we have to take. Next I take
the original density, 3, and add, for each axis vector I needed to use, the
following: origin_density x (multiplier - 1) x vector_coefficient. (Note
that I subtract 1 because of what I mentioned in the parenthesis above,
it's an accumulation so we have to subtract 1 to the multiplier, otherwise
we count the "original amount" twice). This worked for some cases but after
some deeper thought on it today I realized that this is wrong. Instead of
just summing one on top of the other, we have to make the operations step
by step and use the result of the first step as input for the second step.
Hereby goes attached the FIXED VERSION

Lets consider the box of the first paragraph.





2017-07-19 0:05 GMT+02:00 Christopher Sean Morrison <brl...@mac.com>:

>
> > Attached goes an example of one way I think it might work.
>
> This is an excellent example to work through!
>
> > In the end we want one vector for each axis, that tells, through a
> multiplier, how the density changes as we move in its direction. Choosing
> any point in the region is taking the right combination of the vectors to
> go from the origin to the point, and applying the multipliers of the
> vectors to the density of the origin. Do this twice and you get in-point
> and out-point of the segment. Now you can interpolate and calculate mass.
>
> I think I’m following you, but via different calculations.  Where is your
> “3 + 3/2” coming from for segment a?  I would have calculated it as a
> density field going from 3 (pt V) to 6 (pt B), divided by the contribution
> ratio of each.  Showing all steps, undoubtedly with a mistake or three
> because this was done in just a few minutes:
>
>     density(V)            density(B)        3   6
> ———————–––––––––––– + ––––—––——–––––––––– = – + – = 4.5 = contrib(a1, VB)
> vect(VB)/vect(a1'V)   vect(BA)/vect(a1’B)   2   2
>
> Obviously same result, but is that essentially the same method?  What’s
> throwing me is that I don’t get the same result for the out point, which
> means I probably have something wrong.  I get:
>
> contrib(a2, VB) + contrib(a2, VA)   4.5 + 9
> ––––––––––––––––––––––––––––––––– = ––––––- = 6.75
>                 2                       2
>
>
> Regardless, I’m not sure I understand how your result (10.5) is even
> possible as the largest value should be 3*V=9, no?
>
> > The user could also define non-axis vectors and we should then break
> them down into axis ones.
>
> Yes, it’s important to note that geometry is often not axis-aligned like
> in your setup, so deriving vectors from the points will probably be
> desirable.  That is, derive vectors VA, VB, VC, VD from the five density
> field points.
>
> > This method only covers some really simple density distributions and
> fails to represent more complex ones like density values that go up and
> down as we advance in a certain direction. I see no easy way of modeling
> this without complicating the whole think a lot. What do you think?
>
> This makes me think we’re using different methods.  Summing contributions
> from the different points/vectors should give values that go up and down…
>
> Cheers!
> Sean
>
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> BRL-CAD Developer mailing list
> brlcad-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/brlcad-devel
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
BRL-CAD Developer mailing list
brlcad-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/brlcad-devel

Reply via email to