?

Log in

No account? Create an account

James Mastros — LiveJournal

Dec. 15th, 2007

03:01 am - On Vox: Not a day: In which scramjets are debunked

On another site (we don't like to advertise), I came across a http://www.popsci.com/popsci/aviationspace/a3bfe2e6fb5c6110vgnvcm1000004eecbccdrcrd.html , in which scramjets are discussed.  It's been making the rounds again, so you've quite likely seen it elsewhere.  I thought I'd do a little looking into their claims, and here's what I came up with.  Anybody care to fault my physics; I wouldn't be surprised if I mucked up somewhere:

I think it'll be a long time before we start seeing scramjets for consumer travel, and here's why -- it's just too fast. "In 2004, NASA's unmanned X-43A ... reached Mach 9.6, setting the world speed record for a jet-powered aircraft. It took only 10 seconds of scramjet power to get it up to that speed."

That's a hair over 32 gee, people. That *will* kill you, see http://www.thespacereview.com/article/410/1. OK, you say, that's not the sort of acceleration profile you'd use for a consumer flight. The great circle distance from JFK to Melbourne [Tullamarine Intl] is 10374 mi. If we assume uniform acceleration to the halfway point, then uniform deceleration from there, the case with the lowest required acceleration, then we need to cover 5,187 mi in 1 hour.

That's 7.6 gravity. It won't kill you, but it's certianly not comfortable. That's the lowest possible accleration to get from New York to Melbourne in two hours, and it assumes a pretty amazing engine -- one that can run continously for two hours, and one that can instantly cut from full thrust forward to full thrust reverse.

It's not going to be possible to get humans from NYC to Australia in two hours without some sort of major change in the way we think physics works -- inertial dampers or teleporters.

[ this is good ] for making me think.

Originally posted on theorbtwo.vox.com

Dec. 14th, 2007

04:20 pm - On Vox: Day 2: In which a weekend is looked forward to.

Sleep cycle check: 14:20-19ish (declared not morning, didn't brush), 9-15:50 (brushed).  Guess that's not all better yet, but I'm getting closer, which is good, as we have a day out in London prepared for tomorrow, which I'm looking forward to, and it would be Not Good if I slept through it.
Started on Briscoe Country, Jr. yesterday.  Jess seemed to mildly enjoy it, and it's been long enough (apparently, it was on originally in 1993, so 14 years) that I can be surprised by the surprises again.  It's a bit overcompressed, but still quite watchable.
I went to bed feeling like I messed things up with a friend again, but she seems fairly recovered from the chatting she did elsewhere.  It's probably somewhat egotistical to think I had much to do with her bad mood in the first place, for that matter.
Looking forward to spending the weekend with Jess and with friends; it seems like a long time since I've had much time with either.
Not much more to say, so see you tomorrow.  Some of you (if you're reading) in person.

Originally posted on theorbtwo.vox.com

Dec. 13th, 2007

04:59 am - On Vox: Day 1: In which resolutions are made

Hi, all (for a very small value of all).
I just woke up and make some resolutions.  One of them is to write a blog entry every day (approximately) when I wake up, so here it is.  These will likely be short and boring, for the most part.
The other is that I shall brush my teath every morning, and report on my success in following that, so I don't muck it up.  Today: Brushed.
I've been awake seriously odd times lately, ever since shortly after getting back from the US on, er, Fri Nov 30, so almost a fortnight now.  Hopefully, that's resolving itself; last sleep-wake cycle was awake 5PM very appx yesterday, asleep appx 11PM last night, to awake appx 5 AM this morning.  When I put it like that, I see less hope, but there you have it... at least 5AM is a vaugely normal time to get up.
Let's see.  I'm a bit worried about Jess spending more and more time at work, but she doesn't seem to think that's actually the case, and she's probably right.  There's just been a few times lately when she's made up lost time that I wasn't aware of, and spending time semi-at-work.  For example, she took a long lunch break to drive up to Oxford and buy her eeepc, and forgot her Secret Santa gift, and had to drive all the way back her and back to Abingdon again to get it -- and that right there is almost 100 minutes off, from a 60 minute lunch break, and that didn't include any eating of lunch.
Plus, when I'm time-shifted, that means I don't get to spend as much time "with" jess, even if I'm awake all the time she's awake and at home, because I can't IRC with her while she's at work.  Also, most of the people I know are also alseep, for a doubleplusboring time.  Nobody at area 51 to be able to walk over there and hang either...
Yeah, that's it for now.  Kind of wish I could write different paragraphs in different securities; I don't want to make little short posts for little short bits of information I don't want to share widely.

Originally posted on theorbtwo.vox.com

Dec. 2nd, 2007

06:06 pm - In which I am lazy, and post a conversation as an entry.

17:54 < Dorward> The trip home last night was interesting
17:55 < castaway> again?
17:55 < Dorward> The busses weren't running along the usual route because of roadworks, so I ended up walking for half a mile along the route until it picked up again
17:56 < theorbtwo> Sounds even more fun then ours.
17:56 < Dorward> Happily the bus stops had maps so I didn't have trouble finding the way
17:57 < theorbtwo> We rushed from nearly the end of mst's live, er, issues to the tube stop, hurry-up-and-waited to Heathrow (while having the train unexpectly diverted to the other branch of the Piccadily line in midflight), up to left luggage and back to the bus stop.
17:57 < theorbtwo> We ended up at the bus stop 5 minutes late...
17:57 < theorbtwo> ...and he was still unpacking from his previous trip.
17:57 < Dorward> eeep
17:58 < Dorward> phew
17:58 < theorbtwo> Once we got on, he informed us that the bathroom was out of order, so we'd have to hold it until Swindon, where there would be bathrooms.
17:58 < theorbtwo> ...they were locked.
17:58 < Dorward> d'oh
17:59 < theorbtwo> However, we found a very nice Chinese resturant, and had a wonderful conversation about Blink, which we watched on Jess's A2 while on the bus.
17:59 < theorbtwo> They even deliver here!
18:00 < castaway> Blink++
18:00 < Dorward> :)
18:00 < castaway> A2++
18:00 < Dorward> Blink is very good
18:00 < theorbtwo> I even estimated that we're currently about 1/4 of the way along the lifetime of the universe.
18:01 < theorbtwo> (Breaking a predestination paradox would destory about 2/3rds of the universe; if we assume the destruction follows an event cone...)
18:02 * theorbtwo ponders just posting this conversation as a livejournal entry.
18:04 * Dorward starts geotagging LPW photos

Sep. 18th, 2007

03:12 pm - Starting Project: Cross-site friends

Allo, folkses.
I've started on a project recently, it's going to be a facebook application. Facebook has this interesting feature called "friends finder". You give it your AIM username and password, and it downloads your AIM friends list. Then it figures out what those people are called (if anything, of course) on facebook, and presents you with a list so you can (attempt to) add them.
Now, there's nothing in that that would require it to be part of the core. There's no reason I can't make it work for livejournal. I just need a way for facebook users to declare their livejournal user names... and, in fact, there's no reason not to ...
sorry, my brain has left the buildling. I need a nice long shower. Too bad that involves putting the side back on the bathtub first.

Sep. 10th, 2007

10:54 pm

Having a very ultra-rapid-cycling day. This is "down". I'm considering going to sleep. Again.

May. 21st, 2007

11:46 pm

I've been looking for a while for a decent drawing program, and I think I've determined that my definition of "decent" is a bit... overpowering.

1: It must have an interface that is fairly intuitive (to me).
2: It must be able to deal with changing requirements in a reasonable way. If I want that circle to be just a *little* bit bigger, I shouldn't have to manually move everything else.
3: It has to be free, at least as in beer, and preferably as in freedom.
4: It should have reusable objects, so I don't have to re-draw them every time I want to use them.
5: It should deal with 2d and 3d just fine. 4d is optional. ;)

I *think* the best way to deal with all this is to just write the damn thing myself. There's an interesting class of constraint-based drawing programs, such as Asymptote, MetaPost, and Linograph. But all of them have something *wrong* with them. They all only allow solving systems of linear equations for the constraints, they all have funkyness in their syntaxes of one sort or another. Linograph is seriously underdocumented. Metapost and Asymptote both have very deep stacks and are written in C. Metapost and Asymptote don't have any real archetechture for reusablility, whereas Linograph has no support for rotation and scaling as coordinate-set transformations.

Rolling my own will allow me to do things the Right Way from the beginning, and design in the functionality I want. I *think* I can make it reasonably extensible and easy to use fairly easily by good leverage of Perl and existing components on CPAN and elsewhere. For example, I can borrow bits of Linotype for postscript output, and use Math::Symbolic for the algebra (and calc, where it's necessary). I can possibly use solvers not based on linear algebra where I need to, hopefully with some help from Sara, and possibly MJD if I can manage to feel comfortable asking for help from strangers (something I'm really bad at). I can also do some of the funkier stuff I've been considering, like making it into a full electronics system, in reasonable manners. (Think about it -- the same constraint-based system can be used for all sorts of things, esp if I can make the algebra smart about units -- that is, know what (5mm+3ft)/2hours is, and what 4miles+6ohm isn't. If I can make the system know that R1 terminal 2 is connected to U1 pin 4, and draw semantic and physical layout diagrams automagically, that'd be a Big Win. But even if it can't do it all that automatically, just a start is, well, a start.)

There's a lot of work to do on it, absolutely, but it should be interesting work...

Tags:

May. 11th, 2007

01:57 pm - Hack of the day

I'm going to try to make this an occasional series. The hacks aren't neccessarly written today, but something made me think of them on this purticular day.

Today's is a simple script to let things know what machine you're currently on, if you move about -- not what machine you are currently *running* on, but what machine you are actually sitting at -- hopefully, anyway. I tend to run a screen session on my desktop, and attach to it from my laptop when I'm not at my desk. This lets audio announcements happen where I'll hear them, and lets X applications show up where they need to.

Anyway, on to the code:

This is run from a cronjob, once per minute:


#!/usr/bin/perl
use warnings;
use strict;
use Data::Dump::Streamer;
$|=1;

my @lines = `w`;

my %positions;
#uptime, loadavg, etc.
shift @lines;
my $line = shift @lines;
pos($line)=0;
while (pos($line) < length($line)) {
my $start = pos($line);
#print "$line\n";
#print "Pos start: ", pos($line), "\n";
#print "Length: ", length($line), "\n";
$line =~ m/\G(\S+)\s*/g;
#print "Captured: $1\n";
# print "HEADER: $start: $1\n";
$positions{$start} = $1;
}

my @logins;
for my $line (@lines) {
my %login;
chomp $line;
pos($line) = 0;
while (pos($line) < length($line)) {
my $startpos = pos($line);
$line =~ m/\G(\S+)\s*/g;
my $str = $1;
#print "$startpos: $str\n";
my $header;
my $fakestartpos = $startpos;
while (!$header) {
$header=$positions{$fakestartpos};
$fakestartpos++;
}
if ($header eq 'WHAT') {
$str = substr($line, $startpos);
pos($line) = length($line);
}
if ($header =~ /^(IDLE|JCPU|PCPU)$/) {
if ($str =~ m/^(\d+(?:\.\d+)?)s$/) {
$str = $1;
} elsif ($str =~ m/^(\d+):(\d+)m$/) {
$str = $1*60 + $2;
} elsif ($str =~ m/^(\d+):(\d+)$/) {
$str = $1*60*60 + $2*60;
} elsif ($str =~ m/^(\d+)days$/) {
$str = $1*60*60*24;
} else {
warn "Nonparse of rel time: $str";
}
}
#print "$startpos: $str: $header\n";
$login{lc $header}=$str;
}
push @logins, \%login;
}

my $n = 0;
for my $login (sort {$a->{idle} <=> $b->{idle}} @logins) {
# Dump $login;
# print "Idle: $login->{idle}\n";
my $from = $login->{from};
my $host;
if (($host, my $screen) = $from =~ m/^(.*?):S\.(\d+)$/) {
if ($host =~ m/(.*?):(\d+)/) {
$host = $1;
}
$host ||= 'localhost';
# print "Screen session, attached from $host, number $screen\n";
} elsif ($from eq '-') {
$host = 'localhost';
} else {
$host = $from;
}
# print "Host is $host\n";
if ($n == 0) {
open my $fh, ">".glob("~/current-machine");
print $fh "$host\n";
close $fh;
utime time-$login->{idle}, time-$login->{idle}, glob("~/current-machine");
}
$n++;
}


Not exactly the most elegant of code, because I couldn't figure out a way to get the data without running w from a command prompt and then parsing it's output. All my attempts to gather the data myself ended in slight, but significant, changes, mostly in the idle time.

This is combined with a small bash hack to keep my DISPLAY variable up-to-date, to make X applications show up where I want them: export PROMPT_COMMAND='eval export DISPLAY=`cat ~/current-machine`:0'

(Note that the DISPLAY hack doesn't attempt to check if there actually is an X server running on that machine. There's not really anything sane to do if there isn't one anyway.)

Note also that all that is neccessary to keep current-machine up-to-date is to do screen -rd and wait a minute. On the other hand, updating DISPLAY requires hitting enter in a bash. Though it's mostly accidental, that matches when I actually want them updated.

(Later, I'll probably post say.pl, which uses current-machine give me audio announcements where they're needed.)

Apr. 19th, 2007

05:48 pm

I have fallen in love with http://dresdencodak.com/
(Via http://dennyd.livejournal.com/615746.html)

That is all for now.

Feb. 21st, 2007

05:19 pm - Lilith woes

Lilith has been overheating lately (next to radiator was probably not the best place to put her), and has apparently developed bad RAM. This is a big headache, as it means I needed to compile a kernel with the badram patch. Unfortunately, I normally compile kernels on lilith. Big PITA, but everything seems OK now. Cross your fingers for me.

Navigate: (Previous 10 Entries | Next 10 Entries)