Interactive Phasor (Vector) Visio Shapes

Started by jamtart, March 12, 2009, 05:35:49 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

jamtart

Ahh, thank you. got them now. There is some awesome stuff there, thank you

jamtart

Why is this not working for me. I created a new phasor (RED) that i can not go to the same starting point as the others. Then I need to get this new phasor to always be at 90 degrees in front of the Yellow phasor. The new phasor must be equal to the value of the yellow phasor divided by a value that I want to enter into a box on the page somewhere. I thought I was getting a handle on this but then it all fell apart on me. Here is one of the least messed up copies i have...
sure would like to know what i am missing here.

wapperdude

#17
Hey!  Well, couple of pointers to begin with:
1.)  When you grouped, you must have identified the RED phasor 1st, then the group of phasors.  You need to do that in oppositie order.  So, ungroup and then regroup.
2.)  Before you regroup (Oh sure, now he tells me  :o ), set your RED phasor in the approximate location you want, say perpendicular to the BLACK phasor, with the beginning points aligned.  This is more of a convenience thing.
3.)  The math gets to be a little trickier, because of shifted origins.  Rather than try to explain it, here's the update.
Visio 2019 Pro

jamtart

Thanks for that info and sample wapperdude. It appears that I have a huge learning curve ahead of me as I had many other ideas to add to this project as it developed. I see that I had better take small steps. I took a look at the math involved and you were not kidding about the math getting a little trickier.

wapperdude

I chose to implement all of this by manipulating the 1D Shape Section entries.  This is a case where Visio uses coordinates rather than width/height to do calculations.  (A 1D shape has no height.)  I chose this approach because it's more intuitively straight forward, and, if you click a sub-shape, the drawn shape coincides with the "selection marks".  There are other approaches, e.g., manipulating the Geomemtry and/or the Shape Transform sections.  However, that's less intuitive since Visio relies on width/length, PinX, PinY, etc.  One other point, the group alignment box doesn't update.  Don't update it.  I did not guard the formulas, and updating will clobber them.   ::)  >:(
Visio 2019 Pro

jamtart

I made one small modification for the Red Phasor:
1-D endpoints,
EndX =(Sheet.8!EndX-BeginX)*COS(Sheet.8!Angle-90 deg)/COS(Sheet.8!Angle)+BeginX
I changed the +90 to -90
EndY =(Sheet.8!EndY-BeginY)*SIN(Sheet.8!Angle-90 deg)/SIN(Sheet.8!Angle)+BeginY
I changed the +90 to -90

I see now that when I manipulate the Black or Blue phasor so that the Red phasor SHOULD be at 0 degrees that the red phasor suddenly flips to 180 degrees. However, progress is being made, I think :P

Visio Guy

More rain on your parade, or salvation, depending on your perspective:

Vector Calculation Shapes from Junichi Yoda
For articles, tips and free content, see the Visio Guy Website at http://www.visguy.com
Get my Visio Book! Using Microsoft Visio 2010

wapperdude

Gee, I hear music...Oh, the weather outside is frightful...let it rain, .........Who'll stop the rain?  (CCR)

But look at all that we learned!!!
Visio 2019 Pro

jamtart

Well I have learned a lot from this exercise but alas I feel that this is just beyond my expertise at this time :'(