While sitting in class during a lecture I had the most interesting idea for a story, oir rather a series of short stories that builds up to a main arc I suppose. I really want to get it down here mostly because I know no one will ever read it, and if I do by some miracle end up writing the full story I won't have to worry about spoiling it for anyone.
Set in an alternate reality of the present day. For 25 years a few people have suddenly come into strange and powerful abilities. Only one person at a time ever exhibits the powers, and they only live for 6 months, after which time most die of a heart attack. Over the years many different type of people have the acquired the power. Some have used it for good and evil, while others chose to seclude themselves until they die.
Many people have studied the phenomenon with no answers. There are no apparent statistical trends, leading many to believe the power is completely random in its selection. The appears to be no bias in gender, race, or geographical location. Only a few differences have crept in over the years. Some have died prematurely, but only after extreme exertion.
I'll be writing more about this later as I go over my notes again, I wrote a lot in a short amount of time, but now it's bedtime!
Thursday, October 29, 2009
Wednesday, October 28, 2009
Scripts Everywhere, and not an App to Run
In another entry of my series on my novice attempt at programming, I will be talking about Vbscript. When looking for references and tutorials you will inevitably locate guides for internet related VBscript, while my need at the moment is decidedly system based.
Lucky for me I know enough about VBscript to get me started. I was able to create an executable Vbscript file that didn't crash or exit. It maintained a healthy non-invasive loop that did exactly what I needed it to do. Once I had that little issue out of the way, which I might say was no small feat, I moved onto my arch nemesis; Internet Explorer.
So now I have this working VBscript that handles the system side requirements, but I still need it to reach out an touch an active IE window. Once I discovered the way to get the collection of shell windows it was pretty easy to start running head on into the brick wall of IE.
I spent most of my day trying to get a stupid onclick event working. Of course you can't just add it as a damn attribute, which it is; you have you use a special method to add the onclick event, which of course isn't supported by Microsoft's own webcontrol. Great! I finally just had to inject some Javascript into the damn document to add the event.
What I learned is that Microsoft can't handle a process from its own method, you have to use a third-party solution. Microsoft continues to amaze me, and don't even get me fucking started on the cross-frame scripting issue. Why I can't access an Iframe that in IE from my own damn machine is beyond me.
Lucky for me I know enough about VBscript to get me started. I was able to create an executable Vbscript file that didn't crash or exit. It maintained a healthy non-invasive loop that did exactly what I needed it to do. Once I had that little issue out of the way, which I might say was no small feat, I moved onto my arch nemesis; Internet Explorer.
So now I have this working VBscript that handles the system side requirements, but I still need it to reach out an touch an active IE window. Once I discovered the way to get the collection of shell windows it was pretty easy to start running head on into the brick wall of IE.
I spent most of my day trying to get a stupid onclick event working. Of course you can't just add it as a damn attribute, which it is; you have you use a special method to add the onclick event, which of course isn't supported by Microsoft's own webcontrol. Great! I finally just had to inject some Javascript into the damn document to add the event.
What I learned is that Microsoft can't handle a process from its own method, you have to use a third-party solution. Microsoft continues to amaze me, and don't even get me fucking started on the cross-frame scripting issue. Why I can't access an Iframe that in IE from my own damn machine is beyond me.
Monday, October 26, 2009
Maximun Warp (XML style)
Thanks to my rather quick education in ASP yesterday, I was able to bypass my companies GUI in both queries and updates. I no longer have to worry about the Internet Explorer window crashing right in the middle of 10000 updates. The good news is I went from an average update time of 3-4 seconds to a consistent 70 milliseconds. A large improvement!
Sending the query to the server eats about 35 milliseconds. The server spits out a HTML page that is used for an IFRAME. I than have to turn this HTML junk into a usable XML string; this process eats up another 30 milliseconds. From here I make the update to the XML string, and then send it back to the server with an update tag attached; this only takes around 7 milliseconds!
My queries should go a lot quicker now, I don't have to make an update or convert the HTML into XML. I could feasibly run queries that respond in 35 milliseconds, and considering this is through the httprequest method, that's not too bad at all! I could run through 10000 customer entries in under an hour!
Sending the query to the server eats about 35 milliseconds. The server spits out a HTML page that is used for an IFRAME. I than have to turn this HTML junk into a usable XML string; this process eats up another 30 milliseconds. From here I make the update to the XML string, and then send it back to the server with an update tag attached; this only takes around 7 milliseconds!
My queries should go a lot quicker now, I don't have to make an update or convert the HTML into XML. I could feasibly run queries that respond in 35 milliseconds, and considering this is through the httprequest method, that's not too bad at all! I could run through 10000 customer entries in under an hour!
Sunday, October 25, 2009
Automating a Dynamic Webpage
Today I created my first asp page. Nothing fancy of course, but it allows for some interesting manipulations of the HTML DOM. It makes what I do at work make a lot more sense now though.
Normally I just work on the client side of things. I became sick and tired of having to automate our GUI with basic webcontrol functions. I knew there had to be a quicker way. I eventually discovered how the form submit works, and reverse engineered how the client requested and updated the database through the GUI. I was able to build hundreds of scripts that allowed for very quick scraping and updating processes. But I really didn't know how the XML updates I was running were actually working.
Now that I've had time to play on my own ASP server, I can see how the GET and POST functions actually work. The SQL behind what I'm doing is still invisible of course, but knowing what's happening makes a lot of sense now.
I should be able to leverage this knowledge at work to further increase the speed of what I'm doing. I only which I could get the raw ASP page to see the SQL side of the request.
Normally I just work on the client side of things. I became sick and tired of having to automate our GUI with basic webcontrol functions. I knew there had to be a quicker way. I eventually discovered how the form submit works, and reverse engineered how the client requested and updated the database through the GUI. I was able to build hundreds of scripts that allowed for very quick scraping and updating processes. But I really didn't know how the XML updates I was running were actually working.
Now that I've had time to play on my own ASP server, I can see how the GET and POST functions actually work. The SQL behind what I'm doing is still invisible of course, but knowing what's happening makes a lot of sense now.
I should be able to leverage this knowledge at work to further increase the speed of what I'm doing. I only which I could get the raw ASP page to see the SQL side of the request.
Saturday, October 24, 2009
The Three Dimensional Illusion
How a one dimensional universe can appear to be three dimensional.
Imagine two particles; particle A, and particle B. From the vantage point of each particle, the other appears to be orbiting around it. There are two scenarios that would lead to this happening. One of the particles is either spinning, or one is rotating around the other.
With only two particles available, in a one dimensional setting, there is no way to determine how the particles are actually behaving without another reference. This leads to the concept of only two measurements; distance and spin. Meaning in our one dimensional universe, particles can only spin, and measure a distance to another particle.
By introducing a third particle we can now determine how the two particles are actually behaving in relation to each other. The behavior can be determined by measuring the distance of both particles. If neither is changing, than we know one of them is spinning. If one is moving, than we know that is the orbiting particle. Of course both could be moving, in which case a careful measuring of the change in distances would yield the relationship between the particles.
What we know have is a universe of one dimension, distance. Each particle would have a unique distance to each other particle along the one dimensional spectrum. This matrix of distances on a massive scale gives rise to the illusion of three dimensional space.
Now we have an interesting framework to describe how a one dimensional universe can look three dimensional. The only problem is that it isn’t complete. There are times when an array of distances will causes a particle to not match what we would expect to see in a three dimension space.
Assume particle A is 1m away from B, and 1m away from C, but C is 10m away from B. This would prevent a 3d illusion from forming within these particles. What might happen though is that the violating particle would simply vanish from sight. It still exists in the universe, but because it doesn’t follow the rule for an established 3d system it cannot be visible, but it could still interact.
This allows for there to be a vast number of particles all around you, but not visible because the distances between it and other particles don’t conform to the 3D rules. Because they are still particles though, they would exert a force on everything around them, like gravity and so on. This might be an explanation for dark matter. We can’t see it because it doesn’t behave correctly in the 3D rule set, but because it still exerts a force we can see its affects on other matter.
Imagine two particles; particle A, and particle B. From the vantage point of each particle, the other appears to be orbiting around it. There are two scenarios that would lead to this happening. One of the particles is either spinning, or one is rotating around the other.
With only two particles available, in a one dimensional setting, there is no way to determine how the particles are actually behaving without another reference. This leads to the concept of only two measurements; distance and spin. Meaning in our one dimensional universe, particles can only spin, and measure a distance to another particle.
By introducing a third particle we can now determine how the two particles are actually behaving in relation to each other. The behavior can be determined by measuring the distance of both particles. If neither is changing, than we know one of them is spinning. If one is moving, than we know that is the orbiting particle. Of course both could be moving, in which case a careful measuring of the change in distances would yield the relationship between the particles.
What we know have is a universe of one dimension, distance. Each particle would have a unique distance to each other particle along the one dimensional spectrum. This matrix of distances on a massive scale gives rise to the illusion of three dimensional space.
Now we have an interesting framework to describe how a one dimensional universe can look three dimensional. The only problem is that it isn’t complete. There are times when an array of distances will causes a particle to not match what we would expect to see in a three dimension space.
Assume particle A is 1m away from B, and 1m away from C, but C is 10m away from B. This would prevent a 3d illusion from forming within these particles. What might happen though is that the violating particle would simply vanish from sight. It still exists in the universe, but because it doesn’t follow the rule for an established 3d system it cannot be visible, but it could still interact.
This allows for there to be a vast number of particles all around you, but not visible because the distances between it and other particles don’t conform to the 3D rules. Because they are still particles though, they would exert a force on everything around them, like gravity and so on. This might be an explanation for dark matter. We can’t see it because it doesn’t behave correctly in the 3D rule set, but because it still exerts a force we can see its affects on other matter.
Subscribe to:
Posts (Atom)